C# Class BEPUphysics.DataStructures.TriangleMesh

Data structure containing triangle mesh data and its associated bounding box tree.
Mostra file Open project: Indiefreaks/igf Class Usage Examples

Public Methods

Method Description
AddMesh ( Microsoft.Xna.Framework.Graphics.ModelMesh collisionModelMesh, Matrix transform, List vertices, IList indices ) : void

Adds a mesh's vertices and indices to the given lists.

GetVerticesAndIndicesFromModel ( Model collisionModel, Microsoft.Xna.Framework.Vector3 &vertices, int &indices ) : void

Gets an array of vertices and indices from the provided model.

RayCast ( Ray ray, IList hits ) : bool

Tests a ray against the triangle mesh.

RayCast ( Ray ray, RayHit &rayHit ) : bool

Tests a ray against the triangle mesh.

RayCast ( Ray ray, TriangleSidedness sidedness, IList hits ) : bool

Tests a ray against the triangle mesh.

RayCast ( Ray ray, TriangleSidedness sidedness, RayHit &rayHit ) : bool

Tests a ray against the triangle mesh.

RayCast ( Ray ray, float maximumLength, IList hits ) : bool

Tests a ray against the triangle mesh.

RayCast ( Ray ray, float maximumLength, RayHit &rayHit ) : bool

Tests a ray against the triangle mesh.

RayCast ( Ray ray, float maximumLength, TriangleSidedness sidedness, IList hits ) : bool

Tests a ray against the triangle mesh.

RayCast ( Ray ray, float maximumLength, TriangleSidedness sidedness, RayHit &rayHit ) : bool

Tests a ray against the triangle mesh.

RayCast ( Ray ray, int &hitCount ) : bool

Tests a ray against the triangle mesh.

TriangleMesh ( MeshBoundingBoxTreeData data ) : System.Collections.Generic

Constructs a new triangle mesh.

Method Details

AddMesh() public static method

Adds a mesh's vertices and indices to the given lists.
public static AddMesh ( Microsoft.Xna.Framework.Graphics.ModelMesh collisionModelMesh, Matrix transform, List vertices, IList indices ) : void
collisionModelMesh Microsoft.Xna.Framework.Graphics.ModelMesh Model to use for the collision shape.
transform Matrix Transform to apply to the mesh.
vertices List List to receive vertices from the mesh.
indices IList List to receive indices from the mesh.
return void

GetVerticesAndIndicesFromModel() public static method

Gets an array of vertices and indices from the provided model.
public static GetVerticesAndIndicesFromModel ( Model collisionModel, Microsoft.Xna.Framework.Vector3 &vertices, int &indices ) : void
collisionModel Microsoft.Xna.Framework.Graphics.Model Model to use for the collision shape.
vertices Microsoft.Xna.Framework.Vector3 Compiled set of vertices from the model.
indices int Compiled set of indices from the model.
return void

RayCast() public method

Tests a ray against the triangle mesh.
public RayCast ( Ray ray, IList hits ) : bool
ray Ray Ray to test against the mesh.
hits IList Hit data for the ray, if any.
return bool

RayCast() public method

Tests a ray against the triangle mesh.
public RayCast ( Ray ray, RayHit &rayHit ) : bool
ray Ray Ray to test against the mesh.
rayHit BEPUutilities.RayHit Hit data for the ray, if any.
return bool

RayCast() public method

Tests a ray against the triangle mesh.
public RayCast ( Ray ray, TriangleSidedness sidedness, IList hits ) : bool
ray Ray Ray to test against the mesh.
sidedness TriangleSidedness Sidedness to apply to the mesh for the ray cast.
hits IList Hit data for the ray, if any.
return bool

RayCast() public method

Tests a ray against the triangle mesh.
public RayCast ( Ray ray, TriangleSidedness sidedness, RayHit &rayHit ) : bool
ray Ray Ray to test against the mesh.
sidedness TriangleSidedness Sidedness to apply to the mesh for the ray cast.
rayHit BEPUutilities.RayHit Hit data for the ray, if any.
return bool

RayCast() public method

Tests a ray against the triangle mesh.
public RayCast ( Ray ray, float maximumLength, IList hits ) : bool
ray Ray Ray to test against the mesh.
maximumLength float Maximum length of the ray in units of the ray direction's length.
hits IList Hit data for the ray, if any.
return bool

RayCast() public method

Tests a ray against the triangle mesh.
public RayCast ( Ray ray, float maximumLength, RayHit &rayHit ) : bool
ray Ray Ray to test against the mesh.
maximumLength float Maximum length of the ray in units of the ray direction's length.
rayHit BEPUutilities.RayHit Hit data for the ray, if any.
return bool

RayCast() public method

Tests a ray against the triangle mesh.
public RayCast ( Ray ray, float maximumLength, TriangleSidedness sidedness, IList hits ) : bool
ray Ray Ray to test against the mesh.
maximumLength float Maximum length of the ray in units of the ray direction's length.
sidedness TriangleSidedness Sidedness to apply to the mesh for the ray cast.
hits IList Hit data for the ray, if any.
return bool

RayCast() public method

Tests a ray against the triangle mesh.
public RayCast ( Ray ray, float maximumLength, TriangleSidedness sidedness, RayHit &rayHit ) : bool
ray Ray Ray to test against the mesh.
maximumLength float Maximum length of the ray in units of the ray direction's length.
sidedness TriangleSidedness Sidedness to apply to the mesh for the ray cast.
rayHit BEPUutilities.RayHit Hit data for the ray, if any.
return bool

RayCast() public method

Tests a ray against the triangle mesh.
public RayCast ( Ray ray, int &hitCount ) : bool
ray Ray Ray to test against the mesh.
hitCount int Number of hits between the ray and the mesh.
return bool

TriangleMesh() public method

Constructs a new triangle mesh.
public TriangleMesh ( MeshBoundingBoxTreeData data ) : System.Collections.Generic
data MeshBoundingBoxTreeData Data to use to construct the mesh.
return System.Collections.Generic