Struct Mesh
- Assembly
- ValveResourceFormat.dll
Represents a mesh shape.
public readonly struct Mesh
Inherited Members
Constructors
Mesh(KVObject)
Initializes a new instance of the ValveResourceFormat.ResourceTypes.RubikonPhysics.Shapes.Mesh struct.
public Mesh(KVObject data)
Parameters
data
KVObject
Properties
Data
Gets the raw data.
public KVObject Data { get; }
Property Value
Materials
Per triangle index to surface properties. Can be empty if the whole mesh has the same material.
public int[] Materials { get; }
Property Value
- int[]
Max
Gets the maximum bounds.
public Vector3 Max { get; }
Property Value
Min
Gets the minimum bounds.
public Vector3 Min { get; }
Property Value
OrthographicAreas
Fraction 0..1 of coverage along YZ,ZX,XY sides of AABB
public Vector3 OrthographicAreas { get; }
Property Value
Methods
GetTriangles()
The mesh triangles with additional topology information similar to the half-edge data structure.
public ReadOnlySpan<Mesh.Triangle> GetTriangles()
Returns
GetVertices()
The mesh vertices in the space of the parent shape.
public ReadOnlySpan<Vector3> GetVertices()
Returns
ParseNodes()
The nodes of the loose kd-tree to accelerate ray casts and volume queries against this mesh.
public ReadOnlySpan<Mesh.Node> ParseNodes()