Helper struct for depth or light pre-passes.
More...
#include <candlewick/core/DepthAndShadowPass.h>
|
| DepthPass (NoInitT) |
|
| DepthPass (const Device &device, const MeshLayout &layout, SDL_GPUTexture *depth_texture, SDL_GPUTextureFormat format, const Config &config={}) |
| Create DepthPass (e.g. for a depth pre-pass) from a Device, specified mesh layout, and raw texture handle along with its format.
|
|
| DepthPass (const Device &device, const MeshLayout &layout, const Texture &depth_texture, const Config &config={}) |
| Create DepthPass (e.g. for a depth pre-pass) from a Device, specified mesh layout, and the RAIII Texture object.
|
|
| DepthPass (const DepthPass &)=delete |
|
DepthPass & | operator= (const DepthPass &)=delete |
|
| DepthPass (DepthPass &&other) noexcept |
|
DepthPass & | operator= (DepthPass &&other) noexcept |
|
void | render (CommandBuffer &cmdBuf, const Mat4f &viewProj, std::span< const OpaqueCastable > castables) |
|
void | release () noexcept |
| Release the pass resources.
|
|
| ~DepthPass () noexcept |
|
Helper struct for depth or light pre-passes.
- Warning
- The depth pre-pass is meant for opaque geometries. Hence, the pipeline created by the create() factory function will have back-face culling enabled.
◆ DepthPass() [1/5]
candlewick::DepthPass::DepthPass |
( |
NoInitT | | ) |
|
|
inline |
◆ DepthPass() [2/5]
candlewick::DepthPass::DepthPass |
( |
const Device & | device, |
|
|
const MeshLayout & | layout, |
|
|
SDL_GPUTexture * | depth_texture, |
|
|
SDL_GPUTextureFormat | format, |
|
|
const Config & | config = {} ) |
Create DepthPass (e.g. for a depth pre-pass) from a Device, specified mesh layout, and raw texture handle along with its format.
- Parameters
-
device | The device object. |
layout | Mesh layout used for the render pipeline's vertex input state. |
depth_texture | Raw handle to a texture. Cannot be null. |
format | Texture format. Has to be passed here because we pass the raw handle. |
config | Configuration. |
◆ DepthPass() [3/5]
Create DepthPass (e.g. for a depth pre-pass) from a Device, specified mesh layout, and the RAIII Texture object.
- Parameters
-
device | The device object. |
layout | Mesh layout used for the render pipeline's vertex input state. |
depth_texture | Texture object. |
config | Configuration. |
◆ DepthPass() [4/5]
candlewick::DepthPass::DepthPass |
( |
const DepthPass & | | ) |
|
|
delete |
◆ DepthPass() [5/5]
candlewick::DepthPass::DepthPass |
( |
DepthPass && | other | ) |
|
|
noexcept |
◆ ~DepthPass()
candlewick::DepthPass::~DepthPass |
( |
| ) |
|
|
inlinenoexcept |
◆ operator=() [1/2]
◆ operator=() [2/2]
◆ release()
void candlewick::DepthPass::release |
( |
| ) |
|
|
noexcept |
Release the pass resources.
◆ render()
◆ depthTexture
SDL_GPUTexture* candlewick::DepthPass::depthTexture = nullptr |
◆ pipeline
SDL_GPUGraphicsPipeline* candlewick::DepthPass::pipeline = nullptr |
◆ TRANSFORM_SLOT
Uint32 candlewick::DepthPass::TRANSFORM_SLOT = 0 |
|
staticconstexpr |
The documentation for this class was generated from the following file: