Atlassian uses cookies to improve your browsing experience, perform analytics and research, and conduct advertising. Accept all cookies to indicate that you agree to our use of cookies on your device. Atlassian cookies and tracking notice, (opens new window)

Enlighten API 3.10 Documentation
Results will update as you type.
  • class Enlighten IPrecompPackedGeometry
  • class Enlighten IPrecompPackedInstance
  • class Enlighten IPrecompPackedSystem
  • class Enlighten IPrecompProbeSetBuildParameters
  • class Enlighten IPrecompProbeSetRadiosity
  • class Enlighten IPrecompRadiosityNormalTexture
  • class Enlighten IPrecompSystemClustering
  • class Enlighten IPrecompSystemCompressedLightTransport
  • class Enlighten IPrecompSystemDependencies
  • class Enlighten IPrecompSystemDuster
  • class Enlighten IPrecompSystemLightTransport
  • class Enlighten IPrecompSystemPreClustering
  • class Enlighten IPrecompSystemRadiosity
  • class Enlighten IPrecompSystemsDependencies
  • class Enlighten IPrecompute
  • class Enlighten IPrecomputeLoaderCubeMap
  • class Enlighten IPrecomputeLoaderGeometry
  • class Enlighten IPrecomputeLoaderProbeSet
  • class Enlighten IPrecomputeLoaderSystem
  • class Enlighten IPrecompVolumeQuery
  • class Enlighten IProbeSetManager
  • class Enlighten IrradianceOutputDesc
  • class Enlighten ISystemSolutionSpace
  • class Enlighten IThreadGroup
  • class Enlighten IUpdateManager
  • class Enlighten IUpdateManagerWorker
  • class Enlighten IViewVolumeIntersector
  • class Enlighten LightMethodSelector
  • class Enlighten LightTransportPixel
  • class Enlighten LightValue64
  • class Enlighten LightValueIterator
  • class Enlighten Line2D
  • class Enlighten LongRunningProcess
  • class Enlighten LrbCpuTextureSampler
  • class Enlighten MaterialAlbedoSampler
  • class Enlighten MaterialComponentBuffer
  • class Enlighten MaterialEmissiveSampler
  • class Enlighten MaterialGuids
  • class Enlighten MaterialSampler
  • class Enlighten MaterialTransparencySampler
  • class Enlighten MergeGeometry
  • class Enlighten MergeGeometryCache
  • class Enlighten MergeMap
  • class Enlighten MergeProcessParams
  • class Enlighten MergeStats
  • class Enlighten MergeTriGroupParams
  • class Enlighten MetaBlock
  • class Enlighten MetaBlockBuilder
  • class Enlighten MultithreadCpuUpdateManager
  • class Enlighten MultithreadCpuWorker
  • class Enlighten MultithreadCpuWorkerCommon
  • class Enlighten NullGeometryTransparencySampler
  • class Enlighten NullMaterialEmissiveSampler
  • class Enlighten NullMaterialTransparencySampler
  • class Enlighten NullSampler
  • class Enlighten OctreeBuilder
  • class Enlighten OctreeSearchResult
  • class Enlighten OutputOctreeBuilder
  • class Enlighten PackedDusterPoint
  • class Enlighten PipelineCubemap
  • class Enlighten PipelineError
  • class Enlighten PipelineExcludedInstance
  • class Enlighten PipelineGeom
  • class Enlighten PipelineGeometryProperties
  • class Enlighten PipelineGlobalParameters
  • class Enlighten PipelineInstanceParameters
  • class Enlighten PipelineLineWriter
  • class Enlighten PipelineMesh
  • class Enlighten PipelinePaths
  • class Enlighten PipelineProbeRegion
  • class Enlighten PipelineProbeVolume
  • class Enlighten PipelineRadiosityInstance
  • class Enlighten PipelineScene
  • class Enlighten PipelineTransform
  • class Enlighten PointLight
  • class Enlighten PointLightMeta
  • class Enlighten PointProjection
  • class Enlighten PointProjectionOptions
  • class Enlighten PointProjectionScratchMem
  • class Enlighten PointProjectionSurface
  • class Enlighten PointProjectionVersion
    Calendars

You‘re viewing this with anonymous access, so some content might be blocked.
/
class Enlighten MergeGeometry

    This is the documentation for Enlighten.

    class Enlighten MergeGeometry

    Nov 21, 2019

    class Enlighten::MergeGeometry

    This is the very basic geometry description we operate on.

    It's function is to provide a basic wrapper around simple arrays which is will release/delete with itself. You can construct it how you like, but there's some utils to allocate/delete arrays for you. The data is create/freeable in two halfs, geometry related stuff and tri-group/param related stuff.

    Note

    It intentionally doesn't handle "empty" geometry (no verts or indices or both). This case should be handled upstream.

    Functions

    Name Description
    ~MergeGeometry()

    Free all resources.

    BuildMergeGeometryCache()

    Build cache data.

    CacheGetBoxForGroup(Geo::s32)

    Access the cache data.

    CacheGetNumGroups()

    Access the cache data.

    CacheGetNumUniqueVertsInGroup(Geo::s32)

    Access the cache data.

    CacheGetOptimalModelForGroup(Geo::s32)

    Access the cache data.

    CacheGetPrincipleNormalForGroup(Geo::s32)

    Access the cache data.

    CacheGetUniqueVertIndicesInGroup(Geo::s32)

    Access the cache data.

    CacheGetWorldSurfaceAreaForGroup(Geo::s32)

    Access the cache data.

    CacheSetFlagsOnGroup(Geo::s32, Geo::u32)

    Access the cache data.

    CacheTestFlagsOnGroup(Geo::s32, Geo::u32)

    Access the cache data.

    CalculateProjectedArea(const Geo::s32 *, Geo::s32, FitModel const &)

    calculate the total projected area of the passed in groups

    ClearUp()

    Free all memory and reset the class to it's initial state.

    ClearUpGeometry()

    Free just the vertex and index buffer data.

    ClearUpTriGroupsAndParams()

    Free just the tri groups and param data.

    ComputeGroupMaxDistance(Geo::s32, const FitModel &, float)


    Given a vector of points, this computes the least-squares plane.

    ComputeModel(Geo::s32, Geo::s32, FitModel &)


    Given a vector of points, this computes the least-squares plane.

    ComputeModel(Geo::s32, FitModel &)


    Given a vector of points, this computes the least-squares plane.

    ComputeTriNormal(Geo::s32, Geo::s32, Geo::s32)

    Get a single representative normal for a triangle in a MergeGeometry.

    FitPlaneToGroups(const Geo::s32 *, Geo::s32, FitModel &)


    Given a vector of points, this computes the least-squares plane.

    GetMaxGeneralNormalDeviationCosForGroupIdx(Geo::s32)

    access per group data

    GetMaxInitialNormalDeviationCosForGroupIdx(Geo::s32)

    access per group data

    GetMaxPlaneDistanceForGroupIdx(Geo::s32)

    access per group data

    GetOverlapExpansionPercForGroupIdx(Geo::s32)

    access per group data

    GetSignificantAreaRatioForGroupIdx(Geo::s32)

    access per group data

    GetTriPoints(Geo::s32, Geo::GeoPoint3 &, Geo::GeoPoint3 &, Geo::GeoPoint3 &)

    Utility function that is used when computing triangle shrinkage.

    InitialiseGeometry(Geo::s32, Geo::s32)

    Initialise the vertex and index buffers to the given sizes.

    InitialiseTriGroupsAndParams(Geo::TriGroupSelection *, Geo::s32)

    Takes ownership (not a copy) of the tri group selection and creates the trigroup and param arrays.

    IsCacheValid()

    Checks if the cache is valid.

    MergeGeometry()

    Just nulls everything.

    Variables

    Name Description
    Geo::s32 * m_IdxBuffer32

    Vertex indices. Length assume to be a multiple of 3.

    Geo::GeoFileString m_Name

    Name of the geometry that was used to create this MergeGeometry.

    Geo::s32 m_NumIndices

    Length of m_IdxBuffer32.

    Geo::s32 m_NumParams

    Length of the m_TriGroupParams array.

    Geo::s32 m_NumVertices

    Length of m_Vert* arrays.

    Geo::s32 * m_ParamIdxFromGroupIdx

    Maps tri group indices to param indices. Length of num tri groups.

    MergeTriGroupParams * m_TriGroupParams

    Array of params for specific tri groups.

    Geo::TriGroupSelection * m_TriGroupSelection

    The tri groups for this geometry.

    Geo::GeoPoint2 * m_VertChartUVs

    Vertex chart UVs (provided, not generated). Length of m_NumVertices.

    Geo::v128 * m_VertNormals

    Vertex normals. Length of m_NumVertices.

    Geo::v128 * m_VertPositions

    Vertex positions. Length of m_NumVertices.


    Enlighten::MergeGeometry::~MergeGeometry


    public: ~MergeGeometry()


    Free all resources.


    bool Enlighten::MergeGeometry::BuildMergeGeometryCache


    public: bool BuildMergeGeometryCache()


    Build cache data.


    Geo::GeoBoundingBox Enlighten::MergeGeometry::CacheGetBoxForGroup


    public: Geo::GeoBoundingBox CacheGetBoxForGroup
    (
        Geo::s32 groupIdx
    ) const


    Access the cache data.


    Geo::s32 Enlighten::MergeGeometry::CacheGetNumGroups


    public: Geo::s32 CacheGetNumGroups() const


    Access the cache data.


    Geo::s32 Enlighten::MergeGeometry::CacheGetNumUniqueVertsInGroup


    public: Geo::s32 CacheGetNumUniqueVertsInGroup
    (
        Geo::s32 groupIdx
    ) const


    Access the cache data.


    FitModel Enlighten::MergeGeometry::CacheGetOptimalModelForGroup


    public: FitModel CacheGetOptimalModelForGroup
    (
        Geo::s32 groupIdx
    ) const


    Access the cache data.


    Geo::v128 Enlighten::MergeGeometry::CacheGetPrincipleNormalForGroup


    public: Geo::v128 CacheGetPrincipleNormalForGroup
    (
        Geo::s32 groupIdx
    ) const


    Access the cache data.


    const Geo::s32* Enlighten::MergeGeometry::CacheGetUniqueVertIndicesInGroup


    public: const Geo::s32 * CacheGetUniqueVertIndicesInGroup
    (
        Geo::s32 groupIdx
    ) const


    Access the cache data.


    double Enlighten::MergeGeometry::CacheGetWorldSurfaceAreaForGroup


    public: double CacheGetWorldSurfaceAreaForGroup
    (
        Geo::s32 groupIdx
    ) const


    Access the cache data.


    void Enlighten::MergeGeometry::CacheSetFlagsOnGroup


    public: void CacheSetFlagsOnGroup
    (
        Geo::s32 groupIdx,
        Geo::u32 flags
    )


    Access the cache data.


    bool Enlighten::MergeGeometry::CacheTestFlagsOnGroup


    public: bool CacheTestFlagsOnGroup
    (
        Geo::s32 groupIdx,
        Geo::u32 flags
    ) const


    Access the cache data.


    float Enlighten::MergeGeometry::CalculateProjectedArea


    public: float CalculateProjectedArea
    (
        const Geo::s32 * groupIndices,
        Geo::s32 numGroups,
        FitModel const & model
    ) const


    calculate the total projected area of the passed in groups


    void Enlighten::MergeGeometry::ClearUp


    public: void ClearUp()


    Free all memory and reset the class to it's initial state.


    void Enlighten::MergeGeometry::ClearUpGeometry


    public: void ClearUpGeometry()


    Free just the vertex and index buffer data.


    void Enlighten::MergeGeometry::ClearUpTriGroupsAndParams


    public: void ClearUpTriGroupsAndParams()


    Free just the tri groups and param data.


    float Enlighten::MergeGeometry::ComputeGroupMaxDistance


    public: float ComputeGroupMaxDistance
    (
        Geo::s32 groupIdx,
        const FitModel & model,
        float distanceThreshold
    ) const



    Given a vector of points, this computes the least-squares plane.

    The idea is that we want an optimal plane for the given combined groups.


    void Enlighten::MergeGeometry::ComputeModel


    public: void ComputeModel
    (
        Geo::s32 groupIdx0,
        Geo::s32 groupIdx1,
        FitModel & model
    ) const



    Given a vector of points, this computes the least-squares plane.

    The idea is that we want an optimal plane for the given combined groups.


    void Enlighten::MergeGeometry::ComputeModel


    public: void ComputeModel
    (
        Geo::s32 groupIdx,
        FitModel & model
    ) const



    Given a vector of points, this computes the least-squares plane.

    The idea is that we want an optimal plane for the given combined groups.


    Geo::v128 Enlighten::MergeGeometry::ComputeTriNormal


    public: Geo::v128 ComputeTriNormal
    (
        Geo::s32 vertIdx0,
        Geo::s32 vertIdx1,
        Geo::s32 vertIdx2
    ) const


    Get a single representative normal for a triangle in a MergeGeometry.


    void Enlighten::MergeGeometry::FitPlaneToGroups


    public: void FitPlaneToGroups
    (
        const Geo::s32 * groupIndices,
        Geo::s32 numGroups,
        FitModel & model
    ) const



    Given a vector of points, this computes the least-squares plane.

    The idea is that we want an optimal plane for the given combined groups.


    float Enlighten::MergeGeometry::GetMaxGeneralNormalDeviationCosForGroupIdx


    public: float GetMaxGeneralNormalDeviationCosForGroupIdx
    (
        Geo::s32 groupIdx
    ) const


    access per group data


    float Enlighten::MergeGeometry::GetMaxInitialNormalDeviationCosForGroupIdx


    public: float GetMaxInitialNormalDeviationCosForGroupIdx
    (
        Geo::s32 groupIdx
    ) const


    access per group data


    float Enlighten::MergeGeometry::GetMaxPlaneDistanceForGroupIdx


    public: float GetMaxPlaneDistanceForGroupIdx
    (
        Geo::s32 groupIdx
    ) const


    access per group data


    float Enlighten::MergeGeometry::GetOverlapExpansionPercForGroupIdx


    public: float GetOverlapExpansionPercForGroupIdx
    (
        Geo::s32 groupIdx
    ) const


    access per group data


    float Enlighten::MergeGeometry::GetSignificantAreaRatioForGroupIdx


    public: float GetSignificantAreaRatioForGroupIdx
    (
        Geo::s32 groupIdx
    ) const


    access per group data


    void Enlighten::MergeGeometry::GetTriPoints


    public: void GetTriPoints
    (
        Geo::s32 tri,
        Geo::GeoPoint3 & p0,
        Geo::GeoPoint3 & p1,
        Geo::GeoPoint3 & p2
    ) const


    Utility function that is used when computing triangle shrinkage.


    bool Enlighten::MergeGeometry::InitialiseGeometry


    public: bool InitialiseGeometry
    (
        Geo::s32 numVertices,
        Geo::s32 numIndices
    )


    Initialise the vertex and index buffers to the given sizes.

    This will clear any existing vertex and index buffer data first, but leaves all tri group and parameter data untouched.

    The new buffers are initialised with -1 for indices and 0 for all other vertex data.


    bool Enlighten::MergeGeometry::InitialiseTriGroupsAndParams


    public: bool InitialiseTriGroupsAndParams
    (
        Geo::TriGroupSelection * triGroups,
        Geo::s32 numParams
    )


    Takes ownership (not a copy) of the tri group selection and creates the trigroup and param arrays.

    Parameters are left at their defaults, and the mapping is initialised to 0.


    bool Enlighten::MergeGeometry::IsCacheValid


    public: bool IsCacheValid() const


    Checks if the cache is valid.


    Enlighten::MergeGeometry::MergeGeometry


    public: MergeGeometry()


    Just nulls everything.

    , multiple selections available,
    {"serverDuration": 9, "requestCorrelationId": "aa9e0042f9a14542be025622270ac136"}