20#ifndef RHI_SUPERSAMPLE_H
21#define RHI_SUPERSAMPLE_H
48 frame.
renderScale =
static_cast<float>( std::max( aFactor, 1u ) );
50 if( aFactor <= 1 || aFrame.
viewport[0] <= 0.0f || aFrame.
viewport[1] <= 0.0f )
57 for(
int col = 0; col < 4; ++col )
72 grid.renderScale =
static_cast<float>( std::max( aFactor, 1u ) );
81 for(
int row = 0; row < 4; ++row )
The Cairo implementation of the graphics abstraction layer.
GRID_UBO_DATA RhiSupersampleGrid(const GRID_UBO_DATA &aGrid, uint32_t aFactor)
constexpr float RHI_SUPERSAMPLE_OFFSET
Offset of a supersampled target from where its frame puts the scene, in pixels.
FRAME_UBO_DATA RhiSupersampleFrame(const FRAME_UBO_DATA &aFrame, uint32_t aFactor)
Per-frame uniform block matching FrameUBO in frame_ubo.glsl (std140).
float projection[16]
column-major for GLSL
float renderScale
target texels per viewport pixel, above 1 in a supersampled target
Grid uniform block matching the GridUBO layout in grid.frag (std140).