|
VisuTwin Canvas
C++ 3D Engine — Metal Backend
|
#include <platform/graphics/metal/metalLICPass.h>
Public Member Functions | |
| void | execute (MTL::RenderCommandEncoder *encoder, Texture *velocityTexture, Texture *noiseTexture, int integrationSteps, float stepSize, float animationPhase, float contrastLo, float contrastHi, MetalRenderPipeline *pipeline, const std::shared_ptr< RenderTarget > &renderTarget, const std::vector< std::shared_ptr< MetalBindGroupFormat > > &bindGroupFormats, MTL::SamplerState *defaultSampler, MTL::DepthStencilState *defaultDepthStencilState) |
| MetalLICPass (MetalGraphicsDevice *device, MetalComposePass *composePass) | |
| ~MetalLICPass () | |
Manages the Surface LIC post-processing pass. Depends on MetalComposePass for shared full-screen vertex buffer/format.
Definition at line 49 of file metalLICPass.h.
| visutwin::canvas::MetalLICPass::MetalLICPass | ( | MetalGraphicsDevice * | device, |
| MetalComposePass * | composePass ) |
Definition at line 173 of file metalLICPass.cpp.
| visutwin::canvas::MetalLICPass::~MetalLICPass | ( | ) |
Definition at line 178 of file metalLICPass.cpp.
| void visutwin::canvas::MetalLICPass::execute | ( | MTL::RenderCommandEncoder * | encoder, |
| Texture * | velocityTexture, | ||
| Texture * | noiseTexture, | ||
| int | integrationSteps, | ||
| float | stepSize, | ||
| float | animationPhase, | ||
| float | contrastLo, | ||
| float | contrastHi, | ||
| MetalRenderPipeline * | pipeline, | ||
| const std::shared_ptr< RenderTarget > & | renderTarget, | ||
| const std::vector< std::shared_ptr< MetalBindGroupFormat > > & | bindGroupFormats, | ||
| MTL::SamplerState * | defaultSampler, | ||
| MTL::DepthStencilState * | defaultDepthStencilState ) |
Execute the LIC pass on the active render command encoder.
| encoder | Active render command encoder. |
| velocityTexture | RG16Float texture with screen-space velocity per pixel. |
| noiseTexture | R8Unorm tiled white noise texture (e.g. 200×200). |
| integrationSteps | Number of steps in each direction (total kernel = 2L+1). |
| stepSize | Step size in normalized texture coordinates. |
| animationPhase | Phase offset [0, 1] for animated LIC. |
| contrastLo | Low end of contrast enhancement range. |
| contrastHi | High end of contrast enhancement range. |
| pipeline | Metal render pipeline for state lookup. |
| renderTarget | Render target for pipeline state creation. |
| bindGroupFormats | Bind group formats for pipeline compatibility. |
| defaultSampler | Linear/wrap sampler for texture reads. |
| defaultDepthStencilState | Fallback depth-stencil state. |
Definition at line 216 of file metalLICPass.cpp.
References visutwin::canvas::Primitive::base, visutwin::canvas::Primitive::count, visutwin::canvas::CULLFACE_NONE, visutwin::canvas::MetalRenderPipeline::get(), visutwin::canvas::Texture::height(), visutwin::canvas::Texture::impl(), visutwin::canvas::Primitive::indexed, visutwin::canvas::PRIMITIVE_TRIANGLES, visutwin::canvas::Primitive::type, and visutwin::canvas::Texture::width().