class Enlighten IPrecompute

This is the documentation for Enlighten.

class Enlighten IPrecompute

class Enlighten::IPrecompute

    └>Geo::IGeoReleasable

The Low Level Enlighten Precompute API.

Enums

Name

Description

Name

Description

EMinimumCompatibleVersion

Controls if Precompute should generate data that can be used by older Enlighten run time APIs.

EStateDump

Controls the amount of reproduction data saved by the IPrecompute tasks.

Functions

Name

Description

Name

Description

AssembleSystemGeometry(const IPrecompInputSystem *, const IPrecompInputGeometry *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompPackedSystem *&)

Assemble system geometry.

CalculateCubeMapSystemDependencies(const IPrecompInputCubeMap *, const IPrecompPackedSystem *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompSystemDependencies *&)

Calculate system dependencies for a cube map.

CalculateProbeSetSystemDependencies(const IPrecompInputProbeSet *, const IPrecompPackedSystem *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompSystemDependencies *&)

Calculate system dependencies for a probe set.

CalculateSystemDependencies(const IPrecompPackedSystem *, const IPrecompPackedSystem *const *, Geo::s32, float, Geo::IGeoProgressProxy *, IPrecompSystemDependencies *&)

Calculate system dependencies for a system.

CalculateSystemDependenciesByDistance(const IPrecompInputSystem *const *, Geo::s32, const IPrecompInputGeometry *const *, Geo::s32, float, bool, Geo::IGeoProgressProxy *, IPrecompSystemsDependencies *&)

Calculate dependencies for the input systems.

ClassifyInstanceAsLightmapOrProbeLit(const Geo::Matrix &, const IPrecompInputGeometry *, float, bool, float, double, eMeshClassificationLightingType &)

Decides whether a given geometry instance should be probe-lit or lightmap-lit based on how good its generated Auto UVs are.

ClassifyInstancesAsContributingProbeLit(const Geo::Matrix *, const IPrecompInputGeometry *const *, const float *, Geo::s32, float, bool *)

Decides which probe-lit instances should be contributing ("Probe Radiosity") and which should not ("Fully Dynamic") based on how much light each instance and its neighbours could block.

CompileClusteringOutput(const IPrecompSystemPreClustering *, const IPrecompSystemClustering *, Geo::IGeoProgressProxy *, IClusteringOutput *&)

Extract some data about the clustering process.

CompileCubeMap(const IPrecompOutputCubeMap *, Enlighten::eSolverType, Geo::IGeoProgressProxy *, IPrecompCubeMapCore *&)

Compile the data from the cube map output object into runtime format.

CompileDepthCubeMap(const IPrecompOutputCubeMap *, IPrecompDepthCubeMap *&)

Compile the depth data from the cube map output object.

CompileInputWorkspace(const IPrecompSystemDuster *, Enlighten::eSolverType, bool, Geo::IGeoProgressProxy *, InputWorkspace *&)

Compile the data from the dusters and radiosity cores into an InputWorkspace.

CompileLightTransportOutput(const IPrecompSystemLightTransport *, Geo::IGeoProgressProxy *, ILightTransportOutput *&)

Extract some data about the light transport process.

CompileMaterialData(const IPrecompSystemDuster *, Geo::IGeoProgressProxy *, ClusterAlbedoWorkspaceMaterialData *&)

Compile the data from the dusters into a ClusterAlbedoWorkspaceMaterialData.

CompileProbeSet(const IPrecompOutputProbeSet *, Enlighten::eSolverType, Geo::IGeoProgressProxy *, IPrecompProbeSetRadiosity *&)

Compile the data from the probeset light transport into runtime format.

CompileRadiosity(const IPrecompSystemCompressedLightTransport *, Enlighten::eSolverType, Geo::IGeoProgressProxy *, IPrecompSystemRadiosity *&)

Compile the data from the light transport into runtime format.

CompileRadiosityNormalTexture(const IPrecompSystemCompressedLightTransport *, IPrecompRadiosityNormalTexture *&)

Compile the radiosity normal texture from the light transport data.

CompressLightTransport(const IPrecompSystemLightTransport *, const IPrecompSystemDuster *, Geo::IGeoProgressProxy *, IPrecompSystemCompressedLightTransport *&)

Compress the data from the light transport into a tighter format.

CreateClustering(const IPrecompSystemPreClustering *, const IPrecompPackedSystem *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompSystemClustering *&)

