BGE patch: Optimization of bullet adaptation layer - part 1.
First batch of optimizaton of the bullet adaptation layer in the BGE. - remove circular motion state update. - optimization of physic adaptation layer for bullet: bypass unecessary conversion of rotation matrix to quaternion and back. - remove double updates during object replication.
This commit is contained in:
@@ -133,9 +133,10 @@ void KX_BulletPhysicsController::getOrientation(MT_Quaternion& orn)
|
||||
CcdPhysicsController::getOrientation(myorn[0],myorn[1],myorn[2],myorn[3]);
|
||||
orn = MT_Quaternion(myorn[0],myorn[1],myorn[2],myorn[3]);
|
||||
}
|
||||
void KX_BulletPhysicsController::setOrientation(const MT_Quaternion& orn)
|
||||
void KX_BulletPhysicsController::setOrientation(const MT_Matrix3x3& orn)
|
||||
{
|
||||
CcdPhysicsController::setOrientation(orn.x(),orn.y(),orn.z(),orn.w());
|
||||
btMatrix3x3 btmat(orn[0][0], orn[0][1], orn[1][2], orn[1][0], orn[1][1], orn[1][2], orn[2][0], orn[2][1], orn[2][2]);
|
||||
CcdPhysicsController::setWorldOrientation(btmat);
|
||||
}
|
||||
void KX_BulletPhysicsController::setPosition(const MT_Point3& pos)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user