2 * Main SWIG 2.0 input file for Bullet.
\r
5 %module(directors="1") gdxBullet
\r
7 #define gdxToString(X) "X"
\r
9 /* remove m_ prefix for the getters/setters of properties,
\r
10 * %rename has some conflict with %template so we much be careful when selecting what to rename */
\r
11 %rename("%(strip:[m_])s", %$ismember, %$ispublic, %$not %$isclass, %$not %$istemplate, %$not %$isfunction, regexmatch$name="m_.*$") "";
\r
12 /* some classes have both public properties and getter/setter methods, ignore the latter. */
\r
13 %ignore btHashString::getHash;
\r
14 %ignore btManifoldPoint::getLifeTime;
\r
15 %ignore btManifoldPoint::getPositionWorldOnA;
\r
16 %ignore btManifoldPoint::getPositionWorldOnB;
\r
17 %ignore btManifoldPoint::getAppliedImpulse;
\r
18 %ignore btSolverBody::getWorldTransform;
\r
19 %ignore btSolverBody::setWorldTransform;
\r
20 %ignore btSolverBody::getDeltaLinearVelocity;
\r
21 %ignore btSolverBody::getDeltaAngularVelocity;
\r
22 %ignore btSolverBody::getPushVelocity;
\r
23 %ignore btSolverBody::getTurnVelocity;
\r
24 %ignore btTypedObject::getObjectType;
\r
25 %ignore btVoronoiSimplexSolver::setEqualVertexThreshold;
\r
26 %ignore btVoronoiSimplexSolver::getEqualVertexThreshold;
\r
28 %include "common/gdxDefault.i"
\r
30 /* Configures types that need down cast support */
\r
31 %include "common/gdxDownCast.i"
\r
34 * Use java.nio.Buffer where Bullet wants btScalar * and alike. This gets disabled
\r
35 * for some types (and re-enabled right after).
\r
37 %include "common/gdxBuffers.i"
\r
38 %include "common/gdxEnableBuffers.i"
\r
40 %include "common/gdxCriticalArrays.i"
\r
42 %include "common/gdxPool.i"
\r
43 %include "common/gdxPooledTypemap.i"
\r
45 %include "common/gdxPooledObject.i"
\r
48 /* Map "void *" to "jlong". */
\r
49 // %include "gdxVoidPointer.i";
\r
51 /* Use "unsafe" enums (plain integer constants) instead of typesafe enum classes. */
\r
52 %include "enumtypeunsafe.swg"
\r
55 /* Include Java imports for all the types we'll need in all extensions/custom types. */
\r
56 %include "common/gdxJavaImports.i"
\r
63 * btScalar.h defines macros the other types need, so process it first.
\r
64 * It also defines some static functions that end up in gdxBulletJNI.java.
\r
66 %include "LinearMath/btScalar.h"
\r
69 * Extend some classes with custom Java.
\r
71 %include "common/btTransform.i"
\r
74 #include <LinearMath/btVector3.h>
\r
76 %include <LinearMath/btVector3.h>
\r
79 #include <LinearMath/btQuaternion.h>
\r
81 %include <LinearMath/btQuaternion.h>
\r
85 //%include "common/gdxManagedObject.i"
\r
87 /* Prefer libgdx's linear math types (Vector3, Matrix3, etc.). */
\r
88 %include "common/gdxMathTypes.i"
\r
90 /* Configure directors for types with virtual methods that need Java implementations */
\r
91 %feature("director") btIDebugDraw;
\r
94 * The rest of the types (some are disabled, commented out at the bottom).
\r
96 * The order below is important. If an "%include"ed type depends on another
\r
97 * type, that other type's "#include" line needs to come before it. Avoid
\r
98 * splitting the #include/%include pairs for a type, so move the whole type
\r
103 #include <LinearMath/btQuadWord.h>
\r
105 #include <LinearMath/btQuadWord.h>
\r
108 #include <LinearMath/btMatrix3x3.h>
\r
110 #include <LinearMath/btMatrix3x3.h>
\r
113 #include <LinearMath/btAabbUtil2.h>
\r
115 %include "LinearMath/btAabbUtil2.h"
\r
117 DISABLE_POOLED_TYPEMAP(btTransform);
\r
118 DISABLE_POOLED_TYPEMAP(btVector3);
\r
120 #include <LinearMath/btIDebugDraw.h>
\r
122 %include "LinearMath/btIDebugDraw.h"
\r
123 ENABLE_POOLED_TYPEMAP(btVector3, Vector3, "Lcom/badlogic/gdx/math/Vector3;");
\r
124 ENABLE_POOLED_TYPEMAP(btTransform, Matrix4, "Lcom/badlogic/gdx/math/Matrix4;");
\r
127 #include <LinearMath/btGeometryUtil.h>
\r
129 %include "LinearMath/btGeometryUtil.h"
\r
132 #include <LinearMath/btRandom.h>
\r
134 %include "LinearMath/btRandom.h"
\r
137 #include <LinearMath/btTransformUtil.h>
\r
139 %include "LinearMath/btTransformUtil.h"
\r
142 #include <LinearMath/btConvexHull.h>
\r
144 %include "LinearMath/btConvexHull.h"
\r
147 #include <LinearMath/btGrahamScan2dConvexHull.h>
\r
149 %include "LinearMath/btGrahamScan2dConvexHull.h"
\r
152 #include <LinearMath/btPoolAllocator.h>
\r
154 %include "LinearMath/btPoolAllocator.h"
\r
157 #include <LinearMath/btQuickprof.h>
\r
159 %include "LinearMath/btQuickprof.h"
\r
162 #include <LinearMath/btConvexHullComputer.h>
\r
164 %include "LinearMath/btConvexHullComputer.h"
\r
167 #include <LinearMath/btAlignedObjectArray.h>
\r
169 %include "LinearMath/btAlignedObjectArray.h"
\r
172 #include <LinearMath/btList.h>
\r
174 %include "LinearMath/btList.h"
\r
177 #include <LinearMath/btAlignedAllocator.h>
\r
179 %include "LinearMath/btAlignedAllocator.h"
\r
182 #include <LinearMath/btHashMap.h>
\r
184 %include "LinearMath/btHashMap.h"
\r
187 #include <LinearMath/btStackAlloc.h>
\r
189 %include "LinearMath/btStackAlloc.h"
\r
192 #include <LinearMath/btMinMax.h>
\r
194 %include "LinearMath/btMinMax.h"
\r
196 %include "collision/gdxBulletCollision.i"
\r
198 %include "dynamics/gdxBulletDynamics.i"
\r
200 %include "softbody/gdxBulletSoftbody.i"
\r
202 %include "gdxMissingBulletMethods.i"
\r
204 %include "extras/serialize/gdxBulletSerialize.i"
\r