5 #ifndef FLUTTER_IMPELLER_CORE_DEVICE_BUFFER_H_
6 #define FLUTTER_IMPELLER_CORE_DEVICE_BUFFER_H_
26 virtual bool SetLabel(std::string_view label) = 0;
44 virtual void Flush(std::optional<Range> range = std::nullopt)
const;
46 virtual void Invalidate(std::optional<Range> range = std::nullopt)
const;
static BufferView AsBufferView(std::shared_ptr< DeviceBuffer > buffer)
Create a buffer view of this entire buffer.
virtual void Flush(std::optional< Range > range=std::nullopt) const
const DeviceBufferDescriptor desc_
virtual bool SetLabel(std::string_view label, Range range)=0
virtual void Invalidate(std::optional< Range > range=std::nullopt) const
virtual uint8_t * OnGetContents() const =0
const DeviceBufferDescriptor & GetDeviceBufferDescriptor() const
DeviceBuffer(DeviceBufferDescriptor desc)
virtual bool SetLabel(std::string_view label)=0
virtual bool OnCopyHostBuffer(const uint8_t *source, Range source_range, size_t offset)=0
bool CopyHostBuffer(const uint8_t *source, Range source_range, size_t offset=0u)