![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
Go to the source code of this file.
Classes | |
| class | rcContext |
| struct | rcBorderSize |
| Specifies the size of borders around the heightfield. More... | |
| struct | rcConfig |
| struct | rcSpanData |
| struct | rcSpanCache |
| struct | rcSpan |
| struct | rcSpanPool |
| struct | rcRowExt |
| struct | rcEdgeHit |
| struct | rcTempSpan |
| struct | rcHeightfield |
| struct | rcCompactCell |
| Provides information on the content of a cell column in a compact heightfield. More... | |
| struct | rcCompactSpan |
| Represents a span of unobstructed space within a compact heightfield. More... | |
| struct | rcCompactHeightfield |
| struct | rcHeightfieldLayer |
| struct | rcHeightfieldLayerSet |
| struct | rcContour |
| Represents a simple, non-overlapping contour in field space. More... | |
| struct | rcContourSet |
| struct | rcPolyMesh |
| struct | rcPolyMeshDetail |
Macros | |
| #define | EPIC_ADDITION_USE_NEW_RECAST_RASTERIZER 1 |
Typedefs | |
| typedef unsigned int | rcSpanUInt |
| #define EPIC_ADDITION_USE_NEW_RECAST_RASTERIZER 1 |
Contour build flags.
| Enumerator | |
|---|---|
| RC_CONTOUR_TESS_WALL_EDGES | Tessellate solid (impassable) edges during contour simplification. |
| RC_CONTOUR_TESS_AREA_EDGES | Tessellate edges between areas during contour simplification. |
Recast log categories.
| Enumerator | |
|---|---|
| RC_LOG_PROGRESS | A progress log entry. |
| RC_LOG_WARNING | A warning log entry. |
| RC_LOG_ERROR | An error log entry. |
Region partitioning methods
| Enumerator | |
|---|---|
| RC_REGION_MONOTONE | monotone partitioning |
| RC_REGION_WATERSHED | watershed partitioning |
| RC_REGION_CHUNKY | monotone partitioning on small chunks |
Recast performance timer categories.
| Enumerator | |
|---|---|
| RC_TIMER_TOTAL | The user defined total time of the build. |
| RC_TIMER_TEMP | A user defined build time. |
| RC_TIMER_RASTERIZE_TRIANGLES | The time to rasterize the triangles. (See: rcRasterizeTriangle) |
| RC_TIMER_BUILD_COMPACTHEIGHTFIELD | The time to build the compact heightfield. (See: rcBuildCompactHeightfield) |
| RC_TIMER_BUILD_CONTOURS | The total time to build the contours. (See: rcBuildContours) |
| RC_TIMER_BUILD_CONTOURS_TRACE | The time to trace the boundaries of the contours. (See: rcBuildContours) |
| RC_TIMER_BUILD_CONTOURS_SIMPLIFY | The time to simplify the contours. (See: rcBuildContours) |
| RC_TIMER_BUILD_CLUSTERS | The time to link clusters from contours. (See: rcBuildClusters) |
| RC_TIMER_FILTER_BORDER | The time to filter ledge spans. (See: rcFilterLedgeSpans) |
| RC_TIMER_FILTER_WALKABLE | The time to filter low height spans. (See: rcFilterWalkableLowHeightSpans) |
| RC_TIMER_MEDIAN_AREA | The time to apply the median filter. (See: rcMedianFilterWalkableArea) |
| RC_TIMER_FILTER_LOW_OBSTACLES | The time to filter low obstacles. (See: rcFilterLowHangingWalkableObstacles) |
| RC_TIMER_BUILD_POLYMESH | The time to build the polygon mesh. (See: rcBuildPolyMesh) |
| RC_TIMER_MERGE_POLYMESH | The time to merge polygon meshes. (See: rcMergePolyMeshes) |
| RC_TIMER_ERODE_AREA | The time to erode the walkable area. (See: rcErodeWalkableArea) |
| RC_TIMER_MARK_BOX_AREA | The time to mark a box area. (See: rcMarkBoxArea) |
| RC_TIMER_MARK_CYLINDER_AREA | The time to mark a cylinder area. (See: rcMarkCylinderArea) |
| RC_TIMER_MARK_CONVEXPOLY_AREA | The time to mark a convex polygon area. (See: rcMarkConvexPolyArea) |
| RC_TIMER_BUILD_DISTANCEFIELD | The total time to build the distance field. (See: rcBuildDistanceField) |
| RC_TIMER_BUILD_DISTANCEFIELD_DIST | The time to build the distances of the distance field. (See: rcBuildDistanceField) |
| RC_TIMER_BUILD_DISTANCEFIELD_BLUR | The time to blur the distance field. (See: rcBuildDistanceField) |
| RC_TIMER_BUILD_REGIONS | The total time to build the regions. (See: rcBuildRegions, rcBuildRegionsMonotone) |
| RC_TIMER_BUILD_REGIONS_WATERSHED | The total time to apply the watershed algorithm. (See: rcBuildRegions) |
| RC_TIMER_BUILD_REGIONS_EXPAND | The time to expand regions while applying the watershed algorithm. (See: rcBuildRegions) |
| RC_TIMER_BUILD_REGIONS_FLOOD | The time to flood regions while applying the watershed algorithm. (See: rcBuildRegions) |
| RC_TIMER_BUILD_REGIONS_FILTER | The time to filter out small regions. (See: rcBuildRegions, rcBuildRegionsMonotone) |
| RC_TIMER_BUILD_LAYERS | The time to build heightfield layers. (See: rcBuildHeightfieldLayers) |
| RC_TIMER_BUILD_POLYMESHDETAIL | The time to build the polygon mesh detail. (See: rcBuildPolyMeshDetail) |
| RC_TIMER_MERGE_POLYMESHDETAIL | The time to merge polygon mesh details. (See: rcMergePolyMeshDetails) |
| RC_MAX_TIMERS | The maximum number of timers. (Used for iterating timers.) |
| NAVMESH_API DECLARE_LOG_CATEGORY_EXTERN | ( | LogRecast | , |
| Log | , | ||
| All | |||
| ) |
|
inline |
Returns the absolute value.
| [in] | a | The value. |
| NAVMESH_API void rcAddSpan | ( | rcContext * | ctx, |
| rcHeightfield & | hf, | ||
| const int | x, | ||
| const int | y, | ||
| const unsigned short | smin, | ||
| const unsigned short | smax, | ||
| const unsigned char | area, | ||
| const int | flagMergeThr | ||
| ) |
Adds a span to the specified heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | hf | An initialized heightfield. |
| [in] | x | The width index where the span is to be added. [Limits: 0 <= value < rcHeightfield::width] |
| [in] | y | The height index where the span is to be added. [Limits: 0 <= value < rcHeightfield::height] |
| [in] | smin | The minimum height of the span. [Limit: < smax] [Units: vx] |
| [in] | smax | The maximum height of the span. [Limit: <= RC_SPAN_MAX_HEIGHT] [Units: vx] |
| [in] | area | The area id of the span. [Limit: <= RC_WALKABLE_AREA) |
| [in] | flagMergeThr | The merge theshold. [Limit: >= 0] [Units: vx] |
| NAVMESH_API void rcAddSpans | ( | rcContext * | ctx, |
| rcHeightfield & | hf, | ||
| const int | flagMergeThr, | ||
| const rcSpanCache * | cachedSpans, | ||
| const int | nspans | ||
| ) |
| NAVMESH_API rcCompactHeightfield * rcAllocCompactHeightfield | ( | ) |
Allocates a compact heightfield object using the Recast allocator.
| NAVMESH_API rcContourSet * rcAllocContourSet | ( | ) |
Allocates a contour set object using the Recast allocator.
| NAVMESH_API rcHeightfield * rcAllocHeightfield | ( | ) |
Allocates a heightfield object using the Recast allocator.
| NAVMESH_API rcHeightfieldLayerSet * rcAllocHeightfieldLayerSet | ( | ) |
Allocates a heightfield layer set using the Recast allocator.
| NAVMESH_API rcPolyMesh * rcAllocPolyMesh | ( | ) |
Allocates a polygon mesh object using the Recast allocator.
| NAVMESH_API rcPolyMeshDetail * rcAllocPolyMeshDetail | ( | ) |
Allocates a detail mesh object using the Recast allocator.
| NAVMESH_API bool rcBuildCompactHeightfield | ( | rcContext * | ctx, |
| const int | walkableHeight, | ||
| const int | walkableClimb, | ||
| rcHeightfield & | hf, | ||
| rcCompactHeightfield & | chf | ||
| ) |
Builds a compact heightfield representing open space, from a heightfield representing solid space.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [in] | walkableClimb | Maximum ledge height that is considered to still be traversable. [Limit: >=0] [Units: vx] |
| [in] | hf | The heightfield to be compacted. |
| [out] | chf | The resulting compact heightfield. (Must be pre-allocated.) |
This is just the beginning of the process of fully building a compact heightfield. Various filters may be applied applied, then the distance field and regions built. E.g: rcBuildDistanceField and rcBuildRegions
See the rcConfig documentation for more information on the configuration parameters.
| NAVMESH_API bool rcBuildContours | ( | rcContext * | ctx, |
| rcCompactHeightfield & | chf, | ||
| const rcReal | maxError, | ||
| const int | maxEdgeLen, | ||
| rcContourSet & | cset, | ||
| const int | buildFlags | ||
| ) |
Builds a contour set from the region outlines in the provided compact heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | chf | A fully built compact heightfield. |
| [in] | maxError | The maximum distance a simplfied contour's border edges should deviate the original raw contour. [Limit: >=0] [Units: wu] |
| [in] | maxEdgeLen | The maximum allowed length for contour edges along the border of the mesh. [Limit: >=0] [Units: vx] |
| [out] | cset | The resulting contour set. (Must be pre-allocated.) |
| [in] | buildFlags | The build flags. (See: rcBuildContoursFlags) |
The raw contours will match the region outlines exactly. The maxError and maxEdgeLen parameters control how closely the simplified contours will match the raw contours.
Simplified contours are generated such that the vertices for portals between areas match up. (They are considered mandatory vertices.)
Setting maxEdgeLength to zero will disable the edge length feature.
See the rcConfig documentation for more information on the configuration parameters.
| NAVMESH_API bool rcBuildDistanceField | ( | rcContext * | ctx, |
| rcCompactHeightfield & | chf | ||
| ) |
Builds the distance field for the specified compact heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
This is usually the second to the last step in creating a fully built compact heightfield. This step is required before regions are built using rcBuildRegions or rcBuildRegionsMonotone.
After this step, the distance data is available via the rcCompactHeightfield::maxDistance and rcCompactHeightfield::dist fields.
| NAVMESH_API bool rcBuildHeightfieldLayers | ( | rcContext * | ctx, |
| rcCompactHeightfield & | chf, | ||
| const rcBorderSize | borderSize, | ||
| const int | walkableHeight, | ||
| rcHeightfieldLayerSet & | lset | ||
| ) |
Builds a layer set from the specified compact heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | chf | A fully built compact heightfield. |
| [in] | borderSize | The size of the non-navigable border around the heightfield. [Limit: >=0] [Units: vx] |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [out] | lset | The resulting layer set. (Must be pre-allocated.) |
See the rcConfig documentation for more information on the configuration parameters.
| NAVMESH_API bool rcBuildHeightfieldLayersChunky | ( | rcContext * | ctx, |
| rcCompactHeightfield & | chf, | ||
| const rcBorderSize | borderSize, | ||
| const int | walkableHeight, | ||
| const int | chunkSize, | ||
| rcHeightfieldLayerSet & | lset | ||
| ) |
Builds a layer set from the specified compact heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | chf | A fully built compact heightfield. |
| [in] | borderSize | The size of the non-navigable border around the heightfield. [Limit: >=0] [Units: vx] |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [in] | chunkSize | Size of chunk of subregion [Units: vx] |
| [out] | lset | The resulting layer set. (Must be pre-allocated.) |
| NAVMESH_API bool rcBuildHeightfieldLayersMonotone | ( | rcContext * | ctx, |
| rcCompactHeightfield & | chf, | ||
| const rcBorderSize | borderSize, | ||
| const int | walkableHeight, | ||
| rcHeightfieldLayerSet & | lset | ||
| ) |
Builds a layer set from the specified compact heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | chf | A fully built compact heightfield. |
| [in] | borderSize | The size of the non-navigable border around the heightfield. [Limit: >=0] [Units: vx] |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [out] | lset | The resulting layer set. (Must be pre-allocated.) |
See the rcConfig documentation for more information on the configuration parameters.
| NAVMESH_API bool rcBuildPolyMesh | ( | rcContext * | ctx, |
| rcContourSet & | cset, | ||
| const int | nvp, | ||
| rcPolyMesh & | mesh | ||
| ) |
Builds a polygon mesh from the provided contours.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | cset | A fully built contour set. |
| [in] | nvp | The maximum number of vertices allowed for polygons generated during the contour to polygon conversion process. [Limit: >= 3] |
| [out] | mesh | The resulting polygon mesh. (Must be re-allocated.) |
| NAVMESH_API bool rcBuildPolyMeshDetail | ( | rcContext * | ctx, |
| const rcPolyMesh & | mesh, | ||
| const rcCompactHeightfield & | chf, | ||
| const rcReal | sampleDist, | ||
| const rcReal | sampleMaxError, | ||
| rcPolyMeshDetail & | dmesh | ||
| ) |
Builds a detail mesh from the provided polygon mesh.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | mesh | A fully built polygon mesh. |
| [in] | chf | The compact heightfield used to build the polygon mesh. |
| [in] | sampleDist | Sets the distance to use when samping the heightfield. [Limit: >=0] [Units: wu] |
| [in] | sampleMaxError | The maximum distance the detail mesh surface should deviate from heightfield data. [Limit: >=0] [Units: wu] |
| [out] | dmesh | The resulting detail mesh. (Must be pre-allocated.) |
See the rcConfig documentation for more information on the configuration parameters.
| NAVMESH_API bool rcBuildRegions | ( | rcContext * | ctx, |
| rcCompactHeightfield & | chf, | ||
| const int | borderSize, | ||
| const int | minRegionArea, | ||
| const int | mergeRegionArea | ||
| ) |
Builds region data for the heightfield using watershed partitioning.
| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
| [in] | borderSize | The size of the non-navigable border around the heightfield. [Limit: >=0] [Units: vx] |
| [in] | minRegionArea | The minimum number of cells allowed to form isolated island areas. [Limit: >=0] [Units: vx]. |
| [in] | mergeRegionArea | Any regions with a span count smaller than this value will, if possible, be merged with larger regions. [Limit: >=0] [Units: vx] |
| NAVMESH_API bool rcBuildRegionsChunky | ( | rcContext * | ctx, |
| rcCompactHeightfield & | chf, | ||
| const rcBorderSize | borderSize, | ||
| const int | minRegionArea, | ||
| const int | mergeRegionArea, | ||
| const int | chunkSize | ||
| ) |
Builds region data for the heightfield using simple monotone partitioning.
| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
| [in] | borderSize | The size of the non-navigable border around the heightfield. [Limit: >=0] [Units: vx] |
| [in] | minRegionArea | The minimum number of cells allowed to form isolated island areas. [Limit: >=0] [Units: vx]. |
| [in] | mergeRegionArea | Any regions with a span count smaller than this value will, if possible, be merged with larger regions. [Limit: >=0] [Units: vx] |
| [in] | chunkSize | Size of subregion [Units: vx] |
| NAVMESH_API bool rcBuildRegionsMonotone | ( | rcContext * | ctx, |
| rcCompactHeightfield & | chf, | ||
| const rcBorderSize | borderSize, | ||
| const int | minRegionArea, | ||
| const int | mergeRegionArea | ||
| ) |
Builds region data for the heightfield using simple monotone partitioning.
| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
| [in] | borderSize | The size of the non-navigable border around the heightfield. [Limit: >=0] [Units: vx] |
| [in] | minRegionArea | The minimum number of cells allowed to form isolated island areas. [Limit: >=0] [Units: vx]. |
| [in] | mergeRegionArea | Any regions with a span count smaller than this value will, if possible, be merged with larger regions. [Limit: >=0] [Units: vx] |
Non-null regions will consist of connected, non-overlapping walkable spans that form a single contour. Contours will form simple polygons.
If multiple regions form an area that is smaller than minRegionArea, then all spans will be re-assigned to the zero (null) region.
Partitioning can result in smaller than necessary regions. mergeRegionArea helps reduce unecessarily small regions.
See the rcConfig documentation for more information on the configuration parameters.
The region data will be available via the rcCompactHeightfield::maxRegions and rcCompactSpan::reg fields.
| NAVMESH_API void rcCacheSpans | ( | rcContext * | ctx, |
| rcHeightfield & | hf, | ||
| rcSpanCache * | cachedSpans | ||
| ) |
| NAVMESH_API void rcCalcBounds | ( | const rcReal * | verts, |
| int | nv, | ||
| rcReal * | bmin, | ||
| rcReal * | bmax | ||
| ) |
Calculates the bounding box of an array of vertices.
| [in] | verts | An array of vertices. [(x, y, z) * nv] |
| [in] | nv | The number of vertices in the verts array. |
| [out] | bmin | The minimum bounds of the AABB. [(x, y, z)] [Units: wu] |
| [out] | bmax | The maximum bounds of the AABB. [(x, y, z)] [Units: wu] |
| NAVMESH_API void rcCalcGridSize | ( | const rcReal * | bmin, |
| const rcReal * | bmax, | ||
| rcReal | cs, | ||
| int * | w, | ||
| int * | h | ||
| ) |
Calculates the grid size based on the bounding box and grid cell size.
| [in] | bmin | The minimum bounds of the AABB. [(x, y, z)] [Units: wu] |
| [in] | bmax | The maximum bounds of the AABB. [(x, y, z)] [Units: wu] |
| [in] | cs | The xz-plane cell size. [Limit: > 0] [Units: wu] |
| [out] | w | The width along the x-axis. [Limit: >= 0] [Units: vx] |
| [out] | h | The height along the z-axis. [Limit: >= 0] [Units: vx] |
| NAVMESH_API void rcCalcTriNormals | ( | const rcReal * | verts, |
| const int | nv, | ||
| const int * | tris, | ||
| const int | nt, | ||
| rcReal * | norms | ||
| ) |
Calculates the normals of each triangles in an array
| [in] | verts | An array of vertices. [(x, y, z) * nv] |
| [in] | nv | The number of vertices in the verts array. |
| [in] | tris | The triangle vertex indices. [(vertA, vertB, vertC) * nt] |
| [in] | nt | The number of triangles. |
| [out] | norms | The normal vector of each triangle. [(x, y, z) * nt] |
When used with a mixture of rcReal and other types (in practice floats and doubles mixed here) this overridden function will be preferred by the compiler.
|
inline |
Clamps the value to the specified range.
| [in] | v | The value to clamp. |
| [in] | mn | The minimum permitted return value. |
| [in] | mx | The maximum permitted return value. |
| NAVMESH_API void rcClearUnwalkableTriangles | ( | rcContext * | ctx, |
| const rcReal | walkableSlopeAngle, | ||
| const rcReal * | verts, | ||
| int | nv, | ||
| const int * | tris, | ||
| int | nt, | ||
| unsigned char * | areas | ||
| ) |
Sets the area id of all triangles with a slope greater than or equal to the specified value to RC_NULL_AREA.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | walkableSlopeAngle | The maximum slope that is considered walkable. [Limits: 0 <= value < 90] [Units: Degrees] |
| [in] | verts | The vertices. [(x, y, z) * nv] |
| [in] | nv | The number of vertices. |
| [in] | tris | The triangle vertex indices. [(vertA, vertB, vertC) * nt] |
| [in] | nt | The number of triangles. |
| [out] | areas | The triangle area ids. [Length: >= nt] |
Only sets the aread id's for the unwalkable triangles. Does not alter the area id's for walkable triangles.
See the rcConfig documentation for more information on the configuration parameters.
| NAVMESH_API bool rcCopyPolyMesh | ( | rcContext * | ctx, |
| const rcPolyMesh & | src, | ||
| rcPolyMesh & | dst | ||
| ) |
Copies the poly mesh data from src to dst.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | src | The source mesh to copy from. |
| [out] | dst | The resulting detail mesh. (Must be pre-allocated, must be empty mesh.) |
| NAVMESH_API int rcCountSpans | ( | rcContext * | ctx, |
| rcHeightfield & | hf | ||
| ) |
| NAVMESH_API bool rcCreateHeightfield | ( | rcContext * | ctx, |
| rcHeightfield & | hf, | ||
| int | width, | ||
| int | height, | ||
| const rcReal * | bmin, | ||
| const rcReal * | bmax, | ||
| rcReal | cs, | ||
| rcReal | ch, | ||
| bool | bAllocateTempSpanColumns | ||
| ) |
Initializes a new heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | hf | The allocated heightfield to initialize. |
| [in] | width | The width of the field along the x-axis. [Limit: >= 0] [Units: vx] |
| [in] | height | The height of the field along the z-axis. [Limit: >= 0] [Units: vx] |
| [in] | bmin | The minimum bounds of the field's AABB. [(x, y, z)] [Units: wu] |
| [in] | bmax | The maximum bounds of the field's AABB. [(x, y, z)] [Units: wu] |
| [in] | cs | The xz-plane cell size to use for the field. [Limit: > 0] [Units: wu] |
| [in] | ch | The y-axis cell size to use for field. [Limit: > 0] [Units: wu] |
| [in] | bAllocateTempSpanColumns | Indicate if we need to allocate the heightfield's tempSpanColumns. |
See the rcConfig documentation for more information on the configuration parameters.
| NAVMESH_API bool rcErodeWalkableAndLowAreas | ( | rcContext * | ctx, |
| int | radius, | ||
| unsigned int | height, | ||
| unsigned char | areaId, | ||
| unsigned char | filterFlags, | ||
| rcCompactHeightfield & | chf | ||
| ) |
Erodes the walkable area within the heightfield by the specified radius. Additionally, it will mark all spans that are too low (rcMarkLowAreas)
| [in,out] | ctx | The build context to use during the operation. |
| [in] | radius | The radius of erosion. [Limits: 0 < value < 255] [Units: vx] |
| [in] | height | Height threshold [Units: vx] |
| [in] | areaId | The area id to apply [Limit: <= @RC_WALKABLE_AREA] |
| [in] | filterFlags | See: rcFilterLowAreaFlags |
| [in,out] | chf | The populated compact heightfield to erode. |
Basically, any spans that are closer to a boundary or obstruction than the specified radius are marked as unwalkable.
This method is usually called immediately after the heightfield has been built.
| NAVMESH_API bool rcErodeWalkableArea | ( | rcContext * | ctx, |
| int | radius, | ||
| rcCompactHeightfield & | chf | ||
| ) |
Erodes the walkable area within the heightfield by the specified radius.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | radius | The radius of erosion. [Limits: 0 < value < 255] [Units: vx] |
| [in,out] | chf | The populated compact heightfield to erode. |
Basically, any spans that are closer to a boundary or obstruction than the specified radius are marked as unwalkable.
This method is usually called immediately after the heightfield has been built.
| NAVMESH_API void rcFilterLedgeSpans | ( | rcContext * | ctx, |
| const int | walkableHeight, | ||
| const int | walkableClimb, | ||
| const rcNeighborSlopeFilterMode | neighborSlopeFilterMode, | ||
| const rcReal | maxStepFromWalkableSlope, | ||
| const rcReal | ch, | ||
| const int | yStart, | ||
| const int | maxYProcess, | ||
| rcHeightfield & | solid | ||
| ) |
Marks spans that are ledges as not-walkable, by a number of y coords at a time.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [in] | walkableClimb | Maximum ledge height that is considered to still be traversable. [Limit: >=0] [Units: vx] |
| [in] | neighborSlopeFilterMode | Change the way neighbors slope filtering is done. //UE |
| [in] | maxStepFromWalkableSlope | Maximum step height in relation to cs and the walkable angle. [Limit: >= 0] [Units: wu] //UE |
| [in] | ch | Cell height. [Limit: >= 0] [Units: wu] //UE |
| [in,out] | solid | A fully built heightfield. (All spans have been added.) |
| [in] | yStart | y coord to start at |
| [in] | maxYProcess | Max y coords to process (yStart + maxYProcess can be more than solid.height and will be capped to solid.height) |
| NAVMESH_API void rcFilterLedgeSpans | ( | rcContext * | ctx, |
| const int | walkableHeight, | ||
| const int | walkableClimb, | ||
| const rcNeighborSlopeFilterMode | neighborSlopeFilterMode, | ||
| const rcReal | maxStepFromWalkableSlope, | ||
| const rcReal | ch, | ||
| rcHeightfield & | solid | ||
| ) |
Marks spans that are ledges as not-walkable.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [in] | walkableClimb | Maximum ledge height that is considered to still be traversable. [Limit: >=0] [Units: vx] |
| [in] | neighborSlopeFilterMode | Change the way neighbors slope filtering is done. //UE |
| [in] | maxStepFromWalkableSlope | Maximum step height in relation to cs and the walkable angle. [Limit: >= 0] [Units: wu] //UE |
| [in] | ch | Cell height. [Limit: >= 0] [Units: wu] //UE |
| [in,out] | solid | A fully built heightfield. (All spans have been added.) |
A ledge is a span with one or more neighbors whose maximum is further away than walkableClimb from the current span's maximum. This method removes the impact of the overestimation of conservative voxelization so the resulting mesh will not have regions hanging in the air over ledges.
A span is a ledge if: rcAbs(currentSpan.smax - neighborSpan.smax) > walkableClimb
| NAVMESH_API void rcFilterLowHangingWalkableObstacles | ( | rcContext * | ctx, |
| const int | walkableClimb, | ||
| rcHeightfield & | solid | ||
| ) |
Marks non-walkable spans as walkable if their maximum is within walkableClimp of a walkable neighbor.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | walkableClimb | Maximum ledge height that is considered to still be traversable. [Limit: >=0] [Units: vx] |
| [in,out] | solid | A fully built heightfield. (All spans have been added.) |
Allows the formation of walkable regions that will flow over low lying objects such as curbs, and up structures such as stairways.
Two neighboring spans are walkable if: rcAbs(currentSpan.smax - neighborSpan.smax) < waklableClimb
| NAVMESH_API void rcFilterWalkableLowHeightSpans | ( | rcContext * | ctx, |
| int | walkableHeight, | ||
| rcHeightfield & | solid | ||
| ) |
Marks walkable spans as not walkable if the clearance above the span is less than the specified height.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [in,out] | solid | A fully built heightfield. (All spans have been added.) |
For this filter, the clearance above the span is the distance from the span's maximum to the next higher span's minimum. (Same grid column.)
| NAVMESH_API void rcFilterWalkableLowHeightSpansSequences | ( | rcContext * | ctx, |
| int | walkableHeight, | ||
| rcHeightfield & | solid | ||
| ) |
| NAVMESH_API void rcFreeCompactHeightfield | ( | rcCompactHeightfield * | chf | ) |
Frees the specified compact heightfield object using the Recast allocator.
| [in] | chf | A compact heightfield allocated using rcAllocCompactHeightfield |
| NAVMESH_API void rcFreeContourSet | ( | rcContourSet * | cset | ) |
Frees the specified contour set using the Recast allocator.
| [in] | cset | A contour set allocated using rcAllocContourSet |
| NAVMESH_API void rcFreeHeightField | ( | rcHeightfield * | hf | ) |
Frees the specified heightfield object using the Recast allocator.
| [in] | hf | A heightfield allocated using rcAllocHeightfield |
| NAVMESH_API void rcFreeHeightfieldLayerSet | ( | rcHeightfieldLayerSet * | lset | ) |
Frees the specified heightfield layer set using the Recast allocator.
| [in] | lset | A heightfield layer set allocated using rcAllocHeightfieldLayerSet |
| NAVMESH_API void rcFreePolyMesh | ( | rcPolyMesh * | pmesh | ) |
Frees the specified polygon mesh using the Recast allocator.
| [in] | pmesh | A polygon mesh allocated using rcAllocPolyMesh |
| NAVMESH_API void rcFreePolyMeshDetail | ( | rcPolyMeshDetail * | dmesh | ) |
Frees the specified detail mesh using the Recast allocator.
| [in] | dmesh | A detail mesh allocated using rcAllocPolyMeshDetail |
|
inline |
Gets neighbor connection data for the specified direction.
| [in] | s | The span to check. |
| [in] | dir | The direction to check. [Limits: 0 <= value < 4] |
|
inline |
Gets the standard width (x-axis) offset for the specified direction.
| [in] | dir | The direction. [Limits: 0 <= value < 4] |
|
inline |
Gets the standard height (z-axis) offset for the specified direction.
| [in] | dir | The direction. [Limits: 0 <= value < 4] |
| NAVMESH_API int rcGetHeightFieldSpanCount | ( | rcContext * | ctx, |
| rcHeightfield & | hf | ||
| ) |
Returns the number of spans contained in the specified heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | hf | An initialized heightfield. |
| NAVMESH_API void rcMarkBoxArea | ( | rcContext * | ctx, |
| const rcReal * | bmin, | ||
| const rcReal * | bmax, | ||
| unsigned char | areaId, | ||
| rcCompactHeightfield & | chf | ||
| ) |
Applies an area id to all spans within the specified bounding box. (AABB)
| [in,out] | ctx | The build context to use during the operation. |
| [in] | bmin | The minimum of the bounding box. [(x, y, z)] |
| [in] | bmax | The maximum of the bounding box. [(x, y, z)] |
| [in] | areaId | The area id to apply. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | chf | A populated compact heightfield. |
The value of spacial parameters are in world units.
| NAVMESH_API void rcMarkConvexPolyArea | ( | rcContext * | ctx, |
| const rcReal * | verts, | ||
| const int | nverts, | ||
| const rcReal | hmin, | ||
| const rcReal | hmax, | ||
| unsigned char | areaId, | ||
| rcCompactHeightfield & | chf | ||
| ) |
Applies the area id to the all spans within the specified convex polygon.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | verts | The vertices of the polygon [Fomr: (x, y, z) * nverts] |
| [in] | nverts | The number of vertices in the polygon. |
| [in] | hmin | The height of the base of the polygon. |
| [in] | hmax | The height of the top of the polygon. |
| [in] | areaId | The area id to apply. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | chf | A populated compact heightfield. |
The value of spacial parameters are in world units.
The y-values of the polygon vertices are ignored. So the polygon is effectively projected onto the xz-plane at hmin, then extruded to hmax.
| NAVMESH_API void rcMarkCylinderArea | ( | rcContext * | ctx, |
| const rcReal * | pos, | ||
| const rcReal | r, | ||
| const rcReal | h, | ||
| unsigned char | areaId, | ||
| rcCompactHeightfield & | chf | ||
| ) |
Applies the area id to all spans within the specified cylinder.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | pos | The center of the base of the cylinder. [Form: (x, y, z)] |
| [in] | r | The radius of the cylinder. |
| [in] | h | The height of the cylinder. |
| [in] | areaId | The area id to apply. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | chf | A populated compact heightfield. |
The value of spacial parameters are in world units.
| NAVMESH_API bool rcMarkLowAreas | ( | rcContext * | ctx, |
| unsigned int | height, | ||
| unsigned char | areaId, | ||
| rcCompactHeightfield & | chf | ||
| ) |
Marks all spans that have insufficient free space above
| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
| [in] | height | Height threshold [Units: vx] |
| [in] | areaId | The area id to apply [Limit: <= @RC_WALKABLE_AREA] |
| NAVMESH_API void rcMarkWalkableTriangles | ( | rcContext * | ctx, |
| const rcReal | walkableSlopeAngle, | ||
| const rcReal * | verts, | ||
| int | nv, | ||
| const int * | tris, | ||
| int | nt, | ||
| unsigned char * | areas | ||
| ) |
Sets the area id of all triangles with a slope below the specified value to RC_WALKABLE_AREA.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | walkableSlopeAngle | The maximum slope that is considered walkable. [Limits: 0 <= value < 90] [Units: Degrees] |
| [in] | verts | The vertices. [(x, y, z) * nv] |
| [in] | nv | The number of vertices. |
| [in] | tris | The triangle vertex indices. [(vertA, vertB, vertC) * nt] |
| [in] | nt | The number of triangles. |
| [out] | areas | The triangle area ids. [Length: >= nt] |
Only sets the aread id's for the walkable triangles. Does not alter the area id's for unwalkable triangles.
See the rcConfig documentation for more information on the configuration parameters.
| NAVMESH_API void rcMarkWalkableTrianglesCos | ( | rcContext * | ctx, |
| const rcReal | walkableSlopeCos, | ||
| const rcReal * | verts, | ||
| int | nv, | ||
| const int * | tris, | ||
| int | nt, | ||
| unsigned char * | areas | ||
| ) |
Sets the area id of all triangles with a slope below the specified value to RC_WALKABLE_AREA.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | walkableSlopeCos | The cosine of maximum slope that is considered walkable. [Limits: 0 <= value < 1] |
| [in] | verts | The vertices. [(x, y, z) * nv] |
| [in] | nv | The number of vertices. |
| [in] | tris | The triangle vertex indices. [(vertA, vertB, vertC) * nt] |
| [in] | nt | The number of triangles. |
| [out] | areas | The triangle area ids. [Length: >= nt] |
When used with a mixture of rcReal and other types (in practice floats and doubles mixed here) this overridden function will be preferred by the compiler.
|
inline |
Returns the maximum of two values.
| [in] | a | Value A |
| [in] | b | Value B |
| NAVMESH_API bool rcMedianFilterWalkableArea | ( | rcContext * | ctx, |
| rcCompactHeightfield & | chf | ||
| ) |
Applies a median filter to walkable area types (based on area id), removing noise.
| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
This filter is usually applied after applying area id's using functions such as rcMarkBoxArea, rcMarkConvexPolyArea, and rcMarkCylinderArea.
| NAVMESH_API bool rcMergePolyMeshDetails | ( | rcContext * | ctx, |
| rcPolyMeshDetail ** | meshes, | ||
| const int | nmeshes, | ||
| rcPolyMeshDetail & | mesh | ||
| ) |
Merges multiple detail meshes into a single detail mesh.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | meshes | An array of detail meshes to merge. [Size: nmeshes] |
| [in] | nmeshes | The number of detail meshes in the meshes array. |
| [out] | mesh | The resulting detail mesh. (Must be pre-allocated.) |
| NAVMESH_API bool rcMergePolyMeshes | ( | rcContext * | ctx, |
| rcPolyMesh ** | meshes, | ||
| const int | nmeshes, | ||
| rcPolyMesh & | mesh | ||
| ) |
Merges multiple polygon meshes into a single mesh.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | meshes | An array of polygon meshes to merge. [Size: nmeshes] |
| [in] | nmeshes | The number of polygon meshes in the meshes array. |
| [in] | mesh | The resulting polygon mesh. (Must be pre-allocated.) |
When used with a mixture of rcReal and other types (in practice floats and doubles mixed here) this overridden function will be preferred by the compiler.
|
inline |
Returns the minimum of two values.
| [in] | a | Value A |
| [in] | b | Value B |
| NAVMESH_API int rcOffsetPoly | ( | const rcReal * | verts, |
| const int | nverts, | ||
| const rcReal | offset, | ||
| rcReal * | outVerts, | ||
| const int | maxOutVerts | ||
| ) |
Helper function to offset voncex polygons for rcMarkConvexPolyArea.
| [in] | verts | The vertices of the polygon [Form: (x, y, z) * nverts] |
| [in] | nverts | The number of vertices in the polygon. |
| [out] | outVerts | The offset vertices (should hold up to 2 * nverts) [Form: (x, y, z) * return value] |
| [in] | maxOutVerts | The max number of vertices that can be stored to outVerts. |
outVerts. | NAVMESH_API void rcRasterizeTriangle | ( | rcContext * | ctx, |
| const rcReal * | v0, | ||
| const rcReal * | v1, | ||
| const rcReal * | v2, | ||
| const unsigned char | area, | ||
| rcHeightfield & | solid, | ||
| const int | flagMergeThr, | ||
| const int | rasterizationFlags, | ||
| const int * | rasterizationMasks | ||
| ) |
Rasterizes a triangle into the specified heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | v0 | Triangle vertex 0 [(x, y, z)] |
| [in] | v1 | Triangle vertex 1 [(x, y, z)] |
| [in] | v2 | Triangle vertex 2 [(x, y, z)] |
| [in] | area | The area id of the triangle. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | solid | An initialized heightfield. |
| [in] | flagMergeThr | The distance where the walkable flag is favored over the non-walkable flag. [Limit: >= 0] [Units: vx] |
| [in] | rtzFlags | Flags to change the rasterization behavior //UE |
| [in] | rtzMasks | Mask for the rasterization flags [Size: hf.w*hf.h] //UE |
No spans will be added if the triangle does not overlap the heightfield grid.
| NAVMESH_API void rcRasterizeTriangles | ( | rcContext * | ctx, |
| const rcReal * | verts, | ||
| const int | nv, | ||
| const int * | tris, | ||
| const unsigned char * | areas, | ||
| const int | nt, | ||
| rcHeightfield & | solid, | ||
| const int | flagMergeThr, | ||
| const int | rasterizationFlags, | ||
| const int * | rasterizationMasks, | ||
| const rcReal * | vertsbmin, | ||
| const rcReal * | vertsbmax | ||
| ) |
Rasterizes an indexed triangle mesh into the specified heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | verts | The vertices. [(x, y, z) * nv] |
| [in] | nv | The number of vertices. |
| [in] | tris | The triangle indices. [(vertA, vertB, vertC) * nt] |
| [in] | areas | The area id's of the triangles. [Limit: <= RC_WALKABLE_AREA] [Size: nt] |
| [in] | nt | The number of triangles. |
| [in,out] | solid | An initialized heightfield. |
| [in] | flagMergeThr | The distance where the walkable flag is favored over the non-walkable flag. [Limit: >= 0] [Units: vx] |
| [in] | rtzFlags | Flags to change the rasterization behavior //UE |
| [in] | rtzMasks | Mask for the rasterization flags [Size: hf.w*hf.h] //UE |
| [in] | vertsbmin | Min location of the bounding box of verts [(x, y, z)] //UE |
| [in] | vertsbmax | Max location of the bounding box of verts [(x, y, z)] //UE |
Spans will only be added for triangles that overlap the heightfield grid.
| NAVMESH_API void rcRasterizeTriangles | ( | rcContext * | ctx, |
| const rcReal * | verts, | ||
| const int | nv, | ||
| const unsigned short * | tris, | ||
| const unsigned char * | areas, | ||
| const int | nt, | ||
| rcHeightfield & | solid, | ||
| const int | flagMergeThr, | ||
| const int | rasterizationFlags, | ||
| const int * | rasterizationMasks, | ||
| const rcReal * | vertsbmin, | ||
| const rcReal * | vertsbmax | ||
| ) |
Rasterizes an indexed triangle mesh into the specified heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | verts | The vertices. [(x, y, z) * nv] |
| [in] | nv | The number of vertices. |
| [in] | tris | The triangle indices. [(vertA, vertB, vertC) * nt] |
| [in] | areas | The area id's of the triangles. [Limit: <= RC_WALKABLE_AREA] [Size: nt] |
| [in] | nt | The number of triangles. |
| [in,out] | solid | An initialized heightfield. |
| [in] | flagMergeThr | The distance where the walkable flag is favored over the non-walkable flag. [Limit: >= 0] [Units: vx] |
| [in] | rtzFlags | Flags to change the rasterization behavior //UE |
| [in] | rtzMasks | Mask for the rasterization flags [Size: hf.w*hf.h] //UE |
| [in] | vertsbmin | Min location of the bounding box of verts [(x, y, z)] //UE |
| [in] | vertsbmax | Max location of the bounding box of verts [(x, y, z)] //UE |
Spans will only be added for triangles that overlap the heightfield grid.
| NAVMESH_API void rcRasterizeTriangles | ( | rcContext * | ctx, |
| const rcReal * | verts, | ||
| const unsigned char * | areas, | ||
| const int | nt, | ||
| rcHeightfield & | solid, | ||
| const int | flagMergeThr, | ||
| const int | rasterizationFlags, | ||
| const int * | rasterizationMasks, | ||
| const rcReal * | vertsbmin, | ||
| const rcReal * | vertsbmax | ||
| ) |
Rasterizes triangles into the specified heightfield.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | verts | The triangle vertices. [(ax, ay, az, bx, by, bz, cx, by, cx) * nt] |
| [in] | areas | The area id's of the triangles. [Limit: <= RC_WALKABLE_AREA] [Size: nt] |
| [in] | nt | The number of triangles. |
| [in,out] | solid | An initialized heightfield. |
| [in] | flagMergeThr | The distance where the walkable flag is favored over the non-walkable flag. [Limit: >= 0] [Units: vx] |
| [in] | rtzFlags | Flags to change the rasterization behavior //UE |
| [in] | rtzMasks | Mask for the rasterization flags [Size: hf.w*hf.h] //UE |
| [in] | vertsbmin | Min location of the bounding box of verts [(x, y, z)] //UE |
| [in] | vertsbmax | Max location of the bounding box of verts [(x, y, z)] //UE |
Spans will only be added for triangles that overlap the heightfield grid.
| NAVMESH_API void rcReplaceBoxArea | ( | rcContext * | ctx, |
| const rcReal * | bmin, | ||
| const rcReal * | bmax, | ||
| unsigned char | areaId, | ||
| unsigned char | filterAreaId, | ||
| rcCompactHeightfield & | chf | ||
| ) |
Replaces an area id in spans with matching filter area within the specified bounding box. (AABB)
| [in,out] | ctx | The build context to use during the operation. |
| [in] | bmin | The minimum of the bounding box. [(x, y, z)] |
| [in] | bmax | The maximum of the bounding box. [(x, y, z)] |
| [in] | areaId | The area id to apply. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | chf | A populated compact heightfield. |
The value of spacial parameters are in world units.
| NAVMESH_API void rcReplaceConvexPolyArea | ( | rcContext * | ctx, |
| const rcReal * | verts, | ||
| const int | nverts, | ||
| const rcReal | hmin, | ||
| const rcReal | hmax, | ||
| unsigned char | areaId, | ||
| unsigned char | filterAreaId, | ||
| rcCompactHeightfield & | chf | ||
| ) |
Replaces an area id in spans with matching filter area within the specified convex polygon.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | verts | The vertices of the polygon [Fomr: (x, y, z) * nverts] |
| [in] | nverts | The number of vertices in the polygon. |
| [in] | hmin | The height of the base of the polygon. |
| [in] | hmax | The height of the top of the polygon. |
| [in] | areaId | The area id to apply. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | chf | A populated compact heightfield. |
The value of spacial parameters are in world units.
The y-values of the polygon vertices are ignored. So the polygon is effectively projected onto the xz-plane at hmin, then extruded to hmax.
| NAVMESH_API void rcReplaceCylinderArea | ( | rcContext * | ctx, |
| const rcReal * | pos, | ||
| const rcReal | r, | ||
| const rcReal | h, | ||
| unsigned char | areaId, | ||
| unsigned char | filterAreaId, | ||
| rcCompactHeightfield & | chf | ||
| ) |
Replaces an area id in spans with matching filter area within the specified cylinder.
| [in,out] | ctx | The build context to use during the operation. |
| [in] | pos | The center of the base of the cylinder. [Form: (x, y, z)] |
| [in] | r | The radius of the cylinder. |
| [in] | h | The height of the cylinder. |
| [in] | areaId | The area id to apply. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | chf | A populated compact heightfield. |
The value of spacial parameters are in world units.
| NAVMESH_API void rcResetHeightfield | ( | rcHeightfield & | hf | ) |
Resets all spans of heightfield.
| [in,out] | hf | The heightfield to reset. |
| [in] | bmin | The minimum bounds of the field's AABB. [(x, y, z)] [Units: wu] |
| [in] | bmax | The maximum bounds of the field's AABB. [(x, y, z)] [Units: wu] |
| [in,out] | hf | The heightfield toreset. |
|
inline |
Sets the neighbor connection data for the specified direction.
| [in] | s | The span to update. |
| [in] | dir | The direction to set. [Limits: 0 <= value < 4] |
| [in] | i | The index of the neighbor span. |
|
inline |
Returns the square of the value.
| [in] | a | The value. |
Returns the square root of the value.
| [in] | x | The value. |
|
inline |
Swaps the values of the two parameters.
| [in,out] | a | Value A |
| [in,out] | b | Value B |
Performs a vector addition. (v1 + v2)
| [out] | dest | The result vector. [(x, y, z)] |
| [in] | v1 | The base vector. [(x, y, z)] |
| [in] | v2 | The vector to add to v1. [(x, y, z)] |
Performs a vector copy.
| [out] | dest | The result. [(x, y, z)] |
| [in] | v | The vector to copy. [(x, y, z)] |
Derives the cross product of two vectors. (v1 x v2)
| [out] | dest | The cross product. [(x, y, z)] |
| [in] | v1 | A Vector [(x, y, z)] |
| [in] | v2 | A vector [(x, y, z)] |
Returns the distance between two points.
| [in] | v1 | A point. [(x, y, z)] |
| [in] | v2 | A point. [(x, y, z)] |
Returns the square of the distance between two points.
| [in] | v1 | A point. [(x, y, z)] |
| [in] | v2 | A point. [(x, y, z)] |
Derives the dot product of two vectors. (v1 . v2)
| [in] | v1 | A Vector [(x, y, z)] |
| [in] | v2 | A vector [(x, y, z)] |
Performs a scaled vector addition. (v1 + (v2 * s))
| [out] | dest | The result vector. [(x, y, z)] |
| [in] | v1 | The base vector. [(x, y, z)] |
| [in] | v2 | The vector to scale and add to v1. [(x, y, z)] |
| [in] | s | The amount to scale v2 by before adding to v1. |
Selects the maximum value of each element from the specified vectors.
| [in,out] | mx | A vector. (Will be updated with the result.) [(x, y, z)] |
| [in] | v | A vector. [(x, y, z)] |
Selects the minimum value of each element from the specified vectors.
| [in,out] | mn | A vector. (Will be updated with the result.) [(x, y, z)] |
| [in] | v | A vector. [(x, y, z)] |
Normalizes the vector.
| [in,out] | v | The vector to normalize. [(x, y, z)] |