| Description | Hierarchy | Fields | Methods | Properties |
type TMeshManipulator = class(TReferenceCounted)
An interface for easy manipulation of meshes. Scale, set alpha value, flip surfaces, and so on. This exists for fixing problems with wrong imported or exported meshes quickly after loading. It is not intended for doing mesh modifications and/or animations during runtime.
![]() |
function Apply(Func: TMeshManipulatorMethod; Mesh: TMesh; UpdateBoundingBox: Boolean=False): Boolean; overload; inline; |
![]() |
function Apply(Func: TMeshManipulatorMethod; Buffer: TMeshBuffer; UpdateBoundingBox: Boolean=False): Boolean; overload; inline; |
![]() |
function Apply(Func: TMeshManipulatorFunction; Mesh: TMesh; UpdateBoundingBox: Boolean=False): Boolean; overload; inline; |
![]() |
function Apply(Func: TMeshManipulatorFunction; Buffer: TMeshBuffer; UpdateBoundingBox: Boolean=False): Boolean; overload; inline; |
![]() |
function CreateAnimatedMesh(Mesh: TMesh; MeshType: TAnimatedMeshType = amUnknown): TAnimatedMesh; inline; |
![]() |
function CreateMeshCopy(Mesh: TMesh): TMesh; inline; |
![]() |
function CreateMeshUniquePrimitives(Mesh: TMesh): TMesh; inline; |
![]() |
function CreateMeshWelded(Mesh: TMesh; Tolerance: Single = 0.000001): TMesh; inline; |
![]() |
function CreateMeshWith1TCoords(Mesh: TMesh): TMesh; inline; |
![]() |
function CreateMeshWith2TCoords(Mesh: TMesh): TMesh; inline; |
![]() |
function CreateMeshWithTangents(Mesh: TMesh; RecalculateNormals: Boolean = False; Smooth: Boolean = False; AngleWeighted: Boolean = False; RecalculateTangents: Boolean = True): TMesh; inline; |
![]() |
function GetPolyCount(Mesh: TMesh): LongInt; overload; inline; |
![]() |
function GetPolyCount(Mesh: TAnimatedMesh): LongInt; overload; inline; |
![]() |
procedure FlipSurfaces(Mesh: TMesh); inline; |
![]() |
procedure MakePlanarTextureMapping(Mesh: TMesh; Resolution: Single = 0.001); inline; |
![]() |
procedure MakePlanarTextureMapping(Buffer: TMeshBuffer; Resolution: Single = 0.001); overload; inline; |
![]() |
procedure MakePlanarTextureMapping(Buffer: TMeshBuffer; ResolutionS, ResolutionT: Single; Axis: Byte; const Offset: TVector3D); overload; inline; |
![]() |
procedure RecalculateNormals(Mesh: TMesh; Smooth: Boolean = False; AngleWeighted: Boolean = False); overload; inline; |
![]() |
procedure RecalculateNormals(Buffer: TMeshBuffer; Smooth: Boolean = False; AngleWeighted: Boolean = False); overload; inline; |
![]() |
procedure RecalculateTangents(Mesh: TMesh; RecalculateNormals: Boolean = False; Smooth: Boolean = False; AngleWeighted: Boolean = False); inline; |
![]() |
procedure Scale(Mesh: TMesh; const Factor: TVector3D); overload; inline; |
![]() |
procedure Scale(Buffer: TMeshBuffer; const Factor: TVector3D); overload; inline; |
![]() |
procedure ScaleTCoords(Mesh: TMesh; const Factor: TVector2D; Level: LongWord=1); overload; inline; |
![]() |
procedure ScaleTCoords(Buffer: TMeshBuffer; const Factor: TVector2D; Level: LongWord=1); overload; inline; |
![]() |
procedure SetVertexColorAlpha(Mesh: TMesh; Alpha: LongInt); overload; inline; |
![]() |
procedure SetVertexColors(Mesh: TMesh; Color: TARGBColor); overload; inline; |
![]() |
procedure Transform(Mesh: TMesh; const Matrix: TMatrix4); overload; inline; |
![]() |
procedure Transform(Buffer: TMeshBuffer; const Matrix: TMatrix4); overload; inline; |
![]() |
function Apply(Func: TMeshManipulatorMethod; Mesh: TMesh; UpdateBoundingBox: Boolean=False): Boolean; overload; inline; |
|
Apply a member function manipulator on the Mesh. Parameters
ReturnsTrue if the functor was successfully applied, else false. | |
![]() |
function Apply(Func: TMeshManipulatorMethod; Buffer: TMeshBuffer; UpdateBoundingBox: Boolean=False): Boolean; overload; inline; |
|
Parameters
ReturnsTrue if the functor was successfully applied, else false. | |
![]() |
function Apply(Func: TMeshManipulatorFunction; Mesh: TMesh; UpdateBoundingBox: Boolean=False): Boolean; overload; inline; |
|
Apply a manipulator on the Mesh. Parameters
ReturnsTrue if the functor was successfully applied, else false. | |
![]() |
function Apply(Func: TMeshManipulatorFunction; Buffer: TMeshBuffer; UpdateBoundingBox: Boolean=False): Boolean; overload; inline; |
|
Apply a manipulator on a MeshBuffer. Parameters
ReturnsTrue if the functor was successfully applied, else false. | |
![]() |
function CreateAnimatedMesh(Mesh: TMesh; MeshType: TAnimatedMeshType = amUnknown): TAnimatedMesh; inline; |
|
Create a new AnimatedMesh and adds the mesh to it. Parameters
ReturnsNewly created animated mesh with mesh as its only content. When you don't need the animated mesh anymore, you should call TAnimatedMesh.Drop(). See TReferenceCounted.Drop() for more information. | |
![]() |
function CreateMeshCopy(Mesh: TMesh): TMesh; inline; |
|
Clones a static IMesh into a modifiable SMesh. Parameters
ReturnsThe Cloned mesh. If you no longer need the cloned mesh, you should call TMesh.Drop(). See TReferenceCounted.Drop() for more information. | |
![]() |
function CreateMeshUniquePrimitives(Mesh: TMesh): TMesh; inline; |
|
Creates a copy of a mesh with all vertices unwelded. Parameters
ReturnsMesh consisting only of unique faces. All vertices which were previously shared are now duplicated. If you no longer need the cloned mesh, you should call TMesh.Drop(). See TReferenceCounted.Drop() for more information. | |
![]() |
function CreateMeshWelded(Mesh: TMesh; Tolerance: Single = 0.000001): TMesh; inline; |
|
Creates a copy of a mesh with vertices welded. Parameters
ReturnsMesh without redundant vertices. If you no longer need the cloned mesh, you should call TMesh.Drop(). See TReferenceCounted.Drop() for more information. | |
![]() |
function CreateMeshWith1TCoords(Mesh: TMesh): TMesh; inline; |
|
Creates a copy of the mesh, which will only consist of TVertex vertices. Parameters
ReturnsMesh consisting only of TVertex vertices. If you no longer need the cloned mesh, you should call TMesh.Drop(). See TReferenceCounted.Drop() for more information. | |
![]() |
function CreateMeshWith2TCoords(Mesh: TMesh): TMesh; inline; |
|
Creates a copy of the mesh, which will only consist of TVertex2TCoords vertices. Parameters
ReturnsMesh consisting only of TVertex2TCoords vertices. If you no longer need the cloned mesh, you should call TMesh.Drop(). See TReferenceCounted.Drop() for more information. | |
![]() |
function CreateMeshWithTangents(Mesh: TMesh; RecalculateNormals: Boolean = False; Smooth: Boolean = False; AngleWeighted: Boolean = False; RecalculateTangents: Boolean = True): TMesh; inline; |
|
Creates a copy of the mesh, which will only consist of S3DVertexTangents vertices. Parameters
ReturnsMesh consisting only of S3DVertexTangents vertices. If you no longer need the cloned mesh, you should call TMesh.Drop(). See TReferenceCounted.Drop() for more information. | |
![]() |
function GetPolyCount(Mesh: TMesh): LongInt; overload; inline; |
|
Get amount of polygons in mesh. Parameters
ReturnsNumber of polygons in mesh. | |
![]() |
function GetPolyCount(Mesh: TAnimatedMesh): LongInt; overload; inline; |
|
Get amount of polygons in mesh. Parameters
ReturnsNumber of polygons in mesh. | |
![]() |
procedure FlipSurfaces(Mesh: TMesh); inline; |
|
Flips the direction of surfaces. Parameters
| |
![]() |
procedure MakePlanarTextureMapping(Mesh: TMesh; Resolution: Single = 0.001); inline; |
|
Creates a planar texture mapping on the mesh. Parameters
| |
![]() |
procedure MakePlanarTextureMapping(Buffer: TMeshBuffer; Resolution: Single = 0.001); overload; inline; |
|
Creates a planar texture mapping on the meshbuffer. Parameters
| |
![]() |
procedure MakePlanarTextureMapping(Buffer: TMeshBuffer; ResolutionS, ResolutionT: Single; Axis: Byte; const Offset: TVector3D); overload; inline; |
|
Creates a planar texture mapping on the meshbuffer. Parameters
| |
![]() |
procedure RecalculateNormals(Mesh: TMesh; Smooth: Boolean = False; AngleWeighted: Boolean = False); overload; inline; |
|
Recalculates all normals of the mesh. Parameters
| |
![]() |
procedure RecalculateNormals(Buffer: TMeshBuffer; Smooth: Boolean = False; AngleWeighted: Boolean = False); overload; inline; |
|
Recalculates all normals of the mesh buffer. Parameters
| |
![]() |
procedure RecalculateTangents(Mesh: TMesh; RecalculateNormals: Boolean = False; Smooth: Boolean = False; AngleWeighted: Boolean = False); inline; |
|
Recalculates tangents, requires a tangent mesh. Parameters
| |
![]() |
procedure Scale(Mesh: TMesh; const Factor: TVector3D); overload; inline; |
|
Scales the actual mesk not a scene node. Parameters
| |
![]() |
procedure Scale(Buffer: TMeshBuffer; const Factor: TVector3D); overload; inline; |
|
Scales the actual meshbuffer, not a scene node. Parameters
| |
![]() |
procedure ScaleTCoords(Mesh: TMesh; const Factor: TVector2D; Level: LongWord=1); overload; inline; |
|
Scale the texture coords of a mesh. Parameters
| |
![]() |
procedure ScaleTCoords(Buffer: TMeshBuffer; const Factor: TVector2D; Level: LongWord=1); overload; inline; |
|
Scale the texture coords of a meshbuffer. Parameters
| |
![]() |
procedure SetVertexColorAlpha(Mesh: TMesh; Alpha: LongInt); overload; inline; |
|
Sets the alpha vertex color value of the whole mesh to a new value. Parameters
| |
![]() |
procedure SetVertexColors(Mesh: TMesh; Color: TARGBColor); overload; inline; |
|
Sets the colors of all vertices to one color. Parameters
| |
![]() |
procedure Transform(Mesh: TMesh; const Matrix: TMatrix4); overload; inline; |
|
Applies a transformation to a mesh. Parameters
| |
![]() |
procedure Transform(Buffer: TMeshBuffer; const Matrix: TMatrix4); overload; inline; |
|
Applies a transformation to a meshbuffer. Parameters
| |