5#ifndef FLUTTER_IMPELLER_RENDERER_BACKEND_GLES_DEVICE_BUFFER_GLES_H_
6#define FLUTTER_IMPELLER_RENDERER_BACKEND_GLES_DEVICE_BUFFER_GLES_H_
20 public BackendCast<DeviceBufferGLES, DeviceBuffer> {
24 std::shared_ptr<Allocation> backing_store);
41 void Flush(std::optional<Range> range = std::nullopt)
const override;
46 mutable std::shared_ptr<Allocation> backing_store_;
47 mutable uint32_t generation_ = 0;
48 mutable uint32_t upload_generation_ = 0;
51 uint8_t* OnGetContents()
const override;
54 bool OnCopyHostBuffer(
const uint8_t*
source,
59 bool SetLabel(
const std::string& label)
override;
62 bool SetLabel(
const std::string& label,
Range range)
override;
void Flush(std::optional< Range > range=std::nullopt) const override
DeviceBufferGLES(DeviceBufferDescriptor desc, ReactorGLES::Ref reactor, std::shared_ptr< Allocation > backing_store)
void UpdateBufferData(const std::function< void(uint8_t *, size_t length)> &update_buffer_data)
bool BindAndUploadDataIfNecessary(BindingType type) const
~DeviceBufferGLES() override
const uint8_t * GetBufferData() const
std::shared_ptr< ReactorGLES > Ref
Dart_NativeFunction function