MCPcopy Create free account
hub / github.com/TheRealMJP/BakingLab / ProjectOntoSH9Color

Function ProjectOntoSH9Color

SampleFramework11/v1.02/Graphics/SH.cpp:81–88  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

79}
80
81SH9Color ProjectOntoSH9Color(const Float3& dir, const Float3& color)
82{
83 SH9 sh = ProjectOntoSH9(dir);
84 SH9Color shColor;
85 for(uint64 i = 0; i < 9; ++i)
86 shColor.Coefficients[i] = color * sh.Coefficients[i];
87 return shColor;
88}
89
90Float3 EvalSH9Cosine(const Float3& dir, const SH9Color& sh)
91{

Callers 4

AddSampleMethod · 0.85
AddSampleMethod · 0.85
AddSampleMethod · 0.85
ProjectCubemapToSHFunction · 0.85

Calls 1

ProjectOntoSH9Function · 0.85

Tested by

no test coverage detected