ruby-bullet 0.1.0-x86-linux → 0.1.1-x86-linux
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/README.md +3 -0
- data/Rakefile +14 -2
- data/bindings/bullet/interface/BulletCollision/CollisionDispatch/btCollisionWorld.i +2 -2
- data/bindings/bullet/interface/bullet_wrap.cpp +17548 -6035
- data/bindings/bullet/interface/bullet_wrap.h +7 -7
- data/bindings/bullet/interface/bullet_wrap.o +0 -0
- data/lib/bullet.so +0 -0
- data/lib/ruby-bullet/version.rb +1 -1
- data/ruby-bullet.gemspec +0 -3
- metadata +169 -444
- data/deps/include/bullet/Bullet-C-Api.h +0 -176
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btAxisSweep3.h +0 -1051
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btBroadphaseInterface.h +0 -82
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btBroadphaseProxy.h +0 -270
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btCollisionAlgorithm.h +0 -80
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btDbvt.h +0 -1257
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btDbvtBroadphase.h +0 -146
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btDispatcher.h +0 -110
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btMultiSapBroadphase.h +0 -151
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btOverlappingPairCache.h +0 -469
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btOverlappingPairCallback.h +0 -40
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btQuantizedBvh.h +0 -579
- data/deps/include/bullet/BulletCollision/BroadphaseCollision/btSimpleBroadphase.h +0 -171
- data/deps/include/bullet/BulletCollision/CollisionDispatch/SphereTriangleDetector.h +0 -51
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btActivatingCollisionAlgorithm.h +0 -36
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btBox2dBox2dCollisionAlgorithm.h +0 -66
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btBoxBoxCollisionAlgorithm.h +0 -66
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btBoxBoxDetector.h +0 -44
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btCollisionConfiguration.h +0 -48
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btCollisionCreateFunc.h +0 -45
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btCollisionDispatcher.h +0 -172
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btCollisionObject.h +0 -524
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btCollisionWorld.h +0 -509
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btCompoundCollisionAlgorithm.h +0 -86
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btConvex2dConvex2dAlgorithm.h +0 -95
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btConvexConcaveCollisionAlgorithm.h +0 -116
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btConvexConvexAlgorithm.h +0 -109
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btConvexPlaneCollisionAlgorithm.h +0 -84
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btDefaultCollisionConfiguration.h +0 -137
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btEmptyCollisionAlgorithm.h +0 -54
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btGhostObject.h +0 -175
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btInternalEdgeUtility.h +0 -46
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btManifoldResult.h +0 -128
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btSimulationIslandManager.h +0 -81
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btSphereBoxCollisionAlgorithm.h +0 -75
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btSphereSphereCollisionAlgorithm.h +0 -66
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btSphereTriangleCollisionAlgorithm.h +0 -69
- data/deps/include/bullet/BulletCollision/CollisionDispatch/btUnionFind.h +0 -129
- data/deps/include/bullet/BulletCollision/CollisionShapes/btBox2dShape.h +0 -369
- data/deps/include/bullet/BulletCollision/CollisionShapes/btBoxShape.h +0 -312
- data/deps/include/bullet/BulletCollision/CollisionShapes/btBvhTriangleMeshShape.h +0 -139
- data/deps/include/bullet/BulletCollision/CollisionShapes/btCapsuleShape.h +0 -173
- data/deps/include/bullet/BulletCollision/CollisionShapes/btCollisionMargin.h +0 -27
- data/deps/include/bullet/BulletCollision/CollisionShapes/btCollisionShape.h +0 -150
- data/deps/include/bullet/BulletCollision/CollisionShapes/btCompoundShape.h +0 -212
- data/deps/include/bullet/BulletCollision/CollisionShapes/btConcaveShape.h +0 -60
- data/deps/include/bullet/BulletCollision/CollisionShapes/btConeShape.h +0 -103
- data/deps/include/bullet/BulletCollision/CollisionShapes/btConvex2dShape.h +0 -80
- data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexHullShape.h +0 -122
- data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexInternalShape.h +0 -224
- data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexPointCloudShape.h +0 -105
- data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexPolyhedron.h +0 -62
- data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexShape.h +0 -84
- data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexTriangleMeshShape.h +0 -75
- data/deps/include/bullet/BulletCollision/CollisionShapes/btCylinderShape.h +0 -200
- data/deps/include/bullet/BulletCollision/CollisionShapes/btEmptyShape.h +0 -70
- data/deps/include/bullet/BulletCollision/CollisionShapes/btHeightfieldTerrainShape.h +0 -161
- data/deps/include/bullet/BulletCollision/CollisionShapes/btMaterial.h +0 -35
- data/deps/include/bullet/BulletCollision/CollisionShapes/btMinkowskiSumShape.h +0 -60
- data/deps/include/bullet/BulletCollision/CollisionShapes/btMultiSphereShape.h +0 -99
- data/deps/include/bullet/BulletCollision/CollisionShapes/btMultimaterialTriangleMeshShape.h +0 -120
- data/deps/include/bullet/BulletCollision/CollisionShapes/btOptimizedBvh.h +0 -65
- data/deps/include/bullet/BulletCollision/CollisionShapes/btPolyhedralConvexShape.h +0 -112
- data/deps/include/bullet/BulletCollision/CollisionShapes/btScaledBvhTriangleMeshShape.h +0 -93
- data/deps/include/bullet/BulletCollision/CollisionShapes/btShapeHull.h +0 -59
- data/deps/include/bullet/BulletCollision/CollisionShapes/btSphereShape.h +0 -73
- data/deps/include/bullet/BulletCollision/CollisionShapes/btStaticPlaneShape.h +0 -103
- data/deps/include/bullet/BulletCollision/CollisionShapes/btStridingMeshInterface.h +0 -162
- data/deps/include/bullet/BulletCollision/CollisionShapes/btTetrahedronShape.h +0 -74
- data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleBuffer.h +0 -69
- data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleCallback.h +0 -42
- data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleIndexVertexArray.h +0 -133
- data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleIndexVertexMaterialArray.h +0 -84
- data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleInfoMap.h +0 -241
- data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleMesh.h +0 -69
- data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleMeshShape.h +0 -89
- data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleShape.h +0 -182
- data/deps/include/bullet/BulletCollision/CollisionShapes/btUniformScalingShape.h +0 -87
- data/deps/include/bullet/BulletCollision/Gimpact/btBoxCollision.h +0 -647
- data/deps/include/bullet/BulletCollision/Gimpact/btClipPolygon.h +0 -182
- data/deps/include/bullet/BulletCollision/Gimpact/btContactProcessing.h +0 -145
- data/deps/include/bullet/BulletCollision/Gimpact/btGImpactBvh.h +0 -396
- data/deps/include/bullet/BulletCollision/Gimpact/btGImpactCollisionAlgorithm.h +0 -306
- data/deps/include/bullet/BulletCollision/Gimpact/btGImpactMassUtil.h +0 -60
- data/deps/include/bullet/BulletCollision/Gimpact/btGImpactQuantizedBvh.h +0 -372
- data/deps/include/bullet/BulletCollision/Gimpact/btGImpactShape.h +0 -1171
- data/deps/include/bullet/BulletCollision/Gimpact/btGenericPoolAllocator.h +0 -163
- data/deps/include/bullet/BulletCollision/Gimpact/btGeometryOperations.h +0 -212
- data/deps/include/bullet/BulletCollision/Gimpact/btQuantization.h +0 -88
- data/deps/include/bullet/BulletCollision/Gimpact/btTriangleShapeEx.h +0 -180
- data/deps/include/bullet/BulletCollision/Gimpact/gim_array.h +0 -326
- data/deps/include/bullet/BulletCollision/Gimpact/gim_basic_geometry_operations.h +0 -543
- data/deps/include/bullet/BulletCollision/Gimpact/gim_bitset.h +0 -123
- data/deps/include/bullet/BulletCollision/Gimpact/gim_box_collision.h +0 -590
- data/deps/include/bullet/BulletCollision/Gimpact/gim_box_set.h +0 -674
- data/deps/include/bullet/BulletCollision/Gimpact/gim_clip_polygon.h +0 -210
- data/deps/include/bullet/BulletCollision/Gimpact/gim_contact.h +0 -164
- data/deps/include/bullet/BulletCollision/Gimpact/gim_geom_types.h +0 -97
- data/deps/include/bullet/BulletCollision/Gimpact/gim_geometry.h +0 -42
- data/deps/include/bullet/BulletCollision/Gimpact/gim_hash_table.h +0 -902
- data/deps/include/bullet/BulletCollision/Gimpact/gim_linear_math.h +0 -1573
- data/deps/include/bullet/BulletCollision/Gimpact/gim_math.h +0 -157
- data/deps/include/bullet/BulletCollision/Gimpact/gim_memory.h +0 -190
- data/deps/include/bullet/BulletCollision/Gimpact/gim_radixsort.h +0 -406
- data/deps/include/bullet/BulletCollision/Gimpact/gim_tri_collision.h +0 -379
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btContinuousConvexCollision.h +0 -59
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btConvexCast.h +0 -73
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btConvexPenetrationDepthSolver.h +0 -42
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btDiscreteCollisionDetectorInterface.h +0 -91
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btGjkConvexCast.h +0 -50
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btGjkEpa2.h +0 -75
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btGjkEpaPenetrationDepthSolver.h +0 -43
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btGjkPairDetector.h +0 -103
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btManifoldPoint.h +0 -158
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btMinkowskiPenetrationDepthSolver.h +0 -40
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btPersistentManifold.h +0 -228
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btPointCollector.h +0 -64
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btPolyhedralContactClipping.h +0 -46
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btRaycastCallback.h +0 -72
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btSimplexSolverInterface.h +0 -63
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btSubSimplexConvexCast.h +0 -50
- data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btVoronoiSimplexSolver.h +0 -179
- data/deps/include/bullet/BulletCollision/btBulletCollisionCommon.h +0 -69
- data/deps/include/bullet/BulletDynamics/Character/btCharacterControllerInterface.h +0 -46
- data/deps/include/bullet/BulletDynamics/Character/btKinematicCharacterController.h +0 -163
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btConeTwistConstraint.h +0 -346
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btConstraintSolver.h +0 -52
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btContactConstraint.h +0 -71
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btContactSolverInfo.h +0 -87
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btGeneric6DofConstraint.h +0 -614
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btGeneric6DofSpringConstraint.h +0 -99
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btHinge2Constraint.h +0 -58
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btHingeConstraint.h +0 -381
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btJacobianEntry.h +0 -156
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btPoint2PointConstraint.h +0 -161
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btSequentialImpulseConstraintSolver.h +0 -130
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btSliderConstraint.h +0 -333
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btSolve2LinearConstraint.h +0 -107
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btSolverBody.h +0 -191
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btSolverConstraint.h +0 -98
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btTypedConstraint.h +0 -452
- data/deps/include/bullet/BulletDynamics/ConstraintSolver/btUniversalConstraint.h +0 -62
- data/deps/include/bullet/BulletDynamics/Dynamics/btActionInterface.h +0 -46
- data/deps/include/bullet/BulletDynamics/Dynamics/btDiscreteDynamicsWorld.h +0 -203
- data/deps/include/bullet/BulletDynamics/Dynamics/btDynamicsWorld.h +0 -151
- data/deps/include/bullet/BulletDynamics/Dynamics/btRigidBody.h +0 -691
- data/deps/include/bullet/BulletDynamics/Dynamics/btSimpleDynamicsWorld.h +0 -89
- data/deps/include/bullet/BulletDynamics/Vehicle/btRaycastVehicle.h +0 -236
- data/deps/include/bullet/BulletDynamics/Vehicle/btVehicleRaycaster.h +0 -35
- data/deps/include/bullet/BulletDynamics/Vehicle/btWheelInfo.h +0 -119
- data/deps/include/bullet/BulletDynamics/btBulletDynamicsCommon.h +0 -48
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverBuffer_DX11.h +0 -323
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverLinkData_DX11.h +0 -103
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverLinkData_DX11SIMDAware.h +0 -173
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverTriangleData_DX11.h +0 -96
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverVertexBuffer_DX11.h +0 -107
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverVertexData_DX11.h +0 -63
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolver_DX11.h +0 -691
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolver_DX11SIMDAware.h +0 -81
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverBuffer_OpenCL.h +0 -209
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverLinkData_OpenCL.h +0 -99
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverLinkData_OpenCLSIMDAware.h +0 -169
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverOutputCLtoGL.h +0 -62
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverTriangleData_OpenCL.h +0 -84
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverVertexBuffer_OpenGL.h +0 -166
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverVertexData_OpenCL.h +0 -52
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolver_OpenCL.h +0 -527
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolver_OpenCLSIMDAware.h +0 -81
- data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/Shared/btSoftBodySolverData.h +0 -748
- data/deps/include/bullet/BulletMultiThreaded/HeapManager.h +0 -117
- data/deps/include/bullet/BulletMultiThreaded/PlatformDefinitions.h +0 -99
- data/deps/include/bullet/BulletMultiThreaded/PosixThreadSupport.h +0 -142
- data/deps/include/bullet/BulletMultiThreaded/PpuAddressSpace.h +0 -37
- data/deps/include/bullet/BulletMultiThreaded/SequentialThreadSupport.h +0 -96
- data/deps/include/bullet/BulletMultiThreaded/SpuCollisionObjectWrapper.h +0 -40
- data/deps/include/bullet/BulletMultiThreaded/SpuCollisionTaskProcess.h +0 -163
- data/deps/include/bullet/BulletMultiThreaded/SpuContactManifoldCollisionAlgorithm.h +0 -120
- data/deps/include/bullet/BulletMultiThreaded/SpuDoubleBuffer.h +0 -126
- data/deps/include/bullet/BulletMultiThreaded/SpuFakeDma.h +0 -135
- data/deps/include/bullet/BulletMultiThreaded/SpuGatheringCollisionDispatcher.h +0 -72
- data/deps/include/bullet/BulletMultiThreaded/SpuLibspe2Support.h +0 -180
- data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/Box.h +0 -167
- data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuCollisionShapes.h +0 -128
- data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuContactResult.h +0 -106
- data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuConvexPenetrationDepthSolver.h +0 -51
- data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuGatheringCollisionTask.h +0 -140
- data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuLocalSupport.h +0 -19
- data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuMinkowskiPenetrationDepthSolver.h +0 -48
- data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuPreferredPenetrationDirections.h +0 -70
- data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/boxBoxDistance.h +0 -65
- data/deps/include/bullet/BulletMultiThreaded/SpuSampleTask/SpuSampleTask.h +0 -54
- data/deps/include/bullet/BulletMultiThreaded/SpuSampleTaskProcess.h +0 -153
- data/deps/include/bullet/BulletMultiThreaded/SpuSync.h +0 -149
- data/deps/include/bullet/BulletMultiThreaded/TrbDynBody.h +0 -79
- data/deps/include/bullet/BulletMultiThreaded/TrbStateVec.h +0 -339
- data/deps/include/bullet/BulletMultiThreaded/Win32ThreadSupport.h +0 -138
- data/deps/include/bullet/BulletMultiThreaded/btGpu3DGridBroadphase.h +0 -138
- data/deps/include/bullet/BulletMultiThreaded/btGpu3DGridBroadphaseSharedCode.h +0 -430
- data/deps/include/bullet/BulletMultiThreaded/btGpu3DGridBroadphaseSharedDefs.h +0 -61
- data/deps/include/bullet/BulletMultiThreaded/btGpu3DGridBroadphaseSharedTypes.h +0 -67
- data/deps/include/bullet/BulletMultiThreaded/btGpuDefines.h +0 -211
- data/deps/include/bullet/BulletMultiThreaded/btGpuUtilsSharedCode.h +0 -55
- data/deps/include/bullet/BulletMultiThreaded/btGpuUtilsSharedDefs.h +0 -52
- data/deps/include/bullet/BulletMultiThreaded/btParallelConstraintSolver.h +0 -285
- data/deps/include/bullet/BulletMultiThreaded/btThreadSupportInterface.h +0 -85
- data/deps/include/bullet/BulletMultiThreaded/vectormath2bullet.h +0 -73
- data/deps/include/bullet/BulletSoftBody/btDefaultSoftBodySolver.h +0 -63
- data/deps/include/bullet/BulletSoftBody/btSoftBody.h +0 -987
- data/deps/include/bullet/BulletSoftBody/btSoftBodyConcaveCollisionAlgorithm.h +0 -153
- data/deps/include/bullet/BulletSoftBody/btSoftBodyData.h +0 -217
- data/deps/include/bullet/BulletSoftBody/btSoftBodyHelpers.h +0 -143
- data/deps/include/bullet/BulletSoftBody/btSoftBodyInternals.h +0 -930
- data/deps/include/bullet/BulletSoftBody/btSoftBodyRigidBodyCollisionConfiguration.h +0 -48
- data/deps/include/bullet/BulletSoftBody/btSoftBodySolverVertexBuffer.h +0 -165
- data/deps/include/bullet/BulletSoftBody/btSoftBodySolvers.h +0 -154
- data/deps/include/bullet/BulletSoftBody/btSoftRigidCollisionAlgorithm.h +0 -75
- data/deps/include/bullet/BulletSoftBody/btSoftRigidDynamicsWorld.h +0 -107
- data/deps/include/bullet/BulletSoftBody/btSoftSoftCollisionAlgorithm.h +0 -69
- data/deps/include/bullet/BulletSoftBody/btSparseSDF.h +0 -306
- data/deps/include/bullet/LinearMath/btAabbUtil2.h +0 -236
- data/deps/include/bullet/LinearMath/btAlignedAllocator.h +0 -107
- data/deps/include/bullet/LinearMath/btAlignedObjectArray.h +0 -494
- data/deps/include/bullet/LinearMath/btConvexHull.h +0 -241
- data/deps/include/bullet/LinearMath/btConvexHullComputer.h +0 -103
- data/deps/include/bullet/LinearMath/btDefaultMotionState.h +0 -40
- data/deps/include/bullet/LinearMath/btGeometryUtil.h +0 -42
- data/deps/include/bullet/LinearMath/btGrahamScan2dConvexHull.h +0 -110
- data/deps/include/bullet/LinearMath/btHashMap.h +0 -450
- data/deps/include/bullet/LinearMath/btIDebugDraw.h +0 -418
- data/deps/include/bullet/LinearMath/btList.h +0 -73
- data/deps/include/bullet/LinearMath/btMatrix3x3.h +0 -771
- data/deps/include/bullet/LinearMath/btMinMax.h +0 -71
- data/deps/include/bullet/LinearMath/btMotionState.h +0 -40
- data/deps/include/bullet/LinearMath/btPoolAllocator.h +0 -121
- data/deps/include/bullet/LinearMath/btQuadWord.h +0 -180
- data/deps/include/bullet/LinearMath/btQuaternion.h +0 -430
- data/deps/include/bullet/LinearMath/btQuickprof.h +0 -203
- data/deps/include/bullet/LinearMath/btRandom.h +0 -42
- data/deps/include/bullet/LinearMath/btScalar.h +0 -539
- data/deps/include/bullet/LinearMath/btSerializer.h +0 -639
- data/deps/include/bullet/LinearMath/btStackAlloc.h +0 -116
- data/deps/include/bullet/LinearMath/btTransform.h +0 -307
- data/deps/include/bullet/LinearMath/btTransformUtil.h +0 -228
- data/deps/include/bullet/LinearMath/btVector3.h +0 -766
- data/deps/include/bullet/MiniCL/MiniCLTask/MiniCLTask.h +0 -62
- data/deps/include/bullet/MiniCL/MiniCLTaskScheduler.h +0 -194
- data/deps/include/bullet/MiniCL/cl.h +0 -867
- data/deps/include/bullet/MiniCL/cl_MiniCL_Defs.h +0 -439
- data/deps/include/bullet/MiniCL/cl_gl.h +0 -113
- data/deps/include/bullet/MiniCL/cl_platform.h +0 -254
- data/deps/include/bullet/btBulletCollisionCommon.h +0 -69
- data/deps/include/bullet/btBulletDynamicsCommon.h +0 -48
- data/deps/include/bullet/vectormath/scalar/boolInVec.h +0 -225
- data/deps/include/bullet/vectormath/scalar/floatInVec.h +0 -343
- data/deps/include/bullet/vectormath/scalar/mat_aos.h +0 -1630
- data/deps/include/bullet/vectormath/scalar/quat_aos.h +0 -433
- data/deps/include/bullet/vectormath/scalar/vec_aos.h +0 -1426
- data/deps/include/bullet/vectormath/scalar/vectormath_aos.h +0 -1872
- data/deps/include/bullet/vectormath/sse/boolInVec.h +0 -247
- data/deps/include/bullet/vectormath/sse/floatInVec.h +0 -340
- data/deps/include/bullet/vectormath/sse/mat_aos.h +0 -2190
- data/deps/include/bullet/vectormath/sse/quat_aos.h +0 -579
- data/deps/include/bullet/vectormath/sse/vec_aos.h +0 -1455
- data/deps/include/bullet/vectormath/sse/vecidx_aos.h +0 -80
- data/deps/include/bullet/vectormath/sse/vectormath_aos.h +0 -2547
- data/deps/include/bullet/vectormath/vmInclude.h +0 -27
- data/deps/lib/libBulletCollision.a +0 -0
- data/deps/lib/libBulletDynamics.a +0 -0
- data/deps/lib/libBulletMultiThreaded.a +0 -0
- data/deps/lib/libBulletSoftBody.a +0 -0
- data/deps/lib/libBulletSoftBodySolvers_OpenCL_Mini.a +0 -0
- data/deps/lib/libLinearMath.a +0 -0
- data/deps/lib/libMiniCL.a +0 -0
@@ -1,116 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
Copyright (c) 2003-2006 Gino van den Bergen / Erwin Coumans http://continuousphysics.com/Bullet/
|
3
|
-
|
4
|
-
This software is provided 'as-is', without any express or implied warranty.
|
5
|
-
In no event will the authors be held liable for any damages arising from the use of this software.
|
6
|
-
Permission is granted to anyone to use this software for any purpose,
|
7
|
-
including commercial applications, and to alter it and redistribute it freely,
|
8
|
-
subject to the following restrictions:
|
9
|
-
|
10
|
-
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.
|
11
|
-
2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
|
12
|
-
3. This notice may not be removed or altered from any source distribution.
|
13
|
-
*/
|
14
|
-
|
15
|
-
/*
|
16
|
-
StackAlloc extracted from GJK-EPA collision solver by Nathanael Presson
|
17
|
-
Nov.2006
|
18
|
-
*/
|
19
|
-
|
20
|
-
#ifndef BT_STACK_ALLOC
|
21
|
-
#define BT_STACK_ALLOC
|
22
|
-
|
23
|
-
#include "btScalar.h" //for btAssert
|
24
|
-
#include "btAlignedAllocator.h"
|
25
|
-
|
26
|
-
///The btBlock class is an internal structure for the btStackAlloc memory allocator.
|
27
|
-
struct btBlock
|
28
|
-
{
|
29
|
-
btBlock* previous;
|
30
|
-
unsigned char* address;
|
31
|
-
};
|
32
|
-
|
33
|
-
///The StackAlloc class provides some fast stack-based memory allocator (LIFO last-in first-out)
|
34
|
-
class btStackAlloc
|
35
|
-
{
|
36
|
-
public:
|
37
|
-
|
38
|
-
btStackAlloc(unsigned int size) { ctor();create(size); }
|
39
|
-
~btStackAlloc() { destroy(); }
|
40
|
-
|
41
|
-
inline void create(unsigned int size)
|
42
|
-
{
|
43
|
-
destroy();
|
44
|
-
data = (unsigned char*) btAlignedAlloc(size,16);
|
45
|
-
totalsize = size;
|
46
|
-
}
|
47
|
-
inline void destroy()
|
48
|
-
{
|
49
|
-
btAssert(usedsize==0);
|
50
|
-
//Raise(L"StackAlloc is still in use");
|
51
|
-
|
52
|
-
if(usedsize==0)
|
53
|
-
{
|
54
|
-
if(!ischild && data)
|
55
|
-
btAlignedFree(data);
|
56
|
-
|
57
|
-
data = 0;
|
58
|
-
usedsize = 0;
|
59
|
-
}
|
60
|
-
|
61
|
-
}
|
62
|
-
|
63
|
-
int getAvailableMemory() const
|
64
|
-
{
|
65
|
-
return static_cast<int>(totalsize - usedsize);
|
66
|
-
}
|
67
|
-
|
68
|
-
unsigned char* allocate(unsigned int size)
|
69
|
-
{
|
70
|
-
const unsigned int nus(usedsize+size);
|
71
|
-
if(nus<totalsize)
|
72
|
-
{
|
73
|
-
usedsize=nus;
|
74
|
-
return(data+(usedsize-size));
|
75
|
-
}
|
76
|
-
btAssert(0);
|
77
|
-
//&& (L"Not enough memory"));
|
78
|
-
|
79
|
-
return(0);
|
80
|
-
}
|
81
|
-
SIMD_FORCE_INLINE btBlock* beginBlock()
|
82
|
-
{
|
83
|
-
btBlock* pb = (btBlock*)allocate(sizeof(btBlock));
|
84
|
-
pb->previous = current;
|
85
|
-
pb->address = data+usedsize;
|
86
|
-
current = pb;
|
87
|
-
return(pb);
|
88
|
-
}
|
89
|
-
SIMD_FORCE_INLINE void endBlock(btBlock* block)
|
90
|
-
{
|
91
|
-
btAssert(block==current);
|
92
|
-
//Raise(L"Unmatched blocks");
|
93
|
-
if(block==current)
|
94
|
-
{
|
95
|
-
current = block->previous;
|
96
|
-
usedsize = (unsigned int)((block->address-data)-sizeof(btBlock));
|
97
|
-
}
|
98
|
-
}
|
99
|
-
|
100
|
-
private:
|
101
|
-
void ctor()
|
102
|
-
{
|
103
|
-
data = 0;
|
104
|
-
totalsize = 0;
|
105
|
-
usedsize = 0;
|
106
|
-
current = 0;
|
107
|
-
ischild = false;
|
108
|
-
}
|
109
|
-
unsigned char* data;
|
110
|
-
unsigned int totalsize;
|
111
|
-
unsigned int usedsize;
|
112
|
-
btBlock* current;
|
113
|
-
bool ischild;
|
114
|
-
};
|
115
|
-
|
116
|
-
#endif //BT_STACK_ALLOC
|
@@ -1,307 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
Copyright (c) 2003-2006 Gino van den Bergen / Erwin Coumans http://continuousphysics.com/Bullet/
|
3
|
-
|
4
|
-
This software is provided 'as-is', without any express or implied warranty.
|
5
|
-
In no event will the authors be held liable for any damages arising from the use of this software.
|
6
|
-
Permission is granted to anyone to use this software for any purpose,
|
7
|
-
including commercial applications, and to alter it and redistribute it freely,
|
8
|
-
subject to the following restrictions:
|
9
|
-
|
10
|
-
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.
|
11
|
-
2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
|
12
|
-
3. This notice may not be removed or altered from any source distribution.
|
13
|
-
*/
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
#ifndef BT_TRANSFORM_H
|
18
|
-
#define BT_TRANSFORM_H
|
19
|
-
|
20
|
-
|
21
|
-
#include "btMatrix3x3.h"
|
22
|
-
|
23
|
-
#ifdef BT_USE_DOUBLE_PRECISION
|
24
|
-
#define btTransformData btTransformDoubleData
|
25
|
-
#else
|
26
|
-
#define btTransformData btTransformFloatData
|
27
|
-
#endif
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
/**@brief The btTransform class supports rigid transforms with only translation and rotation and no scaling/shear.
|
33
|
-
*It can be used in combination with btVector3, btQuaternion and btMatrix3x3 linear algebra classes. */
|
34
|
-
class btTransform {
|
35
|
-
|
36
|
-
///Storage for the rotation
|
37
|
-
btMatrix3x3 m_basis;
|
38
|
-
///Storage for the translation
|
39
|
-
btVector3 m_origin;
|
40
|
-
|
41
|
-
public:
|
42
|
-
|
43
|
-
/**@brief No initialization constructor */
|
44
|
-
btTransform() {}
|
45
|
-
/**@brief Constructor from btQuaternion (optional btVector3 )
|
46
|
-
* @param q Rotation from quaternion
|
47
|
-
* @param c Translation from Vector (default 0,0,0) */
|
48
|
-
explicit SIMD_FORCE_INLINE btTransform(const btQuaternion& q,
|
49
|
-
const btVector3& c = btVector3(btScalar(0), btScalar(0), btScalar(0)))
|
50
|
-
: m_basis(q),
|
51
|
-
m_origin(c)
|
52
|
-
{}
|
53
|
-
|
54
|
-
/**@brief Constructor from btMatrix3x3 (optional btVector3)
|
55
|
-
* @param b Rotation from Matrix
|
56
|
-
* @param c Translation from Vector default (0,0,0)*/
|
57
|
-
explicit SIMD_FORCE_INLINE btTransform(const btMatrix3x3& b,
|
58
|
-
const btVector3& c = btVector3(btScalar(0), btScalar(0), btScalar(0)))
|
59
|
-
: m_basis(b),
|
60
|
-
m_origin(c)
|
61
|
-
{}
|
62
|
-
/**@brief Copy constructor */
|
63
|
-
SIMD_FORCE_INLINE btTransform (const btTransform& other)
|
64
|
-
: m_basis(other.m_basis),
|
65
|
-
m_origin(other.m_origin)
|
66
|
-
{
|
67
|
-
}
|
68
|
-
/**@brief Assignment Operator */
|
69
|
-
SIMD_FORCE_INLINE btTransform& operator=(const btTransform& other)
|
70
|
-
{
|
71
|
-
m_basis = other.m_basis;
|
72
|
-
m_origin = other.m_origin;
|
73
|
-
return *this;
|
74
|
-
}
|
75
|
-
|
76
|
-
|
77
|
-
/**@brief Set the current transform as the value of the product of two transforms
|
78
|
-
* @param t1 Transform 1
|
79
|
-
* @param t2 Transform 2
|
80
|
-
* This = Transform1 * Transform2 */
|
81
|
-
SIMD_FORCE_INLINE void mult(const btTransform& t1, const btTransform& t2) {
|
82
|
-
m_basis = t1.m_basis * t2.m_basis;
|
83
|
-
m_origin = t1(t2.m_origin);
|
84
|
-
}
|
85
|
-
|
86
|
-
/* void multInverseLeft(const btTransform& t1, const btTransform& t2) {
|
87
|
-
btVector3 v = t2.m_origin - t1.m_origin;
|
88
|
-
m_basis = btMultTransposeLeft(t1.m_basis, t2.m_basis);
|
89
|
-
m_origin = v * t1.m_basis;
|
90
|
-
}
|
91
|
-
*/
|
92
|
-
|
93
|
-
/**@brief Return the transform of the vector */
|
94
|
-
SIMD_FORCE_INLINE btVector3 operator()(const btVector3& x) const
|
95
|
-
{
|
96
|
-
return btVector3(m_basis[0].dot(x) + m_origin.x(),
|
97
|
-
m_basis[1].dot(x) + m_origin.y(),
|
98
|
-
m_basis[2].dot(x) + m_origin.z());
|
99
|
-
}
|
100
|
-
|
101
|
-
/**@brief Return the transform of the vector */
|
102
|
-
SIMD_FORCE_INLINE btVector3 operator*(const btVector3& x) const
|
103
|
-
{
|
104
|
-
return (*this)(x);
|
105
|
-
}
|
106
|
-
|
107
|
-
/**@brief Return the transform of the btQuaternion */
|
108
|
-
SIMD_FORCE_INLINE btQuaternion operator*(const btQuaternion& q) const
|
109
|
-
{
|
110
|
-
return getRotation() * q;
|
111
|
-
}
|
112
|
-
|
113
|
-
/**@brief Return the basis matrix for the rotation */
|
114
|
-
SIMD_FORCE_INLINE btMatrix3x3& getBasis() { return m_basis; }
|
115
|
-
/**@brief Return the basis matrix for the rotation */
|
116
|
-
SIMD_FORCE_INLINE const btMatrix3x3& getBasis() const { return m_basis; }
|
117
|
-
|
118
|
-
/**@brief Return the origin vector translation */
|
119
|
-
SIMD_FORCE_INLINE btVector3& getOrigin() { return m_origin; }
|
120
|
-
/**@brief Return the origin vector translation */
|
121
|
-
SIMD_FORCE_INLINE const btVector3& getOrigin() const { return m_origin; }
|
122
|
-
|
123
|
-
/**@brief Return a quaternion representing the rotation */
|
124
|
-
btQuaternion getRotation() const {
|
125
|
-
btQuaternion q;
|
126
|
-
m_basis.getRotation(q);
|
127
|
-
return q;
|
128
|
-
}
|
129
|
-
|
130
|
-
|
131
|
-
/**@brief Set from an array
|
132
|
-
* @param m A pointer to a 15 element array (12 rotation(row major padded on the right by 1), and 3 translation */
|
133
|
-
void setFromOpenGLMatrix(const btScalar *m)
|
134
|
-
{
|
135
|
-
m_basis.setFromOpenGLSubMatrix(m);
|
136
|
-
m_origin.setValue(m[12],m[13],m[14]);
|
137
|
-
}
|
138
|
-
|
139
|
-
/**@brief Fill an array representation
|
140
|
-
* @param m A pointer to a 15 element array (12 rotation(row major padded on the right by 1), and 3 translation */
|
141
|
-
void getOpenGLMatrix(btScalar *m) const
|
142
|
-
{
|
143
|
-
m_basis.getOpenGLSubMatrix(m);
|
144
|
-
m[12] = m_origin.x();
|
145
|
-
m[13] = m_origin.y();
|
146
|
-
m[14] = m_origin.z();
|
147
|
-
m[15] = btScalar(1.0);
|
148
|
-
}
|
149
|
-
|
150
|
-
/**@brief Set the translational element
|
151
|
-
* @param origin The vector to set the translation to */
|
152
|
-
SIMD_FORCE_INLINE void setOrigin(const btVector3& origin)
|
153
|
-
{
|
154
|
-
m_origin = origin;
|
155
|
-
}
|
156
|
-
|
157
|
-
SIMD_FORCE_INLINE btVector3 invXform(const btVector3& inVec) const;
|
158
|
-
|
159
|
-
|
160
|
-
/**@brief Set the rotational element by btMatrix3x3 */
|
161
|
-
SIMD_FORCE_INLINE void setBasis(const btMatrix3x3& basis)
|
162
|
-
{
|
163
|
-
m_basis = basis;
|
164
|
-
}
|
165
|
-
|
166
|
-
/**@brief Set the rotational element by btQuaternion */
|
167
|
-
SIMD_FORCE_INLINE void setRotation(const btQuaternion& q)
|
168
|
-
{
|
169
|
-
m_basis.setRotation(q);
|
170
|
-
}
|
171
|
-
|
172
|
-
|
173
|
-
/**@brief Set this transformation to the identity */
|
174
|
-
void setIdentity()
|
175
|
-
{
|
176
|
-
m_basis.setIdentity();
|
177
|
-
m_origin.setValue(btScalar(0.0), btScalar(0.0), btScalar(0.0));
|
178
|
-
}
|
179
|
-
|
180
|
-
/**@brief Multiply this Transform by another(this = this * another)
|
181
|
-
* @param t The other transform */
|
182
|
-
btTransform& operator*=(const btTransform& t)
|
183
|
-
{
|
184
|
-
m_origin += m_basis * t.m_origin;
|
185
|
-
m_basis *= t.m_basis;
|
186
|
-
return *this;
|
187
|
-
}
|
188
|
-
|
189
|
-
/**@brief Return the inverse of this transform */
|
190
|
-
btTransform inverse() const
|
191
|
-
{
|
192
|
-
btMatrix3x3 inv = m_basis.transpose();
|
193
|
-
return btTransform(inv, inv * -m_origin);
|
194
|
-
}
|
195
|
-
|
196
|
-
/**@brief Return the inverse of this transform times the other transform
|
197
|
-
* @param t The other transform
|
198
|
-
* return this.inverse() * the other */
|
199
|
-
btTransform inverseTimes(const btTransform& t) const;
|
200
|
-
|
201
|
-
/**@brief Return the product of this transform and the other */
|
202
|
-
btTransform operator*(const btTransform& t) const;
|
203
|
-
|
204
|
-
/**@brief Return an identity transform */
|
205
|
-
static const btTransform& getIdentity()
|
206
|
-
{
|
207
|
-
static const btTransform identityTransform(btMatrix3x3::getIdentity());
|
208
|
-
return identityTransform;
|
209
|
-
}
|
210
|
-
|
211
|
-
void serialize(struct btTransformData& dataOut) const;
|
212
|
-
|
213
|
-
void serializeFloat(struct btTransformFloatData& dataOut) const;
|
214
|
-
|
215
|
-
void deSerialize(const struct btTransformData& dataIn);
|
216
|
-
|
217
|
-
void deSerializeDouble(const struct btTransformDoubleData& dataIn);
|
218
|
-
|
219
|
-
void deSerializeFloat(const struct btTransformFloatData& dataIn);
|
220
|
-
|
221
|
-
};
|
222
|
-
|
223
|
-
|
224
|
-
SIMD_FORCE_INLINE btVector3
|
225
|
-
btTransform::invXform(const btVector3& inVec) const
|
226
|
-
{
|
227
|
-
btVector3 v = inVec - m_origin;
|
228
|
-
return (m_basis.transpose() * v);
|
229
|
-
}
|
230
|
-
|
231
|
-
SIMD_FORCE_INLINE btTransform
|
232
|
-
btTransform::inverseTimes(const btTransform& t) const
|
233
|
-
{
|
234
|
-
btVector3 v = t.getOrigin() - m_origin;
|
235
|
-
return btTransform(m_basis.transposeTimes(t.m_basis),
|
236
|
-
v * m_basis);
|
237
|
-
}
|
238
|
-
|
239
|
-
SIMD_FORCE_INLINE btTransform
|
240
|
-
btTransform::operator*(const btTransform& t) const
|
241
|
-
{
|
242
|
-
return btTransform(m_basis * t.m_basis,
|
243
|
-
(*this)(t.m_origin));
|
244
|
-
}
|
245
|
-
|
246
|
-
/**@brief Test if two transforms have all elements equal */
|
247
|
-
SIMD_FORCE_INLINE bool operator==(const btTransform& t1, const btTransform& t2)
|
248
|
-
{
|
249
|
-
return ( t1.getBasis() == t2.getBasis() &&
|
250
|
-
t1.getOrigin() == t2.getOrigin() );
|
251
|
-
}
|
252
|
-
|
253
|
-
|
254
|
-
///for serialization
|
255
|
-
struct btTransformFloatData
|
256
|
-
{
|
257
|
-
btMatrix3x3FloatData m_basis;
|
258
|
-
btVector3FloatData m_origin;
|
259
|
-
};
|
260
|
-
|
261
|
-
struct btTransformDoubleData
|
262
|
-
{
|
263
|
-
btMatrix3x3DoubleData m_basis;
|
264
|
-
btVector3DoubleData m_origin;
|
265
|
-
};
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
SIMD_FORCE_INLINE void btTransform::serialize(btTransformData& dataOut) const
|
270
|
-
{
|
271
|
-
m_basis.serialize(dataOut.m_basis);
|
272
|
-
m_origin.serialize(dataOut.m_origin);
|
273
|
-
}
|
274
|
-
|
275
|
-
SIMD_FORCE_INLINE void btTransform::serializeFloat(btTransformFloatData& dataOut) const
|
276
|
-
{
|
277
|
-
m_basis.serializeFloat(dataOut.m_basis);
|
278
|
-
m_origin.serializeFloat(dataOut.m_origin);
|
279
|
-
}
|
280
|
-
|
281
|
-
|
282
|
-
SIMD_FORCE_INLINE void btTransform::deSerialize(const btTransformData& dataIn)
|
283
|
-
{
|
284
|
-
m_basis.deSerialize(dataIn.m_basis);
|
285
|
-
m_origin.deSerialize(dataIn.m_origin);
|
286
|
-
}
|
287
|
-
|
288
|
-
SIMD_FORCE_INLINE void btTransform::deSerializeFloat(const btTransformFloatData& dataIn)
|
289
|
-
{
|
290
|
-
m_basis.deSerializeFloat(dataIn.m_basis);
|
291
|
-
m_origin.deSerializeFloat(dataIn.m_origin);
|
292
|
-
}
|
293
|
-
|
294
|
-
SIMD_FORCE_INLINE void btTransform::deSerializeDouble(const btTransformDoubleData& dataIn)
|
295
|
-
{
|
296
|
-
m_basis.deSerializeDouble(dataIn.m_basis);
|
297
|
-
m_origin.deSerializeDouble(dataIn.m_origin);
|
298
|
-
}
|
299
|
-
|
300
|
-
|
301
|
-
#endif //BT_TRANSFORM_H
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
306
|
-
|
307
|
-
|
@@ -1,228 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
Copyright (c) 2003-2006 Gino van den Bergen / Erwin Coumans http://continuousphysics.com/Bullet/
|
3
|
-
|
4
|
-
This software is provided 'as-is', without any express or implied warranty.
|
5
|
-
In no event will the authors be held liable for any damages arising from the use of this software.
|
6
|
-
Permission is granted to anyone to use this software for any purpose,
|
7
|
-
including commercial applications, and to alter it and redistribute it freely,
|
8
|
-
subject to the following restrictions:
|
9
|
-
|
10
|
-
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.
|
11
|
-
2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
|
12
|
-
3. This notice may not be removed or altered from any source distribution.
|
13
|
-
*/
|
14
|
-
|
15
|
-
|
16
|
-
#ifndef BT_TRANSFORM_UTIL_H
|
17
|
-
#define BT_TRANSFORM_UTIL_H
|
18
|
-
|
19
|
-
#include "btTransform.h"
|
20
|
-
#define ANGULAR_MOTION_THRESHOLD btScalar(0.5)*SIMD_HALF_PI
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
SIMD_FORCE_INLINE btVector3 btAabbSupport(const btVector3& halfExtents,const btVector3& supportDir)
|
26
|
-
{
|
27
|
-
return btVector3(supportDir.x() < btScalar(0.0) ? -halfExtents.x() : halfExtents.x(),
|
28
|
-
supportDir.y() < btScalar(0.0) ? -halfExtents.y() : halfExtents.y(),
|
29
|
-
supportDir.z() < btScalar(0.0) ? -halfExtents.z() : halfExtents.z());
|
30
|
-
}
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
/// Utils related to temporal transforms
|
38
|
-
class btTransformUtil
|
39
|
-
{
|
40
|
-
|
41
|
-
public:
|
42
|
-
|
43
|
-
static void integrateTransform(const btTransform& curTrans,const btVector3& linvel,const btVector3& angvel,btScalar timeStep,btTransform& predictedTransform)
|
44
|
-
{
|
45
|
-
predictedTransform.setOrigin(curTrans.getOrigin() + linvel * timeStep);
|
46
|
-
// #define QUATERNION_DERIVATIVE
|
47
|
-
#ifdef QUATERNION_DERIVATIVE
|
48
|
-
btQuaternion predictedOrn = curTrans.getRotation();
|
49
|
-
predictedOrn += (angvel * predictedOrn) * (timeStep * btScalar(0.5));
|
50
|
-
predictedOrn.normalize();
|
51
|
-
#else
|
52
|
-
//Exponential map
|
53
|
-
//google for "Practical Parameterization of Rotations Using the Exponential Map", F. Sebastian Grassia
|
54
|
-
|
55
|
-
btVector3 axis;
|
56
|
-
btScalar fAngle = angvel.length();
|
57
|
-
//limit the angular motion
|
58
|
-
if (fAngle*timeStep > ANGULAR_MOTION_THRESHOLD)
|
59
|
-
{
|
60
|
-
fAngle = ANGULAR_MOTION_THRESHOLD / timeStep;
|
61
|
-
}
|
62
|
-
|
63
|
-
if ( fAngle < btScalar(0.001) )
|
64
|
-
{
|
65
|
-
// use Taylor's expansions of sync function
|
66
|
-
axis = angvel*( btScalar(0.5)*timeStep-(timeStep*timeStep*timeStep)*(btScalar(0.020833333333))*fAngle*fAngle );
|
67
|
-
}
|
68
|
-
else
|
69
|
-
{
|
70
|
-
// sync(fAngle) = sin(c*fAngle)/t
|
71
|
-
axis = angvel*( btSin(btScalar(0.5)*fAngle*timeStep)/fAngle );
|
72
|
-
}
|
73
|
-
btQuaternion dorn (axis.x(),axis.y(),axis.z(),btCos( fAngle*timeStep*btScalar(0.5) ));
|
74
|
-
btQuaternion orn0 = curTrans.getRotation();
|
75
|
-
|
76
|
-
btQuaternion predictedOrn = dorn * orn0;
|
77
|
-
predictedOrn.normalize();
|
78
|
-
#endif
|
79
|
-
predictedTransform.setRotation(predictedOrn);
|
80
|
-
}
|
81
|
-
|
82
|
-
static void calculateVelocityQuaternion(const btVector3& pos0,const btVector3& pos1,const btQuaternion& orn0,const btQuaternion& orn1,btScalar timeStep,btVector3& linVel,btVector3& angVel)
|
83
|
-
{
|
84
|
-
linVel = (pos1 - pos0) / timeStep;
|
85
|
-
btVector3 axis;
|
86
|
-
btScalar angle;
|
87
|
-
if (orn0 != orn1)
|
88
|
-
{
|
89
|
-
calculateDiffAxisAngleQuaternion(orn0,orn1,axis,angle);
|
90
|
-
angVel = axis * angle / timeStep;
|
91
|
-
} else
|
92
|
-
{
|
93
|
-
angVel.setValue(0,0,0);
|
94
|
-
}
|
95
|
-
}
|
96
|
-
|
97
|
-
static void calculateDiffAxisAngleQuaternion(const btQuaternion& orn0,const btQuaternion& orn1a,btVector3& axis,btScalar& angle)
|
98
|
-
{
|
99
|
-
btQuaternion orn1 = orn0.nearest(orn1a);
|
100
|
-
btQuaternion dorn = orn1 * orn0.inverse();
|
101
|
-
angle = dorn.getAngle();
|
102
|
-
axis = btVector3(dorn.x(),dorn.y(),dorn.z());
|
103
|
-
axis[3] = btScalar(0.);
|
104
|
-
//check for axis length
|
105
|
-
btScalar len = axis.length2();
|
106
|
-
if (len < SIMD_EPSILON*SIMD_EPSILON)
|
107
|
-
axis = btVector3(btScalar(1.),btScalar(0.),btScalar(0.));
|
108
|
-
else
|
109
|
-
axis /= btSqrt(len);
|
110
|
-
}
|
111
|
-
|
112
|
-
static void calculateVelocity(const btTransform& transform0,const btTransform& transform1,btScalar timeStep,btVector3& linVel,btVector3& angVel)
|
113
|
-
{
|
114
|
-
linVel = (transform1.getOrigin() - transform0.getOrigin()) / timeStep;
|
115
|
-
btVector3 axis;
|
116
|
-
btScalar angle;
|
117
|
-
calculateDiffAxisAngle(transform0,transform1,axis,angle);
|
118
|
-
angVel = axis * angle / timeStep;
|
119
|
-
}
|
120
|
-
|
121
|
-
static void calculateDiffAxisAngle(const btTransform& transform0,const btTransform& transform1,btVector3& axis,btScalar& angle)
|
122
|
-
{
|
123
|
-
btMatrix3x3 dmat = transform1.getBasis() * transform0.getBasis().inverse();
|
124
|
-
btQuaternion dorn;
|
125
|
-
dmat.getRotation(dorn);
|
126
|
-
|
127
|
-
///floating point inaccuracy can lead to w component > 1..., which breaks
|
128
|
-
dorn.normalize();
|
129
|
-
|
130
|
-
angle = dorn.getAngle();
|
131
|
-
axis = btVector3(dorn.x(),dorn.y(),dorn.z());
|
132
|
-
axis[3] = btScalar(0.);
|
133
|
-
//check for axis length
|
134
|
-
btScalar len = axis.length2();
|
135
|
-
if (len < SIMD_EPSILON*SIMD_EPSILON)
|
136
|
-
axis = btVector3(btScalar(1.),btScalar(0.),btScalar(0.));
|
137
|
-
else
|
138
|
-
axis /= btSqrt(len);
|
139
|
-
}
|
140
|
-
|
141
|
-
};
|
142
|
-
|
143
|
-
|
144
|
-
///The btConvexSeparatingDistanceUtil can help speed up convex collision detection
|
145
|
-
///by conservatively updating a cached separating distance/vector instead of re-calculating the closest distance
|
146
|
-
class btConvexSeparatingDistanceUtil
|
147
|
-
{
|
148
|
-
btQuaternion m_ornA;
|
149
|
-
btQuaternion m_ornB;
|
150
|
-
btVector3 m_posA;
|
151
|
-
btVector3 m_posB;
|
152
|
-
|
153
|
-
btVector3 m_separatingNormal;
|
154
|
-
|
155
|
-
btScalar m_boundingRadiusA;
|
156
|
-
btScalar m_boundingRadiusB;
|
157
|
-
btScalar m_separatingDistance;
|
158
|
-
|
159
|
-
public:
|
160
|
-
|
161
|
-
btConvexSeparatingDistanceUtil(btScalar boundingRadiusA,btScalar boundingRadiusB)
|
162
|
-
:m_boundingRadiusA(boundingRadiusA),
|
163
|
-
m_boundingRadiusB(boundingRadiusB),
|
164
|
-
m_separatingDistance(0.f)
|
165
|
-
{
|
166
|
-
}
|
167
|
-
|
168
|
-
btScalar getConservativeSeparatingDistance()
|
169
|
-
{
|
170
|
-
return m_separatingDistance;
|
171
|
-
}
|
172
|
-
|
173
|
-
void updateSeparatingDistance(const btTransform& transA,const btTransform& transB)
|
174
|
-
{
|
175
|
-
const btVector3& toPosA = transA.getOrigin();
|
176
|
-
const btVector3& toPosB = transB.getOrigin();
|
177
|
-
btQuaternion toOrnA = transA.getRotation();
|
178
|
-
btQuaternion toOrnB = transB.getRotation();
|
179
|
-
|
180
|
-
if (m_separatingDistance>0.f)
|
181
|
-
{
|
182
|
-
|
183
|
-
|
184
|
-
btVector3 linVelA,angVelA,linVelB,angVelB;
|
185
|
-
btTransformUtil::calculateVelocityQuaternion(m_posA,toPosA,m_ornA,toOrnA,btScalar(1.),linVelA,angVelA);
|
186
|
-
btTransformUtil::calculateVelocityQuaternion(m_posB,toPosB,m_ornB,toOrnB,btScalar(1.),linVelB,angVelB);
|
187
|
-
btScalar maxAngularProjectedVelocity = angVelA.length() * m_boundingRadiusA + angVelB.length() * m_boundingRadiusB;
|
188
|
-
btVector3 relLinVel = (linVelB-linVelA);
|
189
|
-
btScalar relLinVelocLength = relLinVel.dot(m_separatingNormal);
|
190
|
-
if (relLinVelocLength<0.f)
|
191
|
-
{
|
192
|
-
relLinVelocLength = 0.f;
|
193
|
-
}
|
194
|
-
|
195
|
-
btScalar projectedMotion = maxAngularProjectedVelocity +relLinVelocLength;
|
196
|
-
m_separatingDistance -= projectedMotion;
|
197
|
-
}
|
198
|
-
|
199
|
-
m_posA = toPosA;
|
200
|
-
m_posB = toPosB;
|
201
|
-
m_ornA = toOrnA;
|
202
|
-
m_ornB = toOrnB;
|
203
|
-
}
|
204
|
-
|
205
|
-
void initSeparatingDistance(const btVector3& separatingVector,btScalar separatingDistance,const btTransform& transA,const btTransform& transB)
|
206
|
-
{
|
207
|
-
m_separatingDistance = separatingDistance;
|
208
|
-
|
209
|
-
if (m_separatingDistance>0.f)
|
210
|
-
{
|
211
|
-
m_separatingNormal = separatingVector;
|
212
|
-
|
213
|
-
const btVector3& toPosA = transA.getOrigin();
|
214
|
-
const btVector3& toPosB = transB.getOrigin();
|
215
|
-
btQuaternion toOrnA = transA.getRotation();
|
216
|
-
btQuaternion toOrnB = transB.getRotation();
|
217
|
-
m_posA = toPosA;
|
218
|
-
m_posB = toPosB;
|
219
|
-
m_ornA = toOrnA;
|
220
|
-
m_ornB = toOrnB;
|
221
|
-
}
|
222
|
-
}
|
223
|
-
|
224
|
-
};
|
225
|
-
|
226
|
-
|
227
|
-
#endif //BT_TRANSFORM_UTIL_H
|
228
|
-
|