Create clustering for a system.

CreateCubeMap(const IPrecompInputCubeMap *, const IPrecompSystemClustering *const *, Geo::s32, const IPrecompSystemPreClustering *const *, Geo::IGeoProgressProxy *, IPrecompOutputCubeMap *&)

Run the precompute for a cube map.

CreateLightTransport(const IPrecompPackedSystem *, const IPrecompPackedSystem *const *, Geo::s32, const IPrecompSystemClustering *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompSystemLightTransport *&)

Create the light transport for a system.

CreateOutputProbeOctree(const IPrecompInputProbeOctree *, const IPrecompPackedSystem *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompOutputProbeOctree *&)

Automatically place probes within a volume, based on distance to geometry.

CreatePreClustering(const IPrecompPackedSystem *, const IPrecompPackedSystem *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompSystemPreClustering *&)

Create pre-clustering for a system.

CreateProbeOctree(const IPrecompInputProbeOctree *, const IPrecompPackedSystem *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompProbeOctree *&)

Automatically place probes within a volume, based on distance to geometry.

CreateProbeSet(const IPrecompInputProbeSet *, const IPrecompSystemClustering *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompOutputProbeSet *&)

Create the spherical harmonic data for an SH probe set.

CreateSystemDusters(const IPrecompSystemClustering *, const IPrecompSystemClustering *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompSystemDuster *&)

Create the platform-agnostic runtime input sample points.

CreateSystemDusters(const IPrecompSystemClustering *, const IPrecompSystemClustering *const *, Geo::s32, const PointProjectionSurface *, Geo::s32, const PointProjectionVersion *, Geo::s32, const PointProjectionOptions *, Geo::IGeoProgressProxy *, IPrecompSystemDuster *&)

Create the platform-agnostic runtime input sample points including versions of projected points.

CreateSystemsByVoxelisation(const IPrecompInputSystem *, const IPrecompInputGeometry *const *, Geo::s32, float, Geo::IGeoProgressProxy *, IPrecompGeneratedSystems *&)

Split the input system into automatically generated systems.

CreateSystemsByVoxelisation(const IPrecompInputSystem *, const IPrecompPackedGeometry *const *, Geo::s32, float, Geo::IGeoProgressProxy *, IPrecompGeneratedSystems *&)

Split the input system into automatically generated systems.

CreateVisibilityData(const IPrecompSystemClustering *, const IPrecompSystemClustering *const *, Geo::s32, Geo::IGeoProgressProxy *, PrecomputedVisibilityData *&)

Create precomputed visibility data for directional lights for a system.

DumpInputProbeRegion(const IPrecompInputProbeRegion *, const char *)

Dump debug data for a probe region.

ExtractOctreeProbeSet(const IPrecompOutputProbeOctree *, Geo::s32, IPrecompInputProbeSet *&)

Extract a probe set containing automatically placed probes from a probe octree.

ExtractOctreeProbeSet(const IPrecompOutputProbeOctree *, Geo::s32, IPrecompInputProbeSet *&, IPrecompSystemDependencies *&)

Extract a probe set containing automatically placed probes from a probe octree.

LicenseDaysRemaining()

Number of full days remaining for the set license. Returns -1 if the set license is invalid and/or outdated.

PackGeometry(const IPrecompInputGeometry *, Geo::IGeoProgressProxy *, IPrecompPackedGeometry *&)

Simplify and pack geometry meshes.

PackSystem(const IPrecompInputSystem *, const IPrecompPackedGeometry *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompPackedSystem *&)

Pack systems.

ProjectGeometry(const IPrecompInputGeometry *, const IPrecompPackedGeometry *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompPackedGeometry *&)

Project detail meshes in an pInputGeometry onto target clusters from pBaseGeometries This is guaranteed not to change the pInputGeometry and pBaseGeometries in any way, so can be done after a precompute to get new UVs for a detail mesh that was not known about when the last precompute was run.

ProjectSystem(const IPrecompInputSystem *, const IPrecompInputGeometry *const *, Geo::s32, const IPrecompInputSystem *, const IPrecompPackedGeometry *const *, Geo::s32, const Geo::Geo2DTransform *, Geo::IGeoProgressProxy *, IPrecompPackedSystem *&)

Project a system comprised entirely of detail mesh instances across another system.

Release()

Free this object that was created within the Enlighten libraries.

