btSolverConstraint.h
Go to the documentation of this file.
00001 /*
00002 Bullet Continuous Collision Detection and Physics Library
00003 Copyright (c) 2003-2006 Erwin Coumans  http://continuousphysics.com/Bullet/
00004 
00005 This software is provided 'as-is', without any express or implied warranty.
00006 In no event will the authors be held liable for any damages arising from the use of this software.
00007 Permission is granted to anyone to use this software for any purpose, 
00008 including commercial applications, and to alter it and redistribute it freely, 
00009 subject to the following restrictions:
00010 
00011 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required.
00012 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
00013 3. This notice may not be removed or altered from any source distribution.
00014 */
00015 
00016 #ifndef BT_SOLVER_CONSTRAINT_H
00017 #define BT_SOLVER_CONSTRAINT_H
00018 
00019 class   btRigidBody;
00020 #include "LinearMath/btVector3.h"
00021 #include "LinearMath/btMatrix3x3.h"
00022 #include "btJacobianEntry.h"
00023 
00024 //#define NO_FRICTION_TANGENTIALS 1
00025 #include "btSolverBody.h"
00026 
00027 
00029 ATTRIBUTE_ALIGNED64 (struct)    btSolverConstraint
00030 {
00031         BT_DECLARE_ALIGNED_ALLOCATOR();
00032 
00033         btVector3               m_relpos1CrossNormal;
00034         btVector3               m_contactNormal;
00035 
00036         btVector3               m_relpos2CrossNormal;
00037         //btVector3             m_contactNormal2;//usually m_contactNormal2 == -m_contactNormal
00038 
00039         btVector3               m_angularComponentA;
00040         btVector3               m_angularComponentB;
00041         
00042         mutable btSimdScalar    m_appliedPushImpulse;
00043         mutable btSimdScalar    m_appliedImpulse;
00044         
00045         
00046         btScalar        m_friction;
00047         btScalar        m_jacDiagABInv;
00048         union
00049         {
00050                 int     m_numConsecutiveRowsPerKernel;
00051                 btScalar        m_unusedPadding0;
00052         };
00053 
00054         union
00055         {
00056                 int                     m_frictionIndex;
00057                 btScalar        m_unusedPadding1;
00058         };
00059         union
00060         {
00061                 btRigidBody*    m_solverBodyA;
00062                 int                             m_companionIdA;
00063         };
00064         union
00065         {
00066                 btRigidBody*    m_solverBodyB;
00067                 int                             m_companionIdB;
00068         };
00069         
00070         union
00071         {
00072                 void*           m_originalContactPoint;
00073                 btScalar        m_unusedPadding4;
00074         };
00075 
00076         btScalar                m_rhs;
00077         btScalar                m_cfm;
00078         btScalar                m_lowerLimit;
00079         btScalar                m_upperLimit;
00080 
00081         btScalar                m_rhsPenetration;
00082 
00083         enum            btSolverConstraintType
00084         {
00085                 BT_SOLVER_CONTACT_1D = 0,
00086                 BT_SOLVER_FRICTION_1D
00087         };
00088 };
00089 
00090 typedef btAlignedObjectArray<btSolverConstraint>        btConstraintArray;
00091 
00092 
00093 #endif //BT_SOLVER_CONSTRAINT_H
00094 
00095 
00096 
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


bullet
Author(s): Erwin Coumans, ROS package maintained by Tully Foote
autogenerated on Wed Oct 31 2012 07:54:31