5 #ifndef FLUTTER_IMPELLER_RENDERER_BACKEND_VULKAN_TEXTURE_SOURCE_VK_H_
6 #define FLUTTER_IMPELLER_RENDERER_BACKEND_VULKAN_TEXTURE_SOURCE_VK_H_
11 #include "flutter/fml/status.h"
84 uint32_t array_layer)
const = 0;
150 uint32_t mip_level = 0u,
151 uint32_t slice = 0u);
160 uint32_t mip_level = 0u,
161 uint32_t slice = 0u)
const;
169 struct CachedFrameDataEntry {
179 std::vector<CachedFrameDataEntry> frame_data_;
180 mutable vk::ImageLayout layout_ = vk::ImageLayout::eUndefined;
Abstract base class that represents a vkImage and an vkImageView.
TextureSourceVK(TextureDescriptor desc)
virtual std::shared_ptr< YUVConversionVK > GetYUVConversion() const
When sampling from textures whose formats are not known to Vulkan, a custom conversion is necessary t...
void SetCachedFrameData(const FramebufferAndRenderPass &data, SampleCount sample_count, uint32_t mip_level=0u, uint32_t slice=0u)
virtual bool IsSwapchainImage() const =0
Determines if swapchain image. That is, an image used as the root render target.
const TextureDescriptor & GetTextureDescriptor() const
Gets the texture descriptor for this image source.
FramebufferAndRenderPass GetCachedFrameData(SampleCount sample_count, uint32_t mip_level=0u, uint32_t slice=0u) const
virtual vk::ImageView GetImageView() const =0
Retrieve the image view used for sampling/blitting/compute with this texture source.
virtual vk::ImageView GetRenderTargetView(uint32_t mip_level, uint32_t array_layer) const =0
Retrieve the image view used to attach a specific subresource of this texture as a render target.
virtual vk::Image GetImage() const =0
Get the image handle for this texture source.
virtual ~TextureSourceVK()
vk::ImageLayout GetLayout() const
Get the last layout assigned to the TextureSourceVK.
vk::ImageLayout SetLayoutWithoutEncoding(vk::ImageLayout layout) const
Store the layout of the image.
const TextureDescriptor desc_
fml::Status SetLayout(const BarrierVK &barrier) const
Encodes the layout transition barrier to barrier.cmd_buffer for the image.
std::shared_ptr< SharedObjectVKT< T > > SharedHandleVK
Defines an operations and memory access barrier on a resource.
SharedHandleVK< vk::Framebuffer > framebuffer
SharedHandleVK< vk::RenderPass > render_pass
A lightweight object that describes the attributes of a texture that can then used an allocator to cr...