SetCpuGpuMode(Geo::ECpuGpuMode)

Sets the hardware mode for the Enlighten precompute.

SetCpuThreadMax(Geo::s32)

Sets the maximum number of threads that the Cpu mode will use.

SetLicense(const char *, Geo::s32)

Set the license string. Must set before any precompute action.

SetMaxConcurrentRays(Geo::s32)

Sets the total number of rays that the precompute will generate at one time. Set this only if you are concerned about memory pressure.

SetMinimumCompatibleVersion(EMinimumCompatibleVersion)

Sets the minimum version of Enlighten, precompute should generate data for (default is emcvEnlighten3).

SetStateDump(EStateDump)

Sets the level of reproduction data saved by the IPrecompute tasks.

SetStateDumpFolder(const char *)

Sets the folder that shall contain reproduction data for the IPrecompute tasks.

StitchProbeOctree(const IPrecompProbeOctree *, const IPrecompProbeOctreeLayout *const *, Geo::s32, Geo::IGeoProgressProxy *, IPrecompOutputProbeOctree *&)

Stitch one octree with others to produce an output probe octree.

ValidateBuildParameters(const IPrecompInputSystem *, const IPrecompInputGeometry *const *, Geo::s32, bool, bool, Geo::IGeoProgressProxy *)

Examine the incoming data and determine if the supplied parameters will violate memory or reasonable performance limits.

ValidateGeometryParameters(const IPrecompInputGeometry *, Geo::s32 *, Geo::IGeoProgressProxy *)

Examine the incoming geometry and determine if the supplied parameters violate memory and performance limits.



EMinimumCompatibleVersion


public: enum EMinimumCompatibleVersion
{
    emcvEnlighten3
}


Controls if Precompute should generate data that can be used by older Enlighten run time APIs.

enumerators

emcvEnlighten3

Generate precompute data that can be consumed by Enlighten3 (and later) API.



EStateDump


public: enum EStateDump
{
    esdNone,
    esdInputsOnly,
    esdAll
}


Controls the amount of reproduction data saved by the IPrecompute tasks.

enumerators

esdNone

Do not save any dump files.

esdInputsOnly

Save files containing the inputs provided by the user.

esdAll

Save files at the input to every task, including generated files.



virtual Geo::s32 Enlighten::IPrecompute::AssembleSystemGeometry


public: Geo::s32 AssembleSystemGeometry
(
    const IPrecompInputSystem * pSystem,
    const IPrecompInputGeometry *const * ppInputGeometry,
    Geo::s32 numGeometries,
    Geo::IGeoProgressProxy * progress,
    IPrecompPackedSystem *& oSystem
)


Assemble system geometry.

If a system is going to be used as probe radiosity, then the input processing is greatly reduced (there is no need to pack the geometry and create the UV chart mappings).

Parameters

[in]

pSystem

The system to pack

[in]

ppInputGeometry

The geometry referred to (by Id) in this system's PrecompInputInstances. You may pass more geometry items than are necessary, but all Id's used in the instances must have a packed geometry available.

[in]

numGeometries

The number of packed geometry classes in the above array

[in]

progress

This object is updated during this function call to give feedback on progress

[out]

oSystem

The final packed system

 



virtual Geo::s32 Enlighten::IPrecompute::CalculateCubeMapSystemDependencies


public: Geo::s32 CalculateCubeMapSystemDependencies
(
    const IPrecompInputCubeMap * pCubeMap,
    const IPrecompPackedSystem *const * ppSystems,
    Geo::s32 numSystems,
    Geo::IGeoProgressProxy * progress,
    IPrecompSystemDependencies *& oDependencies
)


Calculate system dependencies for a cube map.

Each IPrecompInputCubeMap may have dependencies calculated by calling this function on it. All packed systems which are fully loaded will have their geometry fully represented in the visibility tests. Packed systems which only have a header (ie whose geometry isn't loaded) will be represented by their bounding boxes in the visibility tests. (In the HLBS these sets of systems are controlled by the "expansionDistance" parameter.)

Parameters

[in]

pCubeMap

The cube map for which to calculate dependencies

[in]

ppSystems

The list of systems to include in this calculation.

[in]

numSystems

The number of packed systems in the above array

[in]

progress

This object is updated during this function call to give feedback on progress

[out]

oDependencies

The approximate set of system dependencies, which may be fed back into the precompute.

 



virtual Geo::s32 Enlighten::IPrecompute::CalculateProbeSetSystemDependencies


public: Geo::s32 CalculateProbeSetSystemDependencies
(
    const IPrecompInputProbeSet * pProbeInput,
    const IPrecompPackedSystem *const * ppSystems,
    Geo::s32 numSystems,
    Geo::IGeoProgressProxy * progress,
    IPrecompSystemDependencies *& oDependencies
)


Calculate system dependencies for a probe set.

Each IPrecompInputProbeSet may have dependencies calculated by calling this function on it. The collection of systems passed in determines the connectivity between them, so completely isolated systems have a numSystems of 1. All packed systems which are fully loaded will have their geometry fully represented in the visibility tests. Packed systems which only have a header (ie whose geometry isn't loaded) will be represented by their bounding boxes in the visibility tests. (In the HLBS these sets of systems are controlled by the "expansionDistance" parameter.)

Parameters

[in]

pProbeInput

The probe set for which to calculate dependencies

[in]

ppSystems

The list of systems to include in this calculation.

[in]

numSystems

The number of packed systems in the above array

[in]

progress

This object is updated during this function call to give feedback on progress

[out]

oDependencies

The approximate set of system dependencies, which may be fed back into the precompute.

 



virtual Geo::s32 Enlighten::IPrecompute::CalculateSystemDependencies


public: Geo::s32 CalculateSystemDependencies
(
    const IPrecompPackedSystem * pSystem,
    const IPrecompPackedSystem *const * ppSystems,
    Geo::s32 numSystems,
    float rayOriginsPerPixelArea,
    Geo::IGeoProgressProxy * progress,
    IPrecompSystemDependencies *& oDependencies
)


Calculate system dependencies for a system.

Each IPrecompInputSystem may have dependencies calculated by calling this function on it. The collection of systems passed in determines the connectivity between them, so completely isolated systems have a numSystems of 1. All packed systems which are fully loaded will have their geometry fully represented in the visibility tests. Packed systems which only have a header (ie whose geometry isn't loaded) will be represented by their bounding boxes in the visibility tests. (In the HLBS these sets of systems are controlled by the "expansionDistance" parameter.)

Parameters

[in]

pSystem

The system for which to calculate dependencies

[in]

ppSystems

The list of systems to include in this calculation. It must include at least the system in the previous argument.

[in]

numSystems

The number of packed systems in the above array

[in]

rayOriginsPerPixelArea

Density of ray origins - i.e. num of ray origins = rayOriginsPerPixelArea * SystemWorldArea/(minSystemPixelSize^2)

[in]

progress

This object is updated during this function call to give feedback on progress

[out]

oDependencies

The approximate set of system dependencies, which may be fed back into the precompute.

 



virtual Geo::s32 Enlighten::IPrecompute::CalculateSystemDependenciesByDistance


public: Geo::s32 CalculateSystemDependenciesByDistance
(
    const IPrecompInputSystem *const * pInputSystems,
    Geo::s32 numSystems,
    const IPrecompInputGeometry *const * pInputGeoms,
    Geo::s32 numGeoms,
    float maxDistanceInPixelSizeUnits,
    bool estimateFromCentre,
    Geo::IGeoProgressProxy * progress,
    IPrecompSystemsDependencies *& oDependencies
)


Calculate dependencies for the input systems.

System A is dependent on system B if the centres of A and B are at a distance equal or smaller than the maxDistanceInPixelSizeUnits multiplied by the minimum pixel size of the instances in system B.

Parameters

[in]

pInputSystems

The input systems that will get their dependencies calculated.

[in]

numSystems

The number of input systems

[in]

pInputGeoms

A collection of input geometry objects, referred to by the input systems above.

[in]

numGeoms

How many entries in the pInputGeometry array.

[in]

maxDistanceInPixelSizeUnits

If system A's bounding box is closer than maxDistanceInPixelSizeUnits * (minPixelSize of system B) to system's B bounding box, than system A is dependent on system B. minPixelSize of a system is a minimal value of an output pixel size present among input instances making up that system.

[in]

estimateFromCentre

If true the distance between bounding box centres is evaluated, if false the actual distance between the bounding boxes is considered (i.e. overlapping bounding boxes have a distance of less than zero.

[in]

progress

This object is updated during this function call to give feedback on progress.

[out]

oDependencies

Dependencies for the input systems.