11#ifndef CAL_CORESUBMESH_H
12#define CAL_CORESUBMESH_H
15#include "cal3d/global.h"
16#include "cal3d/vector.h"
51 std::vector<Influence> vectorInfluence;
53 int faceCollapseCount;
65 float springCoefficient;
86 bool reserve(
int vertexCount,
int textureCoordinateCount,
int faceCount,
int springCount);
99 void scale(
float factor);
102 void UpdateTangentVector(
int v0,
int v1,
int v2,
int channel);
105 std::vector<Vertex> m_vectorVertex;
106 std::vector<bool> m_vectorTangentsEnabled;
107 std::vector<std::vector<TangentSpace> > m_vectorvectorTangentSpace;
108 std::vector<std::vector<TextureCoordinate> > m_vectorvectorTextureCoordinate;
109 std::vector<PhysicalProperty> m_vectorPhysicalProperty;
110 std::vector<Face> m_vectorFace;
111 std::vector<Spring> m_vectorSpring;
112 std::vector<CalCoreSubMorphTarget *> m_vectorCoreSubMorphTarget;
113 int m_coreMaterialThreadId;
Definition coresubmorphtarget.h:20
bool setSpring(int springId, const Spring &spring)
Sets a specified spring.
Definition coresubmesh.cpp:496
bool reserve(int vertexCount, int textureCoordinateCount, int faceCount, int springCount)
Reserves memory for the vertices, faces and texture coordinates.
Definition coresubmesh.cpp:334
int getCoreMaterialThreadId()
Returns the ID of the core material thread.
Definition coresubmesh.cpp:67
int addCoreSubMorphTarget(CalCoreSubMorphTarget *pCoreSubMorphTarget)
Adds a core sub morph target.
Definition coresubmesh.cpp:564
bool enableTangents(int mapId, bool enabled)
Enables (and calculates) or disables the storage of tangent spaces.
Definition coresubmesh.cpp:173
bool setTextureCoordinate(int vertexId, int textureCoordinateId, const TextureCoordinate &textureCoordinate)
Sets a specified texture coordinate.
Definition coresubmesh.cpp:520
int getLodCount()
Returns the number of LOD steps.
Definition coresubmesh.cpp:93
std::vector< Vertex > & getVectorVertex()
Returns the vertex vector.
Definition coresubmesh.cpp:296
CalCoreSubmesh()
Constructs the core submesh instance.
Definition coresubmesh.cpp:28
void setLodCount(int lodCount)
Sets the number of LOD steps.
Definition coresubmesh.cpp:427
void scale(float factor)
Scale the Submesh.
Definition coresubmesh.cpp:635
bool setPhysicalProperty(int vertexId, const PhysicalProperty &physicalProperty)
Sets a specified physical property.
Definition coresubmesh.cpp:474
CalCoreSubMorphTarget * getCoreSubMorphTarget(int id)
Provides access to a core sub morph target.
Definition coresubmesh.cpp:587
std::vector< Spring > & getVectorSpring()
Returns the spring vector.
Definition coresubmesh.cpp:251
bool setTangentSpace(int vertexId, int textureCoordinateId, const CalVector &tangent, float crossFactor)
Sets the tangent vector associated with a specified texture coordinate pair.
Definition coresubmesh.cpp:448
int getVertexCount()
Returns the number of vertices.
Definition coresubmesh.cpp:309
std::vector< CalCoreSubMorphTarget * > & getVectorCoreSubMorphTarget()
Returns the core sub morph target vector.
Definition coresubmesh.cpp:620
int getFaceCount()
Returns the number of faces.
Definition coresubmesh.cpp:80
std::vector< std::vector< TextureCoordinate > > & getVectorVectorTextureCoordinate()
Returns the texture coordinate vector-vector.
Definition coresubmesh.cpp:266
int getCoreSubMorphTargetCount()
Returns the number of core sub morph targets.
Definition coresubmesh.cpp:606
void setCoreMaterialThreadId(int coreMaterialThreadId)
Sets the ID of the core material thread.
Definition coresubmesh.cpp:392
std::vector< PhysicalProperty > & getVectorPhysicalProperty()
Returns the physical property vector.
Definition coresubmesh.cpp:237
std::vector< std::vector< TangentSpace > > & getVectorVectorTangentSpace()
Returns the tangent space vector-vector.
Definition coresubmesh.cpp:281
bool setVertex(int vertexId, const Vertex &vertex)
Sets a specified vertex.
Definition coresubmesh.cpp:543
bool isTangentsEnabled(int mapId)
Returns true if tangent vectors are enabled.
Definition coresubmesh.cpp:119
bool setFace(int faceId, const Face &face)
Sets a specified face.
Definition coresubmesh.cpp:410
std::vector< Face > & getVectorFace()
Returns the face vector.
Definition coresubmesh.cpp:223
int getSpringCount()
Returns the number of springs.
Definition coresubmesh.cpp:106
The vector class.
Definition vector.h:37
Definition coresubmesh.h:57
Definition coresubmesh.h:37
Definition coresubmesh.h:43
The core submesh Spring.
Definition coresubmesh.h:63
Definition coresubmesh.h:31
Definition coresubmesh.h:26
Definition coresubmesh.h:48