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,430 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
Bullet Continuous Collision Detection and Physics Library, http://bulletphysics.org
|
3
|
-
Copyright (C) 2006, 2009 Sony Computer Entertainment Inc.
|
4
|
-
|
5
|
-
This software is provided 'as-is', without any express or implied warranty.
|
6
|
-
In no event will the authors be held liable for any damages arising from the use of this software.
|
7
|
-
Permission is granted to anyone to use this software for any purpose,
|
8
|
-
including commercial applications, and to alter it and redistribute it freely,
|
9
|
-
subject to the following restrictions:
|
10
|
-
|
11
|
-
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.
|
12
|
-
2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
|
13
|
-
3. This notice may not be removed or altered from any source distribution.
|
14
|
-
*/
|
15
|
-
|
16
|
-
//----------------------------------------------------------------------------------------
|
17
|
-
|
18
|
-
//----------------------------------------------------------------------------------------
|
19
|
-
//----------------------------------------------------------------------------------------
|
20
|
-
//----------------------------------------------------------------------------------------
|
21
|
-
//----------------------------------------------------------------------------------------
|
22
|
-
// K E R N E L F U N C T I O N S
|
23
|
-
//----------------------------------------------------------------------------------------
|
24
|
-
//----------------------------------------------------------------------------------------
|
25
|
-
//----------------------------------------------------------------------------------------
|
26
|
-
//----------------------------------------------------------------------------------------
|
27
|
-
//----------------------------------------------------------------------------------------
|
28
|
-
//----------------------------------------------------------------------------------------
|
29
|
-
|
30
|
-
// calculate position in uniform grid
|
31
|
-
BT_GPU___device__ int3 bt3DGrid_calcGridPos(float4 p)
|
32
|
-
{
|
33
|
-
int3 gridPos;
|
34
|
-
gridPos.x = (int)floor((p.x - BT_GPU_params.m_worldOriginX) / BT_GPU_params.m_cellSizeX);
|
35
|
-
gridPos.y = (int)floor((p.y - BT_GPU_params.m_worldOriginY) / BT_GPU_params.m_cellSizeY);
|
36
|
-
gridPos.z = (int)floor((p.z - BT_GPU_params.m_worldOriginZ) / BT_GPU_params.m_cellSizeZ);
|
37
|
-
return gridPos;
|
38
|
-
} // bt3DGrid_calcGridPos()
|
39
|
-
|
40
|
-
//----------------------------------------------------------------------------------------
|
41
|
-
|
42
|
-
// calculate address in grid from position (clamping to edges)
|
43
|
-
BT_GPU___device__ uint bt3DGrid_calcGridHash(int3 gridPos)
|
44
|
-
{
|
45
|
-
gridPos.x = BT_GPU_max(0, BT_GPU_min(gridPos.x, (int)BT_GPU_params.m_gridSizeX - 1));
|
46
|
-
gridPos.y = BT_GPU_max(0, BT_GPU_min(gridPos.y, (int)BT_GPU_params.m_gridSizeY - 1));
|
47
|
-
gridPos.z = BT_GPU_max(0, BT_GPU_min(gridPos.z, (int)BT_GPU_params.m_gridSizeZ - 1));
|
48
|
-
return BT_GPU___mul24(BT_GPU___mul24(gridPos.z, BT_GPU_params.m_gridSizeY), BT_GPU_params.m_gridSizeX) + BT_GPU___mul24(gridPos.y, BT_GPU_params.m_gridSizeX) + gridPos.x;
|
49
|
-
} // bt3DGrid_calcGridHash()
|
50
|
-
|
51
|
-
//----------------------------------------------------------------------------------------
|
52
|
-
|
53
|
-
// calculate grid hash value for each body using its AABB
|
54
|
-
BT_GPU___global__ void calcHashAABBD(bt3DGrid3F1U* pAABB, uint2* pHash, uint numBodies)
|
55
|
-
{
|
56
|
-
int index = BT_GPU___mul24(BT_GPU_blockIdx.x, BT_GPU_blockDim.x) + BT_GPU_threadIdx.x;
|
57
|
-
if(index >= (int)numBodies)
|
58
|
-
{
|
59
|
-
return;
|
60
|
-
}
|
61
|
-
bt3DGrid3F1U bbMin = pAABB[index*2];
|
62
|
-
bt3DGrid3F1U bbMax = pAABB[index*2 + 1];
|
63
|
-
float4 pos;
|
64
|
-
pos.x = (bbMin.fx + bbMax.fx) * 0.5f;
|
65
|
-
pos.y = (bbMin.fy + bbMax.fy) * 0.5f;
|
66
|
-
pos.z = (bbMin.fz + bbMax.fz) * 0.5f;
|
67
|
-
// get address in grid
|
68
|
-
int3 gridPos = bt3DGrid_calcGridPos(pos);
|
69
|
-
uint gridHash = bt3DGrid_calcGridHash(gridPos);
|
70
|
-
// store grid hash and body index
|
71
|
-
pHash[index] = BT_GPU_make_uint2(gridHash, index);
|
72
|
-
} // calcHashAABBD()
|
73
|
-
|
74
|
-
//----------------------------------------------------------------------------------------
|
75
|
-
|
76
|
-
BT_GPU___global__ void findCellStartD(uint2* pHash, uint* cellStart, uint numBodies)
|
77
|
-
{
|
78
|
-
int index = BT_GPU___mul24(BT_GPU_blockIdx.x, BT_GPU_blockDim.x) + BT_GPU_threadIdx.x;
|
79
|
-
if(index >= (int)numBodies)
|
80
|
-
{
|
81
|
-
return;
|
82
|
-
}
|
83
|
-
uint2 sortedData = pHash[index];
|
84
|
-
// Load hash data into shared memory so that we can look
|
85
|
-
// at neighboring body's hash value without loading
|
86
|
-
// two hash values per thread
|
87
|
-
BT_GPU___shared__ uint sharedHash[257];
|
88
|
-
sharedHash[BT_GPU_threadIdx.x+1] = sortedData.x;
|
89
|
-
if((index > 0) && (BT_GPU_threadIdx.x == 0))
|
90
|
-
{
|
91
|
-
// first thread in block must load neighbor body hash
|
92
|
-
volatile uint2 prevData = pHash[index-1];
|
93
|
-
sharedHash[0] = prevData.x;
|
94
|
-
}
|
95
|
-
BT_GPU___syncthreads();
|
96
|
-
if((index == 0) || (sortedData.x != sharedHash[BT_GPU_threadIdx.x]))
|
97
|
-
{
|
98
|
-
cellStart[sortedData.x] = index;
|
99
|
-
}
|
100
|
-
} // findCellStartD()
|
101
|
-
|
102
|
-
//----------------------------------------------------------------------------------------
|
103
|
-
|
104
|
-
BT_GPU___device__ uint cudaTestAABBOverlap(bt3DGrid3F1U min0, bt3DGrid3F1U max0, bt3DGrid3F1U min1, bt3DGrid3F1U max1)
|
105
|
-
{
|
106
|
-
return (min0.fx <= max1.fx)&& (min1.fx <= max0.fx) &&
|
107
|
-
(min0.fy <= max1.fy)&& (min1.fy <= max0.fy) &&
|
108
|
-
(min0.fz <= max1.fz)&& (min1.fz <= max0.fz);
|
109
|
-
} // cudaTestAABBOverlap()
|
110
|
-
|
111
|
-
//----------------------------------------------------------------------------------------
|
112
|
-
|
113
|
-
BT_GPU___device__ void findPairsInCell( int3 gridPos,
|
114
|
-
uint index,
|
115
|
-
uint2* pHash,
|
116
|
-
uint* pCellStart,
|
117
|
-
bt3DGrid3F1U* pAABB,
|
118
|
-
uint* pPairBuff,
|
119
|
-
uint2* pPairBuffStartCurr,
|
120
|
-
uint numBodies)
|
121
|
-
{
|
122
|
-
if ( (gridPos.x < 0) || (gridPos.x > (int)BT_GPU_params.m_gridSizeX - 1)
|
123
|
-
|| (gridPos.y < 0) || (gridPos.y > (int)BT_GPU_params.m_gridSizeY - 1)
|
124
|
-
|| (gridPos.z < 0) || (gridPos.z > (int)BT_GPU_params.m_gridSizeZ - 1))
|
125
|
-
{
|
126
|
-
return;
|
127
|
-
}
|
128
|
-
uint gridHash = bt3DGrid_calcGridHash(gridPos);
|
129
|
-
// get start of bucket for this cell
|
130
|
-
uint bucketStart = pCellStart[gridHash];
|
131
|
-
if (bucketStart == 0xffffffff)
|
132
|
-
{
|
133
|
-
return; // cell empty
|
134
|
-
}
|
135
|
-
// iterate over bodies in this cell
|
136
|
-
uint2 sortedData = pHash[index];
|
137
|
-
uint unsorted_indx = sortedData.y;
|
138
|
-
bt3DGrid3F1U min0 = BT_GPU_FETCH(pAABB, unsorted_indx*2);
|
139
|
-
bt3DGrid3F1U max0 = BT_GPU_FETCH(pAABB, unsorted_indx*2 + 1);
|
140
|
-
uint handleIndex = min0.uw;
|
141
|
-
uint2 start_curr = pPairBuffStartCurr[handleIndex];
|
142
|
-
uint start = start_curr.x;
|
143
|
-
uint curr = start_curr.y;
|
144
|
-
uint2 start_curr_next = pPairBuffStartCurr[handleIndex+1];
|
145
|
-
uint curr_max = start_curr_next.x - start - 1;
|
146
|
-
uint bucketEnd = bucketStart + BT_GPU_params.m_maxBodiesPerCell;
|
147
|
-
bucketEnd = (bucketEnd > numBodies) ? numBodies : bucketEnd;
|
148
|
-
for(uint index2 = bucketStart; index2 < bucketEnd; index2++)
|
149
|
-
{
|
150
|
-
uint2 cellData = pHash[index2];
|
151
|
-
if (cellData.x != gridHash)
|
152
|
-
{
|
153
|
-
break; // no longer in same bucket
|
154
|
-
}
|
155
|
-
uint unsorted_indx2 = cellData.y;
|
156
|
-
if (unsorted_indx2 < unsorted_indx) // check not colliding with self
|
157
|
-
{
|
158
|
-
bt3DGrid3F1U min1 = BT_GPU_FETCH(pAABB, unsorted_indx2*2);
|
159
|
-
bt3DGrid3F1U max1 = BT_GPU_FETCH(pAABB, unsorted_indx2*2 + 1);
|
160
|
-
if(cudaTestAABBOverlap(min0, max0, min1, max1))
|
161
|
-
{
|
162
|
-
uint handleIndex2 = min1.uw;
|
163
|
-
uint k;
|
164
|
-
for(k = 0; k < curr; k++)
|
165
|
-
{
|
166
|
-
uint old_pair = pPairBuff[start+k] & (~BT_3DGRID_PAIR_ANY_FLG);
|
167
|
-
if(old_pair == handleIndex2)
|
168
|
-
{
|
169
|
-
pPairBuff[start+k] |= BT_3DGRID_PAIR_FOUND_FLG;
|
170
|
-
break;
|
171
|
-
}
|
172
|
-
}
|
173
|
-
if(k == curr)
|
174
|
-
{
|
175
|
-
if(curr >= curr_max)
|
176
|
-
{ // not a good solution, but let's avoid crash
|
177
|
-
break;
|
178
|
-
}
|
179
|
-
pPairBuff[start+curr] = handleIndex2 | BT_3DGRID_PAIR_NEW_FLG;
|
180
|
-
curr++;
|
181
|
-
}
|
182
|
-
}
|
183
|
-
}
|
184
|
-
}
|
185
|
-
pPairBuffStartCurr[handleIndex] = BT_GPU_make_uint2(start, curr);
|
186
|
-
return;
|
187
|
-
} // findPairsInCell()
|
188
|
-
|
189
|
-
//----------------------------------------------------------------------------------------
|
190
|
-
|
191
|
-
BT_GPU___global__ void findOverlappingPairsD( bt3DGrid3F1U* pAABB, uint2* pHash, uint* pCellStart,
|
192
|
-
uint* pPairBuff, uint2* pPairBuffStartCurr, uint numBodies)
|
193
|
-
{
|
194
|
-
int index = BT_GPU___mul24(BT_GPU_blockIdx.x, BT_GPU_blockDim.x) + BT_GPU_threadIdx.x;
|
195
|
-
if(index >= (int)numBodies)
|
196
|
-
{
|
197
|
-
return;
|
198
|
-
}
|
199
|
-
uint2 sortedData = pHash[index];
|
200
|
-
uint unsorted_indx = sortedData.y;
|
201
|
-
bt3DGrid3F1U bbMin = BT_GPU_FETCH(pAABB, unsorted_indx*2);
|
202
|
-
bt3DGrid3F1U bbMax = BT_GPU_FETCH(pAABB, unsorted_indx*2 + 1);
|
203
|
-
float4 pos;
|
204
|
-
pos.x = (bbMin.fx + bbMax.fx) * 0.5f;
|
205
|
-
pos.y = (bbMin.fy + bbMax.fy) * 0.5f;
|
206
|
-
pos.z = (bbMin.fz + bbMax.fz) * 0.5f;
|
207
|
-
// get address in grid
|
208
|
-
int3 gridPos = bt3DGrid_calcGridPos(pos);
|
209
|
-
// examine only neighbouring cells
|
210
|
-
for(int z=-1; z<=1; z++) {
|
211
|
-
for(int y=-1; y<=1; y++) {
|
212
|
-
for(int x=-1; x<=1; x++) {
|
213
|
-
findPairsInCell(gridPos + BT_GPU_make_int3(x, y, z), index, pHash, pCellStart, pAABB, pPairBuff, pPairBuffStartCurr, numBodies);
|
214
|
-
}
|
215
|
-
}
|
216
|
-
}
|
217
|
-
} // findOverlappingPairsD()
|
218
|
-
|
219
|
-
//----------------------------------------------------------------------------------------
|
220
|
-
|
221
|
-
BT_GPU___global__ void findPairsLargeD( bt3DGrid3F1U* pAABB, uint2* pHash, uint* pCellStart, uint* pPairBuff,
|
222
|
-
uint2* pPairBuffStartCurr, uint numBodies, uint numLarge)
|
223
|
-
{
|
224
|
-
int index = BT_GPU___mul24(BT_GPU_blockIdx.x, BT_GPU_blockDim.x) + BT_GPU_threadIdx.x;
|
225
|
-
if(index >= (int)numBodies)
|
226
|
-
{
|
227
|
-
return;
|
228
|
-
}
|
229
|
-
uint2 sortedData = pHash[index];
|
230
|
-
uint unsorted_indx = sortedData.y;
|
231
|
-
bt3DGrid3F1U min0 = BT_GPU_FETCH(pAABB, unsorted_indx*2);
|
232
|
-
bt3DGrid3F1U max0 = BT_GPU_FETCH(pAABB, unsorted_indx*2 + 1);
|
233
|
-
uint handleIndex = min0.uw;
|
234
|
-
uint2 start_curr = pPairBuffStartCurr[handleIndex];
|
235
|
-
uint start = start_curr.x;
|
236
|
-
uint curr = start_curr.y;
|
237
|
-
uint2 start_curr_next = pPairBuffStartCurr[handleIndex+1];
|
238
|
-
uint curr_max = start_curr_next.x - start - 1;
|
239
|
-
for(uint i = 0; i < numLarge; i++)
|
240
|
-
{
|
241
|
-
uint indx2 = numBodies + i;
|
242
|
-
bt3DGrid3F1U min1 = BT_GPU_FETCH(pAABB, indx2*2);
|
243
|
-
bt3DGrid3F1U max1 = BT_GPU_FETCH(pAABB, indx2*2 + 1);
|
244
|
-
if(cudaTestAABBOverlap(min0, max0, min1, max1))
|
245
|
-
{
|
246
|
-
uint k;
|
247
|
-
uint handleIndex2 = min1.uw;
|
248
|
-
for(k = 0; k < curr; k++)
|
249
|
-
{
|
250
|
-
uint old_pair = pPairBuff[start+k] & (~BT_3DGRID_PAIR_ANY_FLG);
|
251
|
-
if(old_pair == handleIndex2)
|
252
|
-
{
|
253
|
-
pPairBuff[start+k] |= BT_3DGRID_PAIR_FOUND_FLG;
|
254
|
-
break;
|
255
|
-
}
|
256
|
-
}
|
257
|
-
if(k == curr)
|
258
|
-
{
|
259
|
-
pPairBuff[start+curr] = handleIndex2 | BT_3DGRID_PAIR_NEW_FLG;
|
260
|
-
if(curr >= curr_max)
|
261
|
-
{ // not a good solution, but let's avoid crash
|
262
|
-
break;
|
263
|
-
}
|
264
|
-
curr++;
|
265
|
-
}
|
266
|
-
}
|
267
|
-
}
|
268
|
-
pPairBuffStartCurr[handleIndex] = BT_GPU_make_uint2(start, curr);
|
269
|
-
return;
|
270
|
-
} // findPairsLargeD()
|
271
|
-
|
272
|
-
//----------------------------------------------------------------------------------------
|
273
|
-
|
274
|
-
BT_GPU___global__ void computePairCacheChangesD(uint* pPairBuff, uint2* pPairBuffStartCurr,
|
275
|
-
uint* pPairScan, bt3DGrid3F1U* pAABB, uint numBodies)
|
276
|
-
{
|
277
|
-
int index = BT_GPU___mul24(BT_GPU_blockIdx.x, BT_GPU_blockDim.x) + BT_GPU_threadIdx.x;
|
278
|
-
if(index >= (int)numBodies)
|
279
|
-
{
|
280
|
-
return;
|
281
|
-
}
|
282
|
-
bt3DGrid3F1U bbMin = pAABB[index * 2];
|
283
|
-
uint handleIndex = bbMin.uw;
|
284
|
-
uint2 start_curr = pPairBuffStartCurr[handleIndex];
|
285
|
-
uint start = start_curr.x;
|
286
|
-
uint curr = start_curr.y;
|
287
|
-
uint *pInp = pPairBuff + start;
|
288
|
-
uint num_changes = 0;
|
289
|
-
for(uint k = 0; k < curr; k++, pInp++)
|
290
|
-
{
|
291
|
-
if(!((*pInp) & BT_3DGRID_PAIR_FOUND_FLG))
|
292
|
-
{
|
293
|
-
num_changes++;
|
294
|
-
}
|
295
|
-
}
|
296
|
-
pPairScan[index+1] = num_changes;
|
297
|
-
} // computePairCacheChangesD()
|
298
|
-
|
299
|
-
//----------------------------------------------------------------------------------------
|
300
|
-
|
301
|
-
BT_GPU___global__ void squeezeOverlappingPairBuffD(uint* pPairBuff, uint2* pPairBuffStartCurr, uint* pPairScan,
|
302
|
-
uint* pPairOut, bt3DGrid3F1U* pAABB, uint numBodies)
|
303
|
-
{
|
304
|
-
int index = BT_GPU___mul24(BT_GPU_blockIdx.x, BT_GPU_blockDim.x) + BT_GPU_threadIdx.x;
|
305
|
-
if(index >= (int)numBodies)
|
306
|
-
{
|
307
|
-
return;
|
308
|
-
}
|
309
|
-
bt3DGrid3F1U bbMin = pAABB[index * 2];
|
310
|
-
uint handleIndex = bbMin.uw;
|
311
|
-
uint2 start_curr = pPairBuffStartCurr[handleIndex];
|
312
|
-
uint start = start_curr.x;
|
313
|
-
uint curr = start_curr.y;
|
314
|
-
uint* pInp = pPairBuff + start;
|
315
|
-
uint* pOut = pPairOut + pPairScan[index];
|
316
|
-
uint* pOut2 = pInp;
|
317
|
-
uint num = 0;
|
318
|
-
for(uint k = 0; k < curr; k++, pInp++)
|
319
|
-
{
|
320
|
-
if(!((*pInp) & BT_3DGRID_PAIR_FOUND_FLG))
|
321
|
-
{
|
322
|
-
*pOut = *pInp;
|
323
|
-
pOut++;
|
324
|
-
}
|
325
|
-
if((*pInp) & BT_3DGRID_PAIR_ANY_FLG)
|
326
|
-
{
|
327
|
-
*pOut2 = (*pInp) & (~BT_3DGRID_PAIR_ANY_FLG);
|
328
|
-
pOut2++;
|
329
|
-
num++;
|
330
|
-
}
|
331
|
-
}
|
332
|
-
pPairBuffStartCurr[handleIndex] = BT_GPU_make_uint2(start, num);
|
333
|
-
} // squeezeOverlappingPairBuffD()
|
334
|
-
|
335
|
-
|
336
|
-
//----------------------------------------------------------------------------------------
|
337
|
-
//----------------------------------------------------------------------------------------
|
338
|
-
//----------------------------------------------------------------------------------------
|
339
|
-
//----------------------------------------------------------------------------------------
|
340
|
-
// E N D O F K E R N E L F U N C T I O N S
|
341
|
-
//----------------------------------------------------------------------------------------
|
342
|
-
//----------------------------------------------------------------------------------------
|
343
|
-
//----------------------------------------------------------------------------------------
|
344
|
-
//----------------------------------------------------------------------------------------
|
345
|
-
|
346
|
-
extern "C"
|
347
|
-
{
|
348
|
-
|
349
|
-
//----------------------------------------------------------------------------------------
|
350
|
-
|
351
|
-
void BT_GPU_PREF(calcHashAABB)(bt3DGrid3F1U* pAABB, unsigned int* hash, unsigned int numBodies)
|
352
|
-
{
|
353
|
-
int numThreads, numBlocks;
|
354
|
-
BT_GPU_PREF(computeGridSize)(numBodies, 256, numBlocks, numThreads);
|
355
|
-
// execute the kernel
|
356
|
-
BT_GPU_EXECKERNEL(numBlocks, numThreads, calcHashAABBD, (pAABB, (uint2*)hash, numBodies));
|
357
|
-
// check if kernel invocation generated an error
|
358
|
-
BT_GPU_CHECK_ERROR("calcHashAABBD kernel execution failed");
|
359
|
-
} // calcHashAABB()
|
360
|
-
|
361
|
-
//----------------------------------------------------------------------------------------
|
362
|
-
|
363
|
-
void BT_GPU_PREF(findCellStart(unsigned int* hash, unsigned int* cellStart, unsigned int numBodies, unsigned int numCells))
|
364
|
-
{
|
365
|
-
int numThreads, numBlocks;
|
366
|
-
BT_GPU_PREF(computeGridSize)(numBodies, 256, numBlocks, numThreads);
|
367
|
-
BT_GPU_SAFE_CALL(BT_GPU_Memset(cellStart, 0xffffffff, numCells*sizeof(uint)));
|
368
|
-
BT_GPU_EXECKERNEL(numBlocks, numThreads, findCellStartD, ((uint2*)hash, (uint*)cellStart, numBodies));
|
369
|
-
BT_GPU_CHECK_ERROR("Kernel execution failed: findCellStartD");
|
370
|
-
} // findCellStart()
|
371
|
-
|
372
|
-
//----------------------------------------------------------------------------------------
|
373
|
-
|
374
|
-
void BT_GPU_PREF(findOverlappingPairs(bt3DGrid3F1U* pAABB, unsigned int* pHash, unsigned int* pCellStart, unsigned int* pPairBuff, unsigned int* pPairBuffStartCurr, unsigned int numBodies))
|
375
|
-
{
|
376
|
-
#if B_CUDA_USE_TEX
|
377
|
-
BT_GPU_SAFE_CALL(cudaBindTexture(0, pAABBTex, pAABB, numBodies * 2 * sizeof(bt3DGrid3F1U)));
|
378
|
-
#endif
|
379
|
-
int numThreads, numBlocks;
|
380
|
-
BT_GPU_PREF(computeGridSize)(numBodies, 64, numBlocks, numThreads);
|
381
|
-
BT_GPU_EXECKERNEL(numBlocks, numThreads, findOverlappingPairsD, (pAABB,(uint2*)pHash,(uint*)pCellStart,(uint*)pPairBuff,(uint2*)pPairBuffStartCurr,numBodies));
|
382
|
-
BT_GPU_CHECK_ERROR("Kernel execution failed: bt_CudaFindOverlappingPairsD");
|
383
|
-
#if B_CUDA_USE_TEX
|
384
|
-
BT_GPU_SAFE_CALL(cudaUnbindTexture(pAABBTex));
|
385
|
-
#endif
|
386
|
-
} // findOverlappingPairs()
|
387
|
-
|
388
|
-
//----------------------------------------------------------------------------------------
|
389
|
-
|
390
|
-
void BT_GPU_PREF(findPairsLarge(bt3DGrid3F1U* pAABB, unsigned int* pHash, unsigned int* pCellStart, unsigned int* pPairBuff, unsigned int* pPairBuffStartCurr, unsigned int numBodies, unsigned int numLarge))
|
391
|
-
{
|
392
|
-
#if B_CUDA_USE_TEX
|
393
|
-
BT_GPU_SAFE_CALL(cudaBindTexture(0, pAABBTex, pAABB, (numBodies+numLarge) * 2 * sizeof(bt3DGrid3F1U)));
|
394
|
-
#endif
|
395
|
-
int numThreads, numBlocks;
|
396
|
-
BT_GPU_PREF(computeGridSize)(numBodies, 64, numBlocks, numThreads);
|
397
|
-
BT_GPU_EXECKERNEL(numBlocks, numThreads, findPairsLargeD, (pAABB,(uint2*)pHash,(uint*)pCellStart,(uint*)pPairBuff,(uint2*)pPairBuffStartCurr,numBodies,numLarge));
|
398
|
-
BT_GPU_CHECK_ERROR("Kernel execution failed: btCuda_findPairsLargeD");
|
399
|
-
#if B_CUDA_USE_TEX
|
400
|
-
BT_GPU_SAFE_CALL(cudaUnbindTexture(pAABBTex));
|
401
|
-
#endif
|
402
|
-
} // findPairsLarge()
|
403
|
-
|
404
|
-
//----------------------------------------------------------------------------------------
|
405
|
-
|
406
|
-
void BT_GPU_PREF(computePairCacheChanges(unsigned int* pPairBuff, unsigned int* pPairBuffStartCurr, unsigned int* pPairScan, bt3DGrid3F1U* pAABB, unsigned int numBodies))
|
407
|
-
{
|
408
|
-
int numThreads, numBlocks;
|
409
|
-
BT_GPU_PREF(computeGridSize)(numBodies, 256, numBlocks, numThreads);
|
410
|
-
BT_GPU_EXECKERNEL(numBlocks, numThreads, computePairCacheChangesD, ((uint*)pPairBuff,(uint2*)pPairBuffStartCurr,(uint*)pPairScan,pAABB,numBodies));
|
411
|
-
BT_GPU_CHECK_ERROR("Kernel execution failed: btCudaComputePairCacheChangesD");
|
412
|
-
} // computePairCacheChanges()
|
413
|
-
|
414
|
-
//----------------------------------------------------------------------------------------
|
415
|
-
|
416
|
-
void BT_GPU_PREF(squeezeOverlappingPairBuff(unsigned int* pPairBuff, unsigned int* pPairBuffStartCurr, unsigned int* pPairScan, unsigned int* pPairOut, bt3DGrid3F1U* pAABB, unsigned int numBodies))
|
417
|
-
{
|
418
|
-
int numThreads, numBlocks;
|
419
|
-
BT_GPU_PREF(computeGridSize)(numBodies, 256, numBlocks, numThreads);
|
420
|
-
BT_GPU_EXECKERNEL(numBlocks, numThreads, squeezeOverlappingPairBuffD, ((uint*)pPairBuff,(uint2*)pPairBuffStartCurr,(uint*)pPairScan,(uint*)pPairOut,pAABB,numBodies));
|
421
|
-
BT_GPU_CHECK_ERROR("Kernel execution failed: btCudaSqueezeOverlappingPairBuffD");
|
422
|
-
} // btCuda_squeezeOverlappingPairBuff()
|
423
|
-
|
424
|
-
//------------------------------------------------------------------------------------------------
|
425
|
-
|
426
|
-
} // extern "C"
|
427
|
-
|
428
|
-
//------------------------------------------------------------------------------------------------
|
429
|
-
//------------------------------------------------------------------------------------------------
|
430
|
-
//------------------------------------------------------------------------------------------------
|
@@ -1,61 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
Bullet Continuous Collision Detection and Physics Library, http://bulletphysics.org
|
3
|
-
Copyright (C) 2006, 2009 Sony Computer Entertainment Inc.
|
4
|
-
|
5
|
-
This software is provided 'as-is', without any express or implied warranty.
|
6
|
-
In no event will the authors be held liable for any damages arising from the use of this software.
|
7
|
-
Permission is granted to anyone to use this software for any purpose,
|
8
|
-
including commercial applications, and to alter it and redistribute it freely,
|
9
|
-
subject to the following restrictions:
|
10
|
-
|
11
|
-
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.
|
12
|
-
2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
|
13
|
-
3. This notice may not be removed or altered from any source distribution.
|
14
|
-
*/
|
15
|
-
|
16
|
-
//----------------------------------------------------------------------------------------
|
17
|
-
|
18
|
-
// Shared definitions for GPU-based 3D Grid collision detection broadphase
|
19
|
-
|
20
|
-
//!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
21
|
-
// Keep this file free from Bullet headers
|
22
|
-
// it is included into both CUDA and CPU code
|
23
|
-
//!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
24
|
-
|
25
|
-
//----------------------------------------------------------------------------------------
|
26
|
-
|
27
|
-
#ifndef BTGPU3DGRIDBROADPHASESHAREDDEFS_H
|
28
|
-
#define BTGPU3DGRIDBROADPHASESHAREDDEFS_H
|
29
|
-
|
30
|
-
//----------------------------------------------------------------------------------------
|
31
|
-
|
32
|
-
#include "btGpu3DGridBroadphaseSharedTypes.h"
|
33
|
-
|
34
|
-
//----------------------------------------------------------------------------------------
|
35
|
-
|
36
|
-
extern "C"
|
37
|
-
{
|
38
|
-
|
39
|
-
//----------------------------------------------------------------------------------------
|
40
|
-
|
41
|
-
void BT_GPU_PREF(calcHashAABB)(bt3DGrid3F1U* pAABB, unsigned int* hash, unsigned int numBodies);
|
42
|
-
|
43
|
-
void BT_GPU_PREF(findCellStart)(unsigned int* hash, unsigned int* cellStart, unsigned int numBodies, unsigned int numCells);
|
44
|
-
|
45
|
-
void BT_GPU_PREF(findOverlappingPairs)(bt3DGrid3F1U* pAABB, unsigned int* pHash, unsigned int* pCellStart, unsigned int* pPairBuff, unsigned int* pPairBuffStartCurr, unsigned int numBodies);
|
46
|
-
|
47
|
-
void BT_GPU_PREF(findPairsLarge)(bt3DGrid3F1U* pAABB, unsigned int* pHash, unsigned int* pCellStart, unsigned int* pPairBuff, unsigned int* pPairBuffStartCurr, unsigned int numBodies, unsigned int numLarge);
|
48
|
-
|
49
|
-
void BT_GPU_PREF(computePairCacheChanges)(unsigned int* pPairBuff, unsigned int* pPairBuffStartCurr, unsigned int* pPairScan, bt3DGrid3F1U* pAABB, unsigned int numBodies);
|
50
|
-
|
51
|
-
void BT_GPU_PREF(squeezeOverlappingPairBuff)(unsigned int* pPairBuff, unsigned int* pPairBuffStartCurr, unsigned int* pPairScan, unsigned int* pPairOut, bt3DGrid3F1U* pAABB, unsigned int numBodies);
|
52
|
-
|
53
|
-
|
54
|
-
//----------------------------------------------------------------------------------------
|
55
|
-
|
56
|
-
} // extern "C"
|
57
|
-
|
58
|
-
//----------------------------------------------------------------------------------------
|
59
|
-
|
60
|
-
#endif // BTGPU3DGRIDBROADPHASESHAREDDEFS_H
|
61
|
-
|
@@ -1,67 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
Bullet Continuous Collision Detection and Physics Library, http://bulletphysics.org
|
3
|
-
Copyright (C) 2006, 2009 Sony Computer Entertainment Inc.
|
4
|
-
|
5
|
-
This software is provided 'as-is', without any express or implied warranty.
|
6
|
-
In no event will the authors be held liable for any damages arising from the use of this software.
|
7
|
-
Permission is granted to anyone to use this software for any purpose,
|
8
|
-
including commercial applications, and to alter it and redistribute it freely,
|
9
|
-
subject to the following restrictions:
|
10
|
-
|
11
|
-
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.
|
12
|
-
2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software.
|
13
|
-
3. This notice may not be removed or altered from any source distribution.
|
14
|
-
*/
|
15
|
-
|
16
|
-
//----------------------------------------------------------------------------------------
|
17
|
-
|
18
|
-
// Shared definitions for GPU-based 3D Grid collision detection broadphase
|
19
|
-
|
20
|
-
//!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
21
|
-
// Keep this file free from Bullet headers
|
22
|
-
// it is included into both CUDA and CPU code
|
23
|
-
//!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
24
|
-
|
25
|
-
//----------------------------------------------------------------------------------------
|
26
|
-
|
27
|
-
#ifndef BTGPU3DGRIDBROADPHASESHAREDTYPES_H
|
28
|
-
#define BTGPU3DGRIDBROADPHASESHAREDTYPES_H
|
29
|
-
|
30
|
-
//----------------------------------------------------------------------------------------
|
31
|
-
|
32
|
-
#define BT_3DGRID_PAIR_FOUND_FLG (0x40000000)
|
33
|
-
#define BT_3DGRID_PAIR_NEW_FLG (0x20000000)
|
34
|
-
#define BT_3DGRID_PAIR_ANY_FLG (BT_3DGRID_PAIR_FOUND_FLG | BT_3DGRID_PAIR_NEW_FLG)
|
35
|
-
|
36
|
-
//----------------------------------------------------------------------------------------
|
37
|
-
|
38
|
-
struct bt3DGridBroadphaseParams
|
39
|
-
{
|
40
|
-
unsigned int m_gridSizeX;
|
41
|
-
unsigned int m_gridSizeY;
|
42
|
-
unsigned int m_gridSizeZ;
|
43
|
-
unsigned int m_numCells;
|
44
|
-
float m_worldOriginX;
|
45
|
-
float m_worldOriginY;
|
46
|
-
float m_worldOriginZ;
|
47
|
-
float m_cellSizeX;
|
48
|
-
float m_cellSizeY;
|
49
|
-
float m_cellSizeZ;
|
50
|
-
unsigned int m_numBodies;
|
51
|
-
unsigned int m_maxBodiesPerCell;
|
52
|
-
};
|
53
|
-
|
54
|
-
//----------------------------------------------------------------------------------------
|
55
|
-
|
56
|
-
struct bt3DGrid3F1U
|
57
|
-
{
|
58
|
-
float fx;
|
59
|
-
float fy;
|
60
|
-
float fz;
|
61
|
-
unsigned int uw;
|
62
|
-
};
|
63
|
-
|
64
|
-
//----------------------------------------------------------------------------------------
|
65
|
-
|
66
|
-
#endif // BTGPU3DGRIDBROADPHASESHAREDTYPES_H
|
67
|
-
|