Rendu
A lightweight rendering engine for experimentations
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
GPUShaders::Frag::Cubemap_convo Class Reference

Cubemap convo fragment shader. More...

Public Member Functions

vec3 convo (vec3 r, float roughness)
 
void main ()
 

Public Attributes

in vec3 pos
 World position.
 
uniform uniform float mipmapRoughness
 The roughness to use for the convolution lobe.
 
uniform float clampMax
 Clamp input HDR values to avoid artefacts.
 
uniform int samplesCount
 Number of samples to take, higher count helps avoiding artifacts in bright areas.
 
out vec3 fragColor
 Color.
 

Detailed Description

Cubemap convo fragment shader.

See also
GPUShaders::Common::Common_pbr, GPUShaders::Common::Utils

Member Function Documentation

◆ convo()

vec3 GPUShaders::Frag::Cubemap_convo::convo ( vec3  r,
float  roughness 
)
inline

Perform convolution with the BRDF specular lobe, evaluated in a given direction.

Parameters
rthe reflection direction
roughnessthe roughness to evalute the BRDF at
Returns
the result of the convolution

◆ main()

void GPUShaders::Frag::Cubemap_convo::main ( )
inline

Perform convolution of the cubemap with the BRDF lobe at a given roughness, using a high number of samples and importance sampling. This is done in the direction in world space of the current fragment.


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