PeriDyno 1.2.1
Loading...
Searching...
No Matches
VehicleInfo.cpp
Go to the documentation of this file.
1#include "VehicleInfo.h"
2
3
4namespace dyno
5{
6
8 {
9 shapeName = name;
10 meshShapeId = shapeId;
11 shapeType = type;
12 mDensity = density;
13 };
14
16 {
17 shapeName = name;
18 meshShapeId = shapeId;
19 shapeType = type;
20 transform = trans;
21 mDensity = density;
22 };
23
25 Name_Shape Name1,
26 Name_Shape Name2,
27 ConfigJointType typeIn,
28 Vector<Real, 3> Axi ,
30 bool Moter ,
31 Real moter ,
32 bool Range ,
33 Real min ,
34 Real max
35 )
36 {
37 mRigidBodyName_1 = Name1;
38 mRigidBodyName_2 = Name2;
39 mUseMoter = Moter;
40 mUseRange = Range;
42 mMin = min;
43 mMax = max;
44 mMoter = moter;
45 mAxis = Axi;
46 mJointType = typeIn;
47 }
48
50 {
51 mVehicleRigidBodyInfo.resize(size);
52 for (int i = 0; i < mVehicleRigidBodyInfo.size(); i++)
53 {
54 mVehicleRigidBodyInfo[i].shapeName = Name_Shape(std::string("Rigid") + std::to_string(i), i);
55 mVehicleRigidBodyInfo[i].meshShapeId = i;
56 }
57 mVehicleJointInfo.resize(size);
58 }
59
65
66}
67
double Real
Definition Typedef.inl:23
std::vector< VehicleRigidBodyInfo > mVehicleRigidBodyInfo
std::vector< VehicleJointInfo > mVehicleJointInfo
This is an implementation of AdditiveCCD based on peridyno.
Definition Array.h:25
ConfigJointType
Definition VehicleInfo.h:32
@ Point
Definition VehicleInfo.h:37
ConfigShapeType
Definition VehicleInfo.h:22
Transform< float, 3 > Transform3f
Vector< Real, 3 > mAnchorPoint
ConfigJointType mJointType
Definition VehicleInfo.h:95
Name_Shape mRigidBodyName_2
Definition VehicleInfo.h:97
Name_Shape mRigidBodyName_1
Definition VehicleInfo.h:96
Vector< Real, 3 > mAxis
ConfigShapeType shapeType
Definition VehicleInfo.h:72
#define max(x, y)
Definition svd3_cuda.h:41