Added many Joints. Parse asmt file.
This commit is contained in:
26
MbDCode/UniversalJoint.cpp
Normal file
26
MbDCode/UniversalJoint.cpp
Normal file
@@ -0,0 +1,26 @@
|
||||
#include "UniversalJoint.h"
|
||||
#include "System.h"
|
||||
#include "CREATE.h"
|
||||
|
||||
using namespace MbD;
|
||||
|
||||
MbD::UniversalJoint::UniversalJoint()
|
||||
{
|
||||
}
|
||||
|
||||
MbD::UniversalJoint::UniversalJoint(const char* str) : AtPointJoint(str)
|
||||
{
|
||||
}
|
||||
|
||||
void MbD::UniversalJoint::initializeGlobally()
|
||||
{
|
||||
if (constraints->empty())
|
||||
{
|
||||
createAtPointConstraints();
|
||||
addConstraint(CREATE<DirectionCosineConstraintIJ>::ConstraintWith(frmI, frmJ, 2, 2));
|
||||
this->root()->hasChanged = true;
|
||||
}
|
||||
else {
|
||||
Joint::initializeGlobally();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user