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.
Files changed (284) hide show
  1. checksums.yaml +7 -0
  2. data/README.md +3 -0
  3. data/Rakefile +14 -2
  4. data/bindings/bullet/interface/BulletCollision/CollisionDispatch/btCollisionWorld.i +2 -2
  5. data/bindings/bullet/interface/bullet_wrap.cpp +17548 -6035
  6. data/bindings/bullet/interface/bullet_wrap.h +7 -7
  7. data/bindings/bullet/interface/bullet_wrap.o +0 -0
  8. data/lib/bullet.so +0 -0
  9. data/lib/ruby-bullet/version.rb +1 -1
  10. data/ruby-bullet.gemspec +0 -3
  11. metadata +169 -444
  12. data/deps/include/bullet/Bullet-C-Api.h +0 -176
  13. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btAxisSweep3.h +0 -1051
  14. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btBroadphaseInterface.h +0 -82
  15. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btBroadphaseProxy.h +0 -270
  16. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btCollisionAlgorithm.h +0 -80
  17. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btDbvt.h +0 -1257
  18. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btDbvtBroadphase.h +0 -146
  19. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btDispatcher.h +0 -110
  20. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btMultiSapBroadphase.h +0 -151
  21. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btOverlappingPairCache.h +0 -469
  22. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btOverlappingPairCallback.h +0 -40
  23. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btQuantizedBvh.h +0 -579
  24. data/deps/include/bullet/BulletCollision/BroadphaseCollision/btSimpleBroadphase.h +0 -171
  25. data/deps/include/bullet/BulletCollision/CollisionDispatch/SphereTriangleDetector.h +0 -51
  26. data/deps/include/bullet/BulletCollision/CollisionDispatch/btActivatingCollisionAlgorithm.h +0 -36
  27. data/deps/include/bullet/BulletCollision/CollisionDispatch/btBox2dBox2dCollisionAlgorithm.h +0 -66
  28. data/deps/include/bullet/BulletCollision/CollisionDispatch/btBoxBoxCollisionAlgorithm.h +0 -66
  29. data/deps/include/bullet/BulletCollision/CollisionDispatch/btBoxBoxDetector.h +0 -44
  30. data/deps/include/bullet/BulletCollision/CollisionDispatch/btCollisionConfiguration.h +0 -48
  31. data/deps/include/bullet/BulletCollision/CollisionDispatch/btCollisionCreateFunc.h +0 -45
  32. data/deps/include/bullet/BulletCollision/CollisionDispatch/btCollisionDispatcher.h +0 -172
  33. data/deps/include/bullet/BulletCollision/CollisionDispatch/btCollisionObject.h +0 -524
  34. data/deps/include/bullet/BulletCollision/CollisionDispatch/btCollisionWorld.h +0 -509
  35. data/deps/include/bullet/BulletCollision/CollisionDispatch/btCompoundCollisionAlgorithm.h +0 -86
  36. data/deps/include/bullet/BulletCollision/CollisionDispatch/btConvex2dConvex2dAlgorithm.h +0 -95
  37. data/deps/include/bullet/BulletCollision/CollisionDispatch/btConvexConcaveCollisionAlgorithm.h +0 -116
  38. data/deps/include/bullet/BulletCollision/CollisionDispatch/btConvexConvexAlgorithm.h +0 -109
  39. data/deps/include/bullet/BulletCollision/CollisionDispatch/btConvexPlaneCollisionAlgorithm.h +0 -84
  40. data/deps/include/bullet/BulletCollision/CollisionDispatch/btDefaultCollisionConfiguration.h +0 -137
  41. data/deps/include/bullet/BulletCollision/CollisionDispatch/btEmptyCollisionAlgorithm.h +0 -54
  42. data/deps/include/bullet/BulletCollision/CollisionDispatch/btGhostObject.h +0 -175
  43. data/deps/include/bullet/BulletCollision/CollisionDispatch/btInternalEdgeUtility.h +0 -46
  44. data/deps/include/bullet/BulletCollision/CollisionDispatch/btManifoldResult.h +0 -128
  45. data/deps/include/bullet/BulletCollision/CollisionDispatch/btSimulationIslandManager.h +0 -81
  46. data/deps/include/bullet/BulletCollision/CollisionDispatch/btSphereBoxCollisionAlgorithm.h +0 -75
  47. data/deps/include/bullet/BulletCollision/CollisionDispatch/btSphereSphereCollisionAlgorithm.h +0 -66
  48. data/deps/include/bullet/BulletCollision/CollisionDispatch/btSphereTriangleCollisionAlgorithm.h +0 -69
  49. data/deps/include/bullet/BulletCollision/CollisionDispatch/btUnionFind.h +0 -129
  50. data/deps/include/bullet/BulletCollision/CollisionShapes/btBox2dShape.h +0 -369
  51. data/deps/include/bullet/BulletCollision/CollisionShapes/btBoxShape.h +0 -312
  52. data/deps/include/bullet/BulletCollision/CollisionShapes/btBvhTriangleMeshShape.h +0 -139
  53. data/deps/include/bullet/BulletCollision/CollisionShapes/btCapsuleShape.h +0 -173
  54. data/deps/include/bullet/BulletCollision/CollisionShapes/btCollisionMargin.h +0 -27
  55. data/deps/include/bullet/BulletCollision/CollisionShapes/btCollisionShape.h +0 -150
  56. data/deps/include/bullet/BulletCollision/CollisionShapes/btCompoundShape.h +0 -212
  57. data/deps/include/bullet/BulletCollision/CollisionShapes/btConcaveShape.h +0 -60
  58. data/deps/include/bullet/BulletCollision/CollisionShapes/btConeShape.h +0 -103
  59. data/deps/include/bullet/BulletCollision/CollisionShapes/btConvex2dShape.h +0 -80
  60. data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexHullShape.h +0 -122
  61. data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexInternalShape.h +0 -224
  62. data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexPointCloudShape.h +0 -105
  63. data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexPolyhedron.h +0 -62
  64. data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexShape.h +0 -84
  65. data/deps/include/bullet/BulletCollision/CollisionShapes/btConvexTriangleMeshShape.h +0 -75
  66. data/deps/include/bullet/BulletCollision/CollisionShapes/btCylinderShape.h +0 -200
  67. data/deps/include/bullet/BulletCollision/CollisionShapes/btEmptyShape.h +0 -70
  68. data/deps/include/bullet/BulletCollision/CollisionShapes/btHeightfieldTerrainShape.h +0 -161
  69. data/deps/include/bullet/BulletCollision/CollisionShapes/btMaterial.h +0 -35
  70. data/deps/include/bullet/BulletCollision/CollisionShapes/btMinkowskiSumShape.h +0 -60
  71. data/deps/include/bullet/BulletCollision/CollisionShapes/btMultiSphereShape.h +0 -99
  72. data/deps/include/bullet/BulletCollision/CollisionShapes/btMultimaterialTriangleMeshShape.h +0 -120
  73. data/deps/include/bullet/BulletCollision/CollisionShapes/btOptimizedBvh.h +0 -65
  74. data/deps/include/bullet/BulletCollision/CollisionShapes/btPolyhedralConvexShape.h +0 -112
  75. data/deps/include/bullet/BulletCollision/CollisionShapes/btScaledBvhTriangleMeshShape.h +0 -93
  76. data/deps/include/bullet/BulletCollision/CollisionShapes/btShapeHull.h +0 -59
  77. data/deps/include/bullet/BulletCollision/CollisionShapes/btSphereShape.h +0 -73
  78. data/deps/include/bullet/BulletCollision/CollisionShapes/btStaticPlaneShape.h +0 -103
  79. data/deps/include/bullet/BulletCollision/CollisionShapes/btStridingMeshInterface.h +0 -162
  80. data/deps/include/bullet/BulletCollision/CollisionShapes/btTetrahedronShape.h +0 -74
  81. data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleBuffer.h +0 -69
  82. data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleCallback.h +0 -42
  83. data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleIndexVertexArray.h +0 -133
  84. data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleIndexVertexMaterialArray.h +0 -84
  85. data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleInfoMap.h +0 -241
  86. data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleMesh.h +0 -69
  87. data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleMeshShape.h +0 -89
  88. data/deps/include/bullet/BulletCollision/CollisionShapes/btTriangleShape.h +0 -182
  89. data/deps/include/bullet/BulletCollision/CollisionShapes/btUniformScalingShape.h +0 -87
  90. data/deps/include/bullet/BulletCollision/Gimpact/btBoxCollision.h +0 -647
  91. data/deps/include/bullet/BulletCollision/Gimpact/btClipPolygon.h +0 -182
  92. data/deps/include/bullet/BulletCollision/Gimpact/btContactProcessing.h +0 -145
  93. data/deps/include/bullet/BulletCollision/Gimpact/btGImpactBvh.h +0 -396
  94. data/deps/include/bullet/BulletCollision/Gimpact/btGImpactCollisionAlgorithm.h +0 -306
  95. data/deps/include/bullet/BulletCollision/Gimpact/btGImpactMassUtil.h +0 -60
  96. data/deps/include/bullet/BulletCollision/Gimpact/btGImpactQuantizedBvh.h +0 -372
  97. data/deps/include/bullet/BulletCollision/Gimpact/btGImpactShape.h +0 -1171
  98. data/deps/include/bullet/BulletCollision/Gimpact/btGenericPoolAllocator.h +0 -163
  99. data/deps/include/bullet/BulletCollision/Gimpact/btGeometryOperations.h +0 -212
  100. data/deps/include/bullet/BulletCollision/Gimpact/btQuantization.h +0 -88
  101. data/deps/include/bullet/BulletCollision/Gimpact/btTriangleShapeEx.h +0 -180
  102. data/deps/include/bullet/BulletCollision/Gimpact/gim_array.h +0 -326
  103. data/deps/include/bullet/BulletCollision/Gimpact/gim_basic_geometry_operations.h +0 -543
  104. data/deps/include/bullet/BulletCollision/Gimpact/gim_bitset.h +0 -123
  105. data/deps/include/bullet/BulletCollision/Gimpact/gim_box_collision.h +0 -590
  106. data/deps/include/bullet/BulletCollision/Gimpact/gim_box_set.h +0 -674
  107. data/deps/include/bullet/BulletCollision/Gimpact/gim_clip_polygon.h +0 -210
  108. data/deps/include/bullet/BulletCollision/Gimpact/gim_contact.h +0 -164
  109. data/deps/include/bullet/BulletCollision/Gimpact/gim_geom_types.h +0 -97
  110. data/deps/include/bullet/BulletCollision/Gimpact/gim_geometry.h +0 -42
  111. data/deps/include/bullet/BulletCollision/Gimpact/gim_hash_table.h +0 -902
  112. data/deps/include/bullet/BulletCollision/Gimpact/gim_linear_math.h +0 -1573
  113. data/deps/include/bullet/BulletCollision/Gimpact/gim_math.h +0 -157
  114. data/deps/include/bullet/BulletCollision/Gimpact/gim_memory.h +0 -190
  115. data/deps/include/bullet/BulletCollision/Gimpact/gim_radixsort.h +0 -406
  116. data/deps/include/bullet/BulletCollision/Gimpact/gim_tri_collision.h +0 -379
  117. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btContinuousConvexCollision.h +0 -59
  118. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btConvexCast.h +0 -73
  119. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btConvexPenetrationDepthSolver.h +0 -42
  120. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btDiscreteCollisionDetectorInterface.h +0 -91
  121. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btGjkConvexCast.h +0 -50
  122. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btGjkEpa2.h +0 -75
  123. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btGjkEpaPenetrationDepthSolver.h +0 -43
  124. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btGjkPairDetector.h +0 -103
  125. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btManifoldPoint.h +0 -158
  126. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btMinkowskiPenetrationDepthSolver.h +0 -40
  127. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btPersistentManifold.h +0 -228
  128. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btPointCollector.h +0 -64
  129. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btPolyhedralContactClipping.h +0 -46
  130. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btRaycastCallback.h +0 -72
  131. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btSimplexSolverInterface.h +0 -63
  132. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btSubSimplexConvexCast.h +0 -50
  133. data/deps/include/bullet/BulletCollision/NarrowPhaseCollision/btVoronoiSimplexSolver.h +0 -179
  134. data/deps/include/bullet/BulletCollision/btBulletCollisionCommon.h +0 -69
  135. data/deps/include/bullet/BulletDynamics/Character/btCharacterControllerInterface.h +0 -46
  136. data/deps/include/bullet/BulletDynamics/Character/btKinematicCharacterController.h +0 -163
  137. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btConeTwistConstraint.h +0 -346
  138. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btConstraintSolver.h +0 -52
  139. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btContactConstraint.h +0 -71
  140. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btContactSolverInfo.h +0 -87
  141. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btGeneric6DofConstraint.h +0 -614
  142. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btGeneric6DofSpringConstraint.h +0 -99
  143. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btHinge2Constraint.h +0 -58
  144. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btHingeConstraint.h +0 -381
  145. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btJacobianEntry.h +0 -156
  146. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btPoint2PointConstraint.h +0 -161
  147. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btSequentialImpulseConstraintSolver.h +0 -130
  148. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btSliderConstraint.h +0 -333
  149. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btSolve2LinearConstraint.h +0 -107
  150. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btSolverBody.h +0 -191
  151. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btSolverConstraint.h +0 -98
  152. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btTypedConstraint.h +0 -452
  153. data/deps/include/bullet/BulletDynamics/ConstraintSolver/btUniversalConstraint.h +0 -62
  154. data/deps/include/bullet/BulletDynamics/Dynamics/btActionInterface.h +0 -46
  155. data/deps/include/bullet/BulletDynamics/Dynamics/btDiscreteDynamicsWorld.h +0 -203
  156. data/deps/include/bullet/BulletDynamics/Dynamics/btDynamicsWorld.h +0 -151
  157. data/deps/include/bullet/BulletDynamics/Dynamics/btRigidBody.h +0 -691
  158. data/deps/include/bullet/BulletDynamics/Dynamics/btSimpleDynamicsWorld.h +0 -89
  159. data/deps/include/bullet/BulletDynamics/Vehicle/btRaycastVehicle.h +0 -236
  160. data/deps/include/bullet/BulletDynamics/Vehicle/btVehicleRaycaster.h +0 -35
  161. data/deps/include/bullet/BulletDynamics/Vehicle/btWheelInfo.h +0 -119
  162. data/deps/include/bullet/BulletDynamics/btBulletDynamicsCommon.h +0 -48
  163. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverBuffer_DX11.h +0 -323
  164. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverLinkData_DX11.h +0 -103
  165. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverLinkData_DX11SIMDAware.h +0 -173
  166. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverTriangleData_DX11.h +0 -96
  167. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverVertexBuffer_DX11.h +0 -107
  168. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolverVertexData_DX11.h +0 -63
  169. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolver_DX11.h +0 -691
  170. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/DX11/btSoftBodySolver_DX11SIMDAware.h +0 -81
  171. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverBuffer_OpenCL.h +0 -209
  172. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverLinkData_OpenCL.h +0 -99
  173. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverLinkData_OpenCLSIMDAware.h +0 -169
  174. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverOutputCLtoGL.h +0 -62
  175. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverTriangleData_OpenCL.h +0 -84
  176. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverVertexBuffer_OpenGL.h +0 -166
  177. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolverVertexData_OpenCL.h +0 -52
  178. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolver_OpenCL.h +0 -527
  179. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/OpenCL/btSoftBodySolver_OpenCLSIMDAware.h +0 -81
  180. data/deps/include/bullet/BulletMultiThreaded/GpuSoftBodySolvers/Shared/btSoftBodySolverData.h +0 -748
  181. data/deps/include/bullet/BulletMultiThreaded/HeapManager.h +0 -117
  182. data/deps/include/bullet/BulletMultiThreaded/PlatformDefinitions.h +0 -99
  183. data/deps/include/bullet/BulletMultiThreaded/PosixThreadSupport.h +0 -142
  184. data/deps/include/bullet/BulletMultiThreaded/PpuAddressSpace.h +0 -37
  185. data/deps/include/bullet/BulletMultiThreaded/SequentialThreadSupport.h +0 -96
  186. data/deps/include/bullet/BulletMultiThreaded/SpuCollisionObjectWrapper.h +0 -40
  187. data/deps/include/bullet/BulletMultiThreaded/SpuCollisionTaskProcess.h +0 -163
  188. data/deps/include/bullet/BulletMultiThreaded/SpuContactManifoldCollisionAlgorithm.h +0 -120
  189. data/deps/include/bullet/BulletMultiThreaded/SpuDoubleBuffer.h +0 -126
  190. data/deps/include/bullet/BulletMultiThreaded/SpuFakeDma.h +0 -135
  191. data/deps/include/bullet/BulletMultiThreaded/SpuGatheringCollisionDispatcher.h +0 -72
  192. data/deps/include/bullet/BulletMultiThreaded/SpuLibspe2Support.h +0 -180
  193. data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/Box.h +0 -167
  194. data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuCollisionShapes.h +0 -128
  195. data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuContactResult.h +0 -106
  196. data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuConvexPenetrationDepthSolver.h +0 -51
  197. data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuGatheringCollisionTask.h +0 -140
  198. data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuLocalSupport.h +0 -19
  199. data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuMinkowskiPenetrationDepthSolver.h +0 -48
  200. data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/SpuPreferredPenetrationDirections.h +0 -70
  201. data/deps/include/bullet/BulletMultiThreaded/SpuNarrowPhaseCollisionTask/boxBoxDistance.h +0 -65
  202. data/deps/include/bullet/BulletMultiThreaded/SpuSampleTask/SpuSampleTask.h +0 -54
  203. data/deps/include/bullet/BulletMultiThreaded/SpuSampleTaskProcess.h +0 -153
  204. data/deps/include/bullet/BulletMultiThreaded/SpuSync.h +0 -149
  205. data/deps/include/bullet/BulletMultiThreaded/TrbDynBody.h +0 -79
  206. data/deps/include/bullet/BulletMultiThreaded/TrbStateVec.h +0 -339
  207. data/deps/include/bullet/BulletMultiThreaded/Win32ThreadSupport.h +0 -138
  208. data/deps/include/bullet/BulletMultiThreaded/btGpu3DGridBroadphase.h +0 -138
  209. data/deps/include/bullet/BulletMultiThreaded/btGpu3DGridBroadphaseSharedCode.h +0 -430
  210. data/deps/include/bullet/BulletMultiThreaded/btGpu3DGridBroadphaseSharedDefs.h +0 -61
  211. data/deps/include/bullet/BulletMultiThreaded/btGpu3DGridBroadphaseSharedTypes.h +0 -67
  212. data/deps/include/bullet/BulletMultiThreaded/btGpuDefines.h +0 -211
  213. data/deps/include/bullet/BulletMultiThreaded/btGpuUtilsSharedCode.h +0 -55
  214. data/deps/include/bullet/BulletMultiThreaded/btGpuUtilsSharedDefs.h +0 -52
  215. data/deps/include/bullet/BulletMultiThreaded/btParallelConstraintSolver.h +0 -285
  216. data/deps/include/bullet/BulletMultiThreaded/btThreadSupportInterface.h +0 -85
  217. data/deps/include/bullet/BulletMultiThreaded/vectormath2bullet.h +0 -73
  218. data/deps/include/bullet/BulletSoftBody/btDefaultSoftBodySolver.h +0 -63
  219. data/deps/include/bullet/BulletSoftBody/btSoftBody.h +0 -987
  220. data/deps/include/bullet/BulletSoftBody/btSoftBodyConcaveCollisionAlgorithm.h +0 -153
  221. data/deps/include/bullet/BulletSoftBody/btSoftBodyData.h +0 -217
  222. data/deps/include/bullet/BulletSoftBody/btSoftBodyHelpers.h +0 -143
  223. data/deps/include/bullet/BulletSoftBody/btSoftBodyInternals.h +0 -930
  224. data/deps/include/bullet/BulletSoftBody/btSoftBodyRigidBodyCollisionConfiguration.h +0 -48
  225. data/deps/include/bullet/BulletSoftBody/btSoftBodySolverVertexBuffer.h +0 -165
  226. data/deps/include/bullet/BulletSoftBody/btSoftBodySolvers.h +0 -154
  227. data/deps/include/bullet/BulletSoftBody/btSoftRigidCollisionAlgorithm.h +0 -75
  228. data/deps/include/bullet/BulletSoftBody/btSoftRigidDynamicsWorld.h +0 -107
  229. data/deps/include/bullet/BulletSoftBody/btSoftSoftCollisionAlgorithm.h +0 -69
  230. data/deps/include/bullet/BulletSoftBody/btSparseSDF.h +0 -306
  231. data/deps/include/bullet/LinearMath/btAabbUtil2.h +0 -236
  232. data/deps/include/bullet/LinearMath/btAlignedAllocator.h +0 -107
  233. data/deps/include/bullet/LinearMath/btAlignedObjectArray.h +0 -494
  234. data/deps/include/bullet/LinearMath/btConvexHull.h +0 -241
  235. data/deps/include/bullet/LinearMath/btConvexHullComputer.h +0 -103
  236. data/deps/include/bullet/LinearMath/btDefaultMotionState.h +0 -40
  237. data/deps/include/bullet/LinearMath/btGeometryUtil.h +0 -42
  238. data/deps/include/bullet/LinearMath/btGrahamScan2dConvexHull.h +0 -110
  239. data/deps/include/bullet/LinearMath/btHashMap.h +0 -450
  240. data/deps/include/bullet/LinearMath/btIDebugDraw.h +0 -418
  241. data/deps/include/bullet/LinearMath/btList.h +0 -73
  242. data/deps/include/bullet/LinearMath/btMatrix3x3.h +0 -771
  243. data/deps/include/bullet/LinearMath/btMinMax.h +0 -71
  244. data/deps/include/bullet/LinearMath/btMotionState.h +0 -40
  245. data/deps/include/bullet/LinearMath/btPoolAllocator.h +0 -121
  246. data/deps/include/bullet/LinearMath/btQuadWord.h +0 -180
  247. data/deps/include/bullet/LinearMath/btQuaternion.h +0 -430
  248. data/deps/include/bullet/LinearMath/btQuickprof.h +0 -203
  249. data/deps/include/bullet/LinearMath/btRandom.h +0 -42
  250. data/deps/include/bullet/LinearMath/btScalar.h +0 -539
  251. data/deps/include/bullet/LinearMath/btSerializer.h +0 -639
  252. data/deps/include/bullet/LinearMath/btStackAlloc.h +0 -116
  253. data/deps/include/bullet/LinearMath/btTransform.h +0 -307
  254. data/deps/include/bullet/LinearMath/btTransformUtil.h +0 -228
  255. data/deps/include/bullet/LinearMath/btVector3.h +0 -766
  256. data/deps/include/bullet/MiniCL/MiniCLTask/MiniCLTask.h +0 -62
  257. data/deps/include/bullet/MiniCL/MiniCLTaskScheduler.h +0 -194
  258. data/deps/include/bullet/MiniCL/cl.h +0 -867
  259. data/deps/include/bullet/MiniCL/cl_MiniCL_Defs.h +0 -439
  260. data/deps/include/bullet/MiniCL/cl_gl.h +0 -113
  261. data/deps/include/bullet/MiniCL/cl_platform.h +0 -254
  262. data/deps/include/bullet/btBulletCollisionCommon.h +0 -69
  263. data/deps/include/bullet/btBulletDynamicsCommon.h +0 -48
  264. data/deps/include/bullet/vectormath/scalar/boolInVec.h +0 -225
  265. data/deps/include/bullet/vectormath/scalar/floatInVec.h +0 -343
  266. data/deps/include/bullet/vectormath/scalar/mat_aos.h +0 -1630
  267. data/deps/include/bullet/vectormath/scalar/quat_aos.h +0 -433
  268. data/deps/include/bullet/vectormath/scalar/vec_aos.h +0 -1426
  269. data/deps/include/bullet/vectormath/scalar/vectormath_aos.h +0 -1872
  270. data/deps/include/bullet/vectormath/sse/boolInVec.h +0 -247
  271. data/deps/include/bullet/vectormath/sse/floatInVec.h +0 -340
  272. data/deps/include/bullet/vectormath/sse/mat_aos.h +0 -2190
  273. data/deps/include/bullet/vectormath/sse/quat_aos.h +0 -579
  274. data/deps/include/bullet/vectormath/sse/vec_aos.h +0 -1455
  275. data/deps/include/bullet/vectormath/sse/vecidx_aos.h +0 -80
  276. data/deps/include/bullet/vectormath/sse/vectormath_aos.h +0 -2547
  277. data/deps/include/bullet/vectormath/vmInclude.h +0 -27
  278. data/deps/lib/libBulletCollision.a +0 -0
  279. data/deps/lib/libBulletDynamics.a +0 -0
  280. data/deps/lib/libBulletMultiThreaded.a +0 -0
  281. data/deps/lib/libBulletSoftBody.a +0 -0
  282. data/deps/lib/libBulletSoftBodySolvers_OpenCL_Mini.a +0 -0
  283. data/deps/lib/libLinearMath.a +0 -0
  284. 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
-