module Extended Input Lighting

This is the documentation for Enlighten.

module Extended Input Lighting

The extended input lighting api.

Classes

Name

Description

Name

Description

Enlighten::DirectInputLightingParameters

A class containing the parameters to be used as input to the direct input lighting stage.

Enlighten::IncidentLightingBuffer

A buffer containing the incident lighting for a system's input sample points (internal).

Enlighten::IndirectInputLightingParameters

A class containing the parameters to be used as input to the indirect input lighting stage.

Enlighten::TransparencyWorkspace

Workspace used for authored destruction of lightmapped geometry (internal).

Functions

Name

Description

Name

Description

AddDusterValuesToInputWorkspace(const InputWorkspace *, Enlighten::IncidentLightingBuffer *, const Geo::v128 *)

Adds light values laid out in a duster block to an Enlighten input workspace.

ApplyVolumeTransparency(const InputWorkspace *, TransparencyWorkspace *, const SphereVolume &)

Mark the quads transparency value using a sphere volume.

ApplyVolumeTransparency(const InputWorkspace *, TransparencyWorkspace *, const BoxVolume &)

Mark the quads transparency value using a box volume.

CalcBounceBufferSize(const Enlighten::InputWorkspace *, PrecisionHint::Value)

Tells you the amount of memory required to hold bounce lighting for a given system.

CalcIncidentLightingBufferSize(const Enlighten::InputWorkspace *, PrecisionHint::Value)

Tells you the amount of memory required to hold incident lighting for a given system.

CalcRequiredScratchSpaceMemory(InputLightBase **, Geo::u32)

Calculate how much scratchspace memory will be required by the DoDirectInputLighting() function given the lights to be shaded.

CalcTransparencyWorkspaceSize(const InputWorkspace *, Geo::s32, PrecisionHint::Value)

Tells you the amount of memory required for the transparency workspace for a given system.

CalcTransparencyWorkspaceSize(const InputWorkspace *, Geo::s32, Geo::s32, PrecisionHint::Value)

Tells you the amount of memory required for the transparency workspace for a given system.

CompareBounceBuffers(Geo::Statistics &, const Enlighten::BounceBuffer *, const Enlighten::BounceBuffer *)

Compares Returns true if the bounce buffers could be compared.

CompareIncidentLightingBuffers(Geo::Statistics &, const Enlighten::IncidentLightingBuffer *, const Enlighten::IncidentLightingBuffer *)

Compares Returns true if the lighting buffers could be compared.

CreateBounceBuffer(void *, const Enlighten::InputWorkspace *, PrecisionHint::Value)

Construct a BounceBuffer inside the memory provided.

CreateIncidentLightingBuffer(void *, const Enlighten::InputWorkspace *, PrecisionHint::Value)

Construct an IncidentLightingBuffer inside the memory provided.

CreateTransparencyWorkspace(void *, const InputWorkspace *, Geo::s32, Geo::s32, PrecisionHint::Value)

Construct an TransparencyWorkspace inside the memory provided.

CreateTransparencyWorkspace(void *, const InputWorkspace *, Geo::s32, PrecisionHint::Value)

Construct an TransparencyWorkspace inside the memory provided.

DoDirectInputLighting(DirectInputLightingParameters *, void *, size_t, Geo::u32 &)

Do the Direct input lighting stage.

DoIndirectInputLighting(IndirectInputLightingParameters *, Geo::u32 &)

Do the indirect input lighting stage.

GetBounceBufferSize(const Enlighten::BounceBuffer *, PrecisionHint::Value)

Returns the size of the specified BounceBuffer object.

GetBounceBufferSystemId(const Enlighten::BounceBuffer *)

Get system id from BounceBuffer.

GetIncidentLightingBufferSize(const Enlighten::IncidentLightingBuffer *, PrecisionHint::Value)

Returns the size of the specified IncidentLightingBuffer object.

GetIncidentLightingBufferSystemId(const Enlighten::IncidentLightingBuffer *)

