6#ifndef MATERIALX_HARMONICS_H
7#define MATERIALX_HARMONICS_H
26 static const size_t NUM_BANDS = B;
27 static const size_t NUM_COEFFS = B * B;
31 explicit ShCoeffs(
const std::array<C, NUM_COEFFS>& arr) : _arr(arr) { }
51 const C&
operator[](
size_t i)
const {
return _arr.at(i); }
56 std::array<C, NUM_COEFFS> _arr;
78MX_RENDER_API
ImagePtr normalizeEnvironment(
ConstImagePtr env,
float envRadiance,
float maxTexelRadiance);
91MX_RENDER_API
ImagePtr renderEnvironment(
const Sh3ColorCoeffs& shEnv,
unsigned int width,
unsigned int height);
99MX_RENDER_API
ImagePtr renderReferenceIrradiance(
ConstImagePtr env,
unsigned int width,
unsigned int height);
shared_ptr< const Image > ConstImagePtr
A shared pointer to a const image.
Definition: Image.h:27
shared_ptr< Image > ImagePtr
A shared pointer to an image.
Definition: Image.h:24
Macros for declaring imported and exported symbols.
Data types for rendering functionality.
A three-component color value.
Definition: Types.h:376
Class template for a vector of spherical harmonic coefficients.
Definition: Harmonics.h:24
const C & operator[](size_t i) const
Return the const coefficient at the given index.
Definition: Harmonics.h:51
C & operator[](size_t i)
Return the coefficient at the given index.
Definition: Harmonics.h:48
bool operator!=(const ShCoeffs &rhs) const
Return true if the given vector differs from this one.
Definition: Harmonics.h:41
bool operator==(const ShCoeffs &rhs) const
Return true if the given vector is identical to this one.
Definition: Harmonics.h:38
A vector of three floating-point values.
Definition: Types.h:303