Enlighten::Helpers
Classes
Name | Description |
---|---|
Enlighten::Helpers::Hasher | Hashes data. |
Functions
Name | Description |
---|---|
ConstructLightViewProjTransposed(const Geo::v128 &, const Geo::v128 &, const Geo::v128 &, const Geo::v128 &, float, float, float, float, float, Geo::v128 &, Geo::v128 &, Geo::v128 &) | Constructs a transposed light view projection matrix for the given light parameters. |
ExtractDusterVisibility(const Geo::u8 *, const Geo::u32, const Geo::u32) | Extracts 4 consecutive bits into an XYZW mask from the given visibility data based on the given quad index. |
ExtractIndexedXyValues(const Geo::v128 *, const Geo::v128 &, Geo::v128 &, Geo::v128 &) | Extracts the indexed X and Y values from a vector table, based on the input indices. |
ExtractSampleVisibility(const Geo::u8 *, const Geo::u32, const Geo::u32) | Extracts 4 consecutive bits into an XYZW mask from the given visibility data given an arbitrary sample index. |
QuadDotProduct(const Geo::v128 &, const Geo::v128 &, const Geo::v128 &, const Geo::v128 &, const Geo::v128 &, const Geo::v128 &) | Determine dot product of four 3-component vectors packed into x, y and z against another 4 vectors packed into normalsX, normalsY and normalsZ. |
QuadDotProduct(const Geo::v128 &, const Geo::v128 &, const Geo::v128 &, const Geo::v128 &) | Determine dot product of four 3-component vectors packed into x, y and z against another vector. |
QuadLengthSquared(const Geo::v128 &, const Geo::v128 &, const Geo::v128 &) | Determine length squared of four 3-component vectors packed into x, y and z. |
VisibilityMask(const void *) | Determine the mask to be used based on the visibility pointer. |
Anchor | ||||
---|---|---|---|---|
|
Geo::Matrix Enlighten::Helpers::ConstructLightViewProjTransposed
...
public: Geo::Matrix ConstructLightViewProjTransposed
(
const Geo::v128 & rightVec,
const Geo::v128 & upVec,
const Geo::v128 & dirVec,
const Geo::v128 & position,
float coneAngle,
float secondConeAngle,
float nearDist,
float far,
float cutoff,
Geo::v128 & sinOut,
Geo::v128 & cosOut,
Geo::v128 & tanOut
)
...
Constructs a transposed light view projection matrix for the given light parameters.
Parameters
[in] | rightVec | - The 'right' vector of light basis in world space |
[in] | upVec | - The 'up' vector of light basis in world space |
[in] | dirVec | -The 'forward' vector of light basis in world space |
[in] | position | - The world space position of the light |
[in] | coneAngle | - The cone angle of the light |
[in] | secondConeAngle | - The second cone angle of the light |
[in] | nearDist | - The light near plane distance |
[in] | far | - The light far plane distance |
[in] | cutoff | - The radius outside which the intensity of the light is clamped to zero |
[out] | sinOut | - The computed sin of the light cone angle |
[out] | cosOut | - The computed cosine of the light cone angle |
[out] | tanOut | - The computed tangent of the light cone angle |
Returns
The transposed light view projection matrix
Anchor | ||||
---|---|---|---|---|
|
Geo::v128 Enlighten::Helpers::ExtractDusterVisibility
...
public: Geo::v128 ExtractDusterVisibility
(
const Geo::u8 * visibility,
const Geo::u32 quadIndex,
const Geo::u32 indexMask
)
...
Extracts 4 consecutive bits into an XYZW mask from the given visibility data based on the given quad index.
Parameters
[in] | visibility | - The packed duster visibility data |
[in] | quadIndex | - The index into the packed duster visibility data |
[in] | indexMask | - The index mask |
Returns
The XYZW duster visibility mask
Anchor | ||||
---|---|---|---|---|
|
void Enlighten::Helpers::ExtractIndexedXyValues
...
public: void ExtractIndexedXyValues
(
const Geo::v128 * table,
const Geo::v128 & vIndices,
Geo::v128 & xValues,
Geo::v128 & yValues
)
...
Extracts the indexed X and Y values from a vector table, based on the input indices.
Parameters
[in] | table | - The table to index |
[in] | vIndices | - The floating point indices (truncated before doing the lookup) |
[out] | xValues | - The X values |
[out] | yValues | - The Y values |
Anchor | ||||
---|---|---|---|---|
|
Geo::v128 Enlighten::Helpers::ExtractSampleVisibility
...
public: Geo::v128 ExtractSampleVisibility
(
const Geo::u8 * visibility,
const Geo::u32 sampleIdx,
const Geo::u32 indexMask
)
...
Extracts 4 consecutive bits into an XYZW mask from the given visibility data given an arbitrary sample index.
Parameters
[in] | visibility | - The packed sample visibility data |
[in] | sampleIdx | - The index into the packed sample visibility data |
[in] | indexMask | - The index mask |
Returns
The XYZW sample visibility mask
Anchor | ||||
---|---|---|---|---|
|
GEO_CONTROLLED_INLINE Geo::v128 Enlighten::Helpers::QuadDotProduct
...
public: GEO_CONTROLLED_INLINEGeo::v128 QuadDotProduct
(
const Geo::v128 & x,
const Geo::v128 & y,
const Geo::v128 & z,
const Geo::v128 & normalsX,
const Geo::v128 & normalsY,
const Geo::v128 & normalsZ
)
...
Determine dot product of four 3-component vectors packed into x, y and z against another 4 vectors packed into normalsX, normalsY and normalsZ.
Parameters
[in] | x | - contains the x component of 4 vectors |
[in] | y | - contains the y component of 4 vectors |
[in] | z | - contains the z component of 4 vectors |
[in] | normalsX | - contains the x component of 4 normals |
[in] | normalsY | - contains the y component of 4 normals |
[in] | normalsZ | - contains the z component of 4 normals |
Anchor | ||||
---|---|---|---|---|
|
GEO_CONTROLLED_INLINE Geo::v128 Enlighten::Helpers::QuadDotProduct
...
public: GEO_CONTROLLED_INLINEGeo::v128 QuadDotProduct
(
const Geo::v128 & x,
const Geo::v128 & y,
const Geo::v128 & z,
const Geo::v128 & normal
)
...
Determine dot product of four 3-component vectors packed into x, y and z against another vector.
Parameters
[in] | x | - contains the x component of 4 vectors |
[in] | y | - contains the y component of 4 vectors |
[in] | z | - contains the z component of 4 vectors |
[in] | normal | - vector to do the dot product against for the 4 packed vectors |
Anchor | ||||
---|---|---|---|---|
|
GEO_CONTROLLED_INLINE Geo::v128 Enlighten::Helpers::QuadLengthSquared
...
public: GEO_CONTROLLED_INLINEGeo::v128 QuadLengthSquared
(
const Geo::v128 & x,
const Geo::v128 & y,
const Geo::v128 & z
)
...
Determine length squared of four 3-component vectors packed into x, y and z.
Parameters
[in] | x | - contains the x component of 4 vectors |
[in] | y | - contains the y component of 4 vectors |
[in] | z | - contains the z component of 4 vectors |
Anchor | ||||
---|---|---|---|---|
|
GEO_CONTROLLED_INLINE Geo::u32 Enlighten::Helpers::VisibilityMask
...
public: GEO_CONTROLLED_INLINEGeo::u32 VisibilityMask
(
const void * visibilityPointer
)
...
Determine the mask to be used based on the visibility pointer.
Parameters
[in] | visibilityPointer | - Pointer to the visibility buffer |