Get system id from IncidentLightingBuffer.

SetTransparency(const InputWorkspace *, TransparencyWorkspace *, float)

Set all transparency values of transparencyWorkspace to the given value.

UpdateTransparencyWorkspace(const InputWorkspace *, TransparencyWorkspace *, const InterpolationInputSet *, Geo::s32, bool)

Update the transparency workspace with values calculated from interpolated probes.

UpdateTransparencyWorkspace(const InputWorkspace *, TransparencyWorkspace *, Enlighten::IProbeSetManager *, bool)

Update the transparency workspace with values calculated from interpolated probes.

VerifyBounceBufferData(const Enlighten::BounceBuffer *)

Returns true if there are no NaN's or non-finite numbers in the specified BounceBuffer object.

VerifyIncidentLightingBufferData(const Enlighten::IncidentLightingBuffer *)

Returns true if there are no NaN's or non-finite numbers in the specified InputLightingBuffer object.



bool GEO_CALL Enlighten::AddDusterValuesToInputWorkspace


public: bool GEO_CALL AddDusterValuesToInputWorkspace
(
    const InputWorkspace * workspaceMemory,
    Enlighten::IncidentLightingBuffer * output,
    const Geo::v128 * dusterValues
)


Adds light values laid out in a duster block to an Enlighten input workspace.

 

Parameters

[in]

workspaceMemory

The input workspace memory block.

[in]

output

The incident lighting buffer to fill with data.

[in]

dusterValues

The linear light colour values for the duster array of point samples. The duster (its size, positions, normals etc.) must match the one originally passed to CreateInputWorkspace.

 



void GEO_CALL Enlighten::ApplyVolumeTransparency


public: void GEO_CALL ApplyVolumeTransparency
(
    const InputWorkspace * inputWorkspace,
    TransparencyWorkspace * transparencyWorkspace,
    const SphereVolume & volume
)


Mark the quads transparency value using a sphere volume.

 

Parameters

[in]

inputWorkspace

The input workspace for the system

[out]

transparencyWorkspace

The TransparencyWorkspace for the system

[in]

volume

The volume primitive to use to mark the quads

 



void GEO_CALL Enlighten::ApplyVolumeTransparency


public: void GEO_CALL ApplyVolumeTransparency
(
    const InputWorkspace * inputWorkspace,
    TransparencyWorkspace * transparencyWorkspace,
    const BoxVolume & volume
)


Mark the quads transparency value using a box volume.

 

Parameters

[in]

inputWorkspace

The input workspace for the system

[out]

transparencyWorkspace

The TransparencyWorkspace for the system

[in]

volume

The volume primitive to use to mark the quads

 



Geo::u32 GEO_CALL Enlighten::CalcBounceBufferSize


public: Geo::u32GEO_CALL CalcBounceBufferSize
(
    const Enlighten::InputWorkspace * inputWorkspace,
    PrecisionHint::Value precision
)


Tells you the amount of memory required to hold bounce lighting for a given system.

 

Parameters

[in]

inputWorkspace

The InputWorkspace for the system.

[in]

precision

The hint to what floating point precision to use.

Returns

Required memory in bytes, 0xFFFFFFFF upon error.

 



Geo::u32 GEO_CALL Enlighten::CalcIncidentLightingBufferSize


public: Geo::u32GEO_CALL CalcIncidentLightingBufferSize
(
    const Enlighten::InputWorkspace * inputWorkspace,
    PrecisionHint::Value precision
)


Tells you the amount of memory required to hold incident lighting for a given system.

 

Parameters

[in]

inputWorkspace

The InputWorkspace for the system.

[in]

precision

The hint to what floating point precision to use.

Returns

Required memory in bytes, 0xFFFFFFFF upon error.

 



size_t Enlighten::CalcRequiredScratchSpaceMemory


public: size_t CalcRequiredScratchSpaceMemory
(
    InputLightBase ** lights,
    Geo::u32 numLights
)


Calculate how much scratchspace memory will be required by the DoDirectInputLighting() function given the lights to be shaded.

 

Parameters

[in]

lights

An array of pointers to input lights.

[in]

numLights

The number of light pointers in the array.

Returns

Required memory in bytes

 



Geo::u32 GEO_CALL Enlighten::CalcTransparencyWorkspaceSize


public: Geo::u32GEO_CALL CalcTransparencyWorkspaceSize
(
    const InputWorkspace * inputWorkspace,
    Geo::s32 numInterpolants,
    PrecisionHint::Value precision
)


Tells you the amount of memory required for the transparency workspace for a given system.

 

Parameters

[in]

inputWorkspace

The InputWorkspace for the system.

[in]

numInterpolants

The maximum number of interpolants to use.

[in]

precision

The floating point precision for intermediate values.

Returns

Required memory in bytes, 0xFFFFFFFF upon error.

 



Geo::u32 GEO_CALL Enlighten::CalcTransparencyWorkspaceSize


public: Geo::u32GEO_CALL CalcTransparencyWorkspaceSize
(
    const InputWorkspace * inputWorkspace,
    Geo::s32 numInterpolants,
    Geo::s32 numLods,
    PrecisionHint::Value precision
)


Tells you the amount of memory required for the transparency workspace for a given system.

 

Parameters

[in]

inputWorkspace

The InputWorkspace for the system.

[in]

numInterpolants

The maximum number of interpolants to use.

[in]

precision

The floating point precision for intermediate values.

[in]

numLods

The number of LODs to use.

Returns

Required memory in bytes, 0xFFFFFFFF upon error.

 



bool GEO_CALL Enlighten::CompareBounceBuffers


public: bool GEO_CALL CompareBounceBuffers
(
    Geo::Statistics & res,
    const Enlighten::BounceBuffer * bufA,
    const Enlighten::BounceBuffer * bufB
)


Compares Returns true if the bounce buffers could be compared.

 

Parameters

[inout]

res

- The result of the comparison. Only written if the function succeeded.

[in]

bufA

- The first BounceBuffer to compare.

[in]

bufB

- The second BounceBuffer to compare.

 



bool GEO_CALL Enlighten::CompareIncidentLightingBuffers


public: bool GEO_CALL CompareIncidentLightingBuffers
(
    Geo::Statistics & res,
    const Enlighten::IncidentLightingBuffer * bufA,
    const Enlighten::IncidentLightingBuffer * bufB
)


Compares Returns true if the lighting buffers could be compared.

 

Parameters

[inout]

res

- The result of the comparison. Only written if the function succeeded.

[in]

bufA

- The first IncidentLightingBuffer to compare.

[in]

bufB

- The second IncidentLightingBuffer to compare.

 



Enlighten::BounceBuffer* GEO_CALL Enlighten::CreateBounceBuffer


public: Enlighten::BounceBuffer *GEO_CALL CreateBounceBuffer
(
    void * memory,
    const Enlighten::InputWorkspace * inputWorkspace,
    PrecisionHint::Value precision
)


Construct a BounceBuffer inside the memory provided.

 

Parameters

[in]

memory

A block of memory (size determined by CalcBounceBufferSize) to store the bounce buffer

[in]

inputWorkspace

The InputWorkspace for the system.

[in]

precision

The hint to what floating point precision to use.

 



Enlighten::IncidentLightingBuffer* GEO_CALL Enlighten::CreateIncidentLightingBuffer


public: Enlighten::IncidentLightingBuffer *GEO_CALL CreateIncidentLightingBuffer
(
    void * memory,
    const Enlighten::InputWorkspace * inputWorkspace,
    PrecisionHint::Value precision
)


Construct an IncidentLightingBuffer inside the memory provided.

 

Parameters

[in]

memory

A block of memory (size determined by CalcIncidentLightingBufferSize) to store the lighting buffer

[in]

inputWorkspace

The InputWorkspace for the system.

[in]

precision

The hint to what floating point precision to use.