Files
SimpleRayTracing/native/header/Algorithm/GGXMultiScatter.h
Misaki f1d3dddb9a Change project structure;
Added new c# binding;
2025-12-30 20:54:05 +09:00

18 lines
539 B
C

#ifndef GGX_MULTI_SCATTER_H
#define GGX_MULTI_SCATTER_H
#include "Common.h"
#include "cglm/struct/vec3.h"
// Initialize the tiny LUT. Safe to call multiple times.
void ggx_ms_init_lut_once(void);
// Heitz-style multiple-scattering GGX approximation (Smith model).
// Returns a broad lobe (Lambertian-shaped in shading space).
vec3s ggx_multi_scatter_lambert(vec3s f0, float NoV, float NoL, float roughness);
// Expose E(NoV, roughness) for lobe mixing / pdfs.
float ggx_ms_E(float NoV, float roughness);
#endif // GGX_MULTI_SCATTER_H