class Enlighten MergeGeometry

This is the documentation for Enlighten.

class Enlighten MergeGeometry

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

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