19#include "Topology/TriangleSet.h"
63 template<
typename TDataType>
69 typedef typename TDataType::Real
Real;
70 typedef typename TDataType::Coord
Coord;
71 typedef typename TDataType::Matrix
Matrix;
76 typedef unsigned char byte;
91 DEF_VAR(
bool, ImportAnimation,
false,
"");
95 DEF_VAR(
bool, UseInstanceTransform,
true,
"");
#define IMPLEMENT_TCLASS(name, T1)
DEF_VAR(Vec3f, LowerBound, Vec3f(0), "")
DECLARE_CLASS(BoundingBoxOfTextureMesh)
DEF_VAR(uint, ShapeId, 0, "")
DEF_INSTANCE_OUT(EdgeSet< DataType3f >, BoundingBox, "")
DEF_VAR(Vec3f, Center, Vec3f(0), "")
BoundingBoxOfTextureMesh()
DEF_INSTANCE_IN(TextureMesh, TextureMesh, "")
DEF_VAR(Vec3f, UpperBound, Vec3f(0), "")
DArray< Coord > d_ShapeCenter
std::map< joint, Vec3f > joint_scale
std::map< joint, Vec3i > joint_output
void updateAnimation(int frameNumber)
DArray< Mat4f > d_mesh_Matrix
DEF_ARRAY_STATE(Mat4f, JointLocalMatrix, DeviceType::GPU, "JointLocalMatrix")
DEF_ARRAY_STATE(Mat4f, InitialMatrix, DeviceType::GPU, "")
Vec3f getVertexLocationWithJointTransform(joint jointId, Vec3f inPoint, std::map< joint, Mat4f > jMatrix)
DArray< Coord > initialNormal
std::map< joint, std::vector< int > > jointId_joint_Dir
DEF_INSTANCE_STATE(PointSet< TDataType >, ShapeCenter, "")
DECLARE_TCLASS(GltfLoader, TDataType)
std::map< joint, std::string > joint_Name
DEF_INSTANCE_STATE(JointAnimationInfo, Animation,"")
DEF_ARRAY_STATE(Vec2f, TexCoord_0, DeviceType::GPU, "UVSet 0")
std::map< int, Mat4f > node_matrix
DEF_VAR(bool, ImportAnimation, false, "")
DEF_VAR(FilePath, FileName, "", "")
std::map< joint, Vec3f > joint_translation
DEF_ARRAY_STATE(Mat4f, JointWorldMatrix, DeviceType::GPU, "JointWorldMatrix")
DEF_INSTANCE_STATE(TextureMesh, TextureMesh, "")
DEF_VAR(bool, UseInstanceTransform, true, "")
std::map< joint, Vec3f > joint_input
std::string getNodeType() override
Vec3f getmeshPointDeformByJoint(joint jointId, Coord worldPosition, std::map< joint, Mat4f > jMatrix)
std::map< joint, Quat< float > > joint_rotation
DEF_ARRAY_STATE(Mat4f, JointInverseBindMatrix, DeviceType::GPU, "JointInverseBindMatrix")
DEF_VAR(Real, AnimationSpeed, 1,"AnimationSpeed")
void InitializationData()
TopologyModule::Triangle Triangle
DEF_ARRAY_STATE(Vec2f, TexCoord_1, DeviceType::GPU, "UVSet 1")
std::map< joint, Mat4f > joint_inverseBindMatrix
DEF_INSTANCE_STATE(SkinInfo, Skin, "SkinInfo")
DEF_INSTANCE_STATE(EdgeSet< TDataType >, JointSet, "")
DArray< Coord > unCenterPosition
std::map< joint, Mat4f > joint_matrix
std::vector< std::string > Scene_Name
std::shared_ptr< GLWireframeVisualModule > jointLineRender
std::map< int, std::vector< int > > meshId_Dir
DEF_VAR_STATE(Mat4f, Transform, Mat4f::identityMatrix(), "Transform")
DArray< Coord > initialPosition
std::shared_ptr< GLPointVisualModule > jointPointRender
void resetStates() override
std::map< joint, Mat4f > joint_AnimaMatrix
std::vector< joint > all_Joints
void updateStates() override
void updateTransformState()
DEF_INSTANCE_STATE(JointInfo, JointsData,"JointsInfo")
DEF_VAR(Real, JointRadius, 0.01, "")
void buildInverseBindMatrices(const std::vector< joint > &all_Joints)
DArray< int > d_shape_meshId
std::map< int, std::string > node_Name
A PointSet stores the coordinates for a set of independent points.
Vector< PointType, 3 > Triangle
This is an implementation of AdditiveCCD based on peridyno.
Array< T, DeviceType::GPU > DArray
SquareMatrix< float, 4 > Mat4f