|
Rendu
A lightweight rendering engine for experimentations
|
Precompute BRDF-related data for real-time rendering.
Perform cubemap GGX convolution, irradiance SH coefficients computation, and linearized BRDF look-up table precomputation.
Functions | |
| void | loadCubemap (const std::string &inputPath, Texture &cubemapInfos) |
| void | computeCubemapConvolution (const Texture &cubemapInfos, int levelsCount, int outputSide, int samplesCount, std::vector< Texture > &cubeLevels) |
| void | exportCubemapConvolution (std::vector< Texture > &cubeLevels, const std::string &outputPath) |
| void | computeAndExportLookupTable (const int outputSide, const std::string &outputPath) |
| int | main (int argc, char **argv) |
| void computeAndExportLookupTable | ( | const int | outputSide, |
| const std::string & | outputPath | ||
| ) |
Compute and export a linearized BRDF look-up table.
| outputSide | the side size of the 2D output map |
| outputPath | the destination path |
| void computeCubemapConvolution | ( | const Texture & | cubemapInfos, |
| int | levelsCount, | ||
| int | outputSide, | ||
| int | samplesCount, | ||
| std::vector< Texture > & | cubeLevels | ||
| ) |
Compute a series of cubemaps convolved with a BRDF using increasing roughness values. The cubemaps form a mipmap pyramid.
| cubemapInfos | the source HDR cubemap |
| levelsCount | the number of mipmap levels to generate |
| outputSide | the side size of the lvel 0 cubemap faces |
| samplesCount | the number of samples to use in the convolution |
| cubeLevels | will contain the texture infos for each level |
| void exportCubemapConvolution | ( | std::vector< Texture > & | cubeLevels, |
| const std::string & | outputPath | ||
| ) |
Export the pre-convolved cubemap levels.
| cubeLevels | the textures to export as mipmap levels |
| outputPath | the based destination path |
| void loadCubemap | ( | const std::string & | inputPath, |
| Texture & | cubemapInfos | ||
| ) |
| int main | ( | int | argc, |
| char ** | argv | ||
| ) |
Compute either a series of cubemaps convolved with a BRDF using increasing roughness values, irradiance spherical harmonics coefficients, or generate a linearized BRDF look-up table.
| argc | the number of input arguments. |
| argv | a pointer to the raw input arguments. |
Loading section.
Computations section.
Export section.
Visualisation section.
Rendering.