Hymn to Beauty
C++ 3D Engine
Video::WebGPURenderTargetAllocator Class Reference

WebGPU implementation of RenderTargetAllocator. More...

#include <WebGPURenderTargetAllocator.hpp>

Inheritance diagram for Video::WebGPURenderTargetAllocator:
Video::RenderTargetAllocator

Public Member Functions

 WebGPURenderTargetAllocator (WebGPURenderer &renderer)
 Create a new render target allocator. More...
 
 ~WebGPURenderTargetAllocator () final
 Destructor. More...
 
void BeginFrame () final
 Call at the beginning of each frame. More...
 
WebGPUTextureCreateAttachmentlessRenderTarget (const glm::uvec2 &size, uint32_t sampleCount=1)
 Create an attachmentless render target. More...
 
void FreeAttachmentlessRenderTarget (WebGPUTexture *renderTarget)
 Free an attachmentless render target. More...
 
- Public Member Functions inherited from Video::RenderTargetAllocator
 RenderTargetAllocator (uint8_t frames, RenderPassAllocator *renderPassAllocator)
 Create a new render target allocator. More...
 
virtual ~RenderTargetAllocator ()
 Destructor. More...
 
TextureCreateRenderTarget (const glm::uvec2 &size, Texture::Format format)
 Create a render target. More...
 
void FreeRenderTarget (Texture *renderTarget)
 Free a render target. More...
 

Detailed Description

WebGPU implementation of RenderTargetAllocator.

Constructor & Destructor Documentation

◆ WebGPURenderTargetAllocator()

Video::WebGPURenderTargetAllocator::WebGPURenderTargetAllocator ( WebGPURenderer renderer)
explicit

Create a new render target allocator.

Parameters
rendererThe WebGPU renderer.

◆ ~WebGPURenderTargetAllocator()

Video::WebGPURenderTargetAllocator::~WebGPURenderTargetAllocator ( )
final

Destructor.

Member Function Documentation

◆ BeginFrame()

void Video::WebGPURenderTargetAllocator::BeginFrame ( )
finalvirtual

Call at the beginning of each frame.

Reimplemented from Video::RenderTargetAllocator.

◆ CreateAttachmentlessRenderTarget()

WebGPUTexture * Video::WebGPURenderTargetAllocator::CreateAttachmentlessRenderTarget ( const glm::uvec2 &  size,
uint32_t  sampleCount = 1 
)

Create an attachmentless render target.

Parameters
sizeThe size of the texture, in pixels.
sampleCountMSAA samples.

◆ FreeAttachmentlessRenderTarget()

void Video::WebGPURenderTargetAllocator::FreeAttachmentlessRenderTarget ( WebGPUTexture renderTarget)

Free an attachmentless render target.

Parameters
renderTargetThe render target to free.

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