Newton Dynamics  4.00
ndJointFollowPath.h
1 /* Copyright (c) <2003-2022> <Newton Game Dynamics>
2 *
3 * This software is provided 'as-is', without any express or implied
4 * warranty. In no event will the authors be held liable for any damages
5 * arising from the use of this software.
6 *
7 * Permission is granted to anyone to use this software for any purpose,
8 * including commercial applications, and to alter it and redistribute it
9 * freely
10 */
11 
12 
13 #ifndef __ND_JOINT_FOLLOW_PATH_H__
14 #define __ND_JOINT_FOLLOW_PATH_H__
15 
16 #include "ndNewtonStdafx.h"
17 #include "ndJointBilateralConstraint.h"
18 
20 {
21  public:
22  D_CLASS_REFLECTION(ndJointFollowPath);
23  D_NEWTON_API ndJointFollowPath(const ndLoadSaveBase::ndLoadDescriptor& desc);
24  D_NEWTON_API ndJointFollowPath (const ndMatrix& pinAndPivotFrame, ndBodyKinematic* const child, ndBodyKinematic* const parent);
25  D_NEWTON_API virtual ~ndJointFollowPath();
26 
27  virtual void GetPointAndTangentAtLocation(const ndVector& location, ndVector& positOut, ndVector& tangentOut) const
28  {
29  positOut = location;
30  tangentOut = ndVector(1.0f, 0.0f, 0.0f, 0.0f);
31  }
32 
33  protected:
34  D_NEWTON_API void JacobianDerivative(ndConstraintDescritor& desc);
35  D_NEWTON_API void Save(const ndLoadSaveBase::ndSaveDescriptor& desc) const;
36 };
37 
38 #endif
39 
ndJointFollowPath
Definition: ndJointFollowPath.h:20
ndConstraintDescritor
Definition: ndConstraint.h:179
ndJointBilateralConstraint
Definition: ndJointBilateralConstraint.h:53
ndBodyKinematic
Definition: ndBodyKinematic.h:40
ndMatrix
Definition: ndMatrix.h:42
ndLoadSaveBase::ndLoadDescriptor
Definition: ndSaveLoadSytem.h:59
ndLoadSaveBase::ndSaveDescriptor
Definition: ndSaveLoadSytem.h:93
ndVector
Definition: ndVectorArmNeon.h:41