Back to index

supertuxkart  0.5+dfsg1
btSolverConstraint.h
Go to the documentation of this file.
00001 
00002 
00003 /*
00004 Bullet Continuous Collision Detection and Physics Library
00005 Copyright (c) 2003-2006 Erwin Coumans  http://continuousphysics.com/Bullet/
00006 
00007 This software is provided 'as-is', without any express or implied warranty.
00008 In no event will the authors be held liable for any damages arising from the use of this software.
00009 Permission is granted to anyone to use this software for any purpose, 
00010 including commercial applications, and to alter it and redistribute it freely, 
00011 subject to the following restrictions:
00012 
00013 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.
00014 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
00015 3. This notice may not be removed or altered from any source distribution.
00016 */
00017 
00018 #ifndef BT_SOLVER_CONSTRAINT_H
00019 #define BT_SOLVER_CONSTRAINT_H
00020 
00021 class  btRigidBody;
00022 #include "LinearMath/btVector3.h"
00023 #include "LinearMath/btMatrix3x3.h"
00024 
00025 //#define NO_FRICTION_TANGENTIALS 1
00026 
00028 ATTRIBUTE_ALIGNED16 (struct)       btSolverConstraint
00029 {
00030        BT_DECLARE_ALIGNED_ALLOCATOR();
00031 
00032        btVector3     m_relpos1CrossNormal;
00033        btVector3     m_contactNormal;
00034 
00035        btVector3     m_relpos2CrossNormal;
00036        btVector3     m_angularComponentA;
00037 
00038        btVector3     m_angularComponentB;
00039        mutable btScalar     m_appliedVelocityImpulse;
00040        mutable btScalar     m_appliedImpulse;
00041        int                  m_solverBodyIdA;
00042        int                  m_solverBodyIdB;
00043        
00044        btScalar      m_friction;
00045        btScalar      m_restitution;
00046        btScalar      m_jacDiagABInv;
00047        btScalar      m_penetration;
00048        
00049 
00050        
00051        int                  m_constraintType;
00052        int                  m_frictionIndex;
00053        void*         m_originalContactPoint;
00054        int                  m_unusedPadding[1];
00055 
00056 
00057        enum          btSolverConstraintType
00058        {
00059               BT_SOLVER_CONTACT_1D = 0,
00060               BT_SOLVER_FRICTION_1D
00061        };
00062 };
00063 
00064 
00065 
00066 
00067 
00068 
00069 #endif //BT_SOLVER_CONSTRAINT_H
00070 
00071