Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Enlighten::Helpers

Classes

NameDescription
Enlighten::Helpers::Hasher

Hashes data.

Functions

NameDescription
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
a1568ebab3c1c2ed158a16c85ac51c436
a1568ebab3c1c2ed158a16c85ac51c436

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
a4c0d3555556dda22bb31b06eb768c39c
a4c0d3555556dda22bb31b06eb768c39c

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
a678948b7beade6cb05f08c512e62f179
a678948b7beade6cb05f08c512e62f179

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
acf9a2d406a09d86c7b16f00822efadd7
acf9a2d406a09d86c7b16f00822efadd7

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
aa439bf557e9e55bf869c84b0da497039
aa439bf557e9e55bf869c84b0da497039

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
a2a9fd8b69298e64efc1006ec75cde12e
a2a9fd8b69298e64efc1006ec75cde12e

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
ad4daf96218a75a91b3a1c2c7559b69a2
ad4daf96218a75a91b3a1c2c7559b69a2

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
a38baf4dc9bceb143e3309f727eb1944b
a38baf4dc9bceb143e3309f727eb1944b

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