| Flutter Impeller |

Public Member Functions | List of all members
impeller::SwapchainTransientsVK Class Reference

Resources, meant to be memoized by the texture descriptor of the wrapped swapchain images, that are intuitively cheap to create but have been observed to be time consuming to construct on some Vulkan drivers. This includes the device-transient MSAA and depth-stencil textures. More...

`#include <swapchain_transients_vk.h>`

## Public Member Functions
| SwapchainTransientsVK (std::weak_ptr< Context > context, TextureDescriptor desc, bool enable_msaa)
| ~SwapchainTransientsVK ()
| SwapchainTransientsVK (const SwapchainTransientsVK &)=delete
SwapchainTransientsVK & | operator= (const SwapchainTransientsVK &)=delete
const std::weak_ptr< Context > & | GetContext () const
bool | IsMSAAEnabled () const
const std::shared_ptr< Texture > & | GetMSAATexture ()
const std::shared_ptr< Texture > & | GetDepthStencilTexture ()

## Detailed Description

Resources, meant to be memoized by the texture descriptor of the wrapped swapchain images, that are intuitively cheap to create but have been observed to be time consuming to construct on some Vulkan drivers. This includes the device-transient MSAA and depth-stencil textures.

The same textures are used for all swapchain images.

Definition at line 23 of file swapchain_transients_vk.h.

## Constructor & Destructor Documentation

## ◆ SwapchainTransientsVK() [1/2]

impeller::SwapchainTransientsVK::SwapchainTransientsVK | ( | std::weak_ptr< Context > | context,
|  | TextureDescriptor | desc,
|  | bool | enable_msaa
| ) |  |
| explicit

Definition at line 11 of file swapchain_transients_vk.cc.

14 : context_(std::move(context)), desc_(desc), enable_msaa_(enable_msaa) {}

## ◆ ~SwapchainTransientsVK()

impeller::SwapchainTransientsVK::~SwapchainTransientsVK | ( |  | ) |
| default

## ◆ SwapchainTransientsVK() [2/2]

impeller::SwapchainTransientsVK::SwapchainTransientsVK | ( | const SwapchainTransientsVK & |  | ) |
| delete

## Member Function Documentation

## ◆ GetContext()

const std::weak_ptr< Context > & impeller::SwapchainTransientsVK::GetContext | ( |  | ) | const

Definition at line 94 of file swapchain_transients_vk.cc.

94 {
95 return context_;
96 }

## ◆ GetDepthStencilTexture()

const std::shared_ptr< Texture > & impeller::SwapchainTransientsVK::GetDepthStencilTexture | ( |  | ) |

Definition at line 27 of file swapchain_transients_vk.cc.

27 {
28 if (cached_depth_stencil_) {
29 return cached_depth_stencil_;
30 }
31 cached_depth_stencil_ = CreateDepthStencilTexture();
32 return cached_depth_stencil_;
33 }

## ◆ GetMSAATexture()

const std::shared_ptr< Texture > & impeller::SwapchainTransientsVK::GetMSAATexture | ( |  | ) |

Definition at line 18 of file swapchain_transients_vk.cc.

18 {
19 if (cached_msaa_texture_) {
20 return cached_msaa_texture_;
21 }
22 cached_msaa_texture_ = CreateMSAATexture();
23 return cached_msaa_texture_;
24 }

## ◆ IsMSAAEnabled()

bool impeller::SwapchainTransientsVK::IsMSAAEnabled | ( |  | ) | const

Definition at line 90 of file swapchain_transients_vk.cc.

90 {
91 return enable_msaa_;
92 }

## ◆ operator=()

SwapchainTransientsVK& impeller::SwapchainTransientsVK::operator= | ( | const SwapchainTransientsVK & |  | ) |
| delete

The documentation for this class was generated from the following files:

- impeller/renderer/backend/vulkan/swapchain/swapchain_transients_vk.h
- impeller/renderer/backend/vulkan/swapchain/swapchain_transients_vk.cc