• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* ----------------------------------------------------------------------------
2  * This file was automatically generated by SWIG (http://www.swig.org).
3  * Version 3.0.8
4  *
5  * Do not make changes to this file unless you know what you are doing--modify
6  * the SWIG interface file instead.
7  * ----------------------------------------------------------------------------- */
8 
9 package com.badlogic.gdx.physics.bullet.collision;
10 
11 import com.badlogic.gdx.physics.bullet.BulletBase;
12 import com.badlogic.gdx.physics.bullet.linearmath.*;
13 import com.badlogic.gdx.math.Vector3;
14 import com.badlogic.gdx.math.Quaternion;
15 import com.badlogic.gdx.math.Matrix3;
16 import com.badlogic.gdx.math.Matrix4;
17 
18 public class btGImpactCompoundShape extends btGImpactShapeInterface {
19 	private long swigCPtr;
20 
btGImpactCompoundShape(final String className, long cPtr, boolean cMemoryOwn)21 	protected btGImpactCompoundShape(final String className, long cPtr, boolean cMemoryOwn) {
22 		super(className, CollisionJNI.btGImpactCompoundShape_SWIGUpcast(cPtr), cMemoryOwn);
23 		swigCPtr = cPtr;
24 	}
25 
26 	/** Construct a new btGImpactCompoundShape, normally you should not need this constructor it's intended for low-level usage. */
btGImpactCompoundShape(long cPtr, boolean cMemoryOwn)27 	public btGImpactCompoundShape(long cPtr, boolean cMemoryOwn) {
28 		this("btGImpactCompoundShape", cPtr, cMemoryOwn);
29 		construct();
30 	}
31 
32 	@Override
reset(long cPtr, boolean cMemoryOwn)33 	protected void reset(long cPtr, boolean cMemoryOwn) {
34 		if (!destroyed)
35 			destroy();
36 		super.reset(CollisionJNI.btGImpactCompoundShape_SWIGUpcast(swigCPtr = cPtr), cMemoryOwn);
37 	}
38 
getCPtr(btGImpactCompoundShape obj)39 	public static long getCPtr(btGImpactCompoundShape obj) {
40 		return (obj == null) ? 0 : obj.swigCPtr;
41 	}
42 
43 	@Override
finalize()44 	protected void finalize() throws Throwable {
45 		if (!destroyed)
46 			destroy();
47 		super.finalize();
48 	}
49 
delete()50   @Override protected synchronized void delete() {
51 		if (swigCPtr != 0) {
52 			if (swigCMemOwn) {
53 				swigCMemOwn = false;
54 				CollisionJNI.delete_btGImpactCompoundShape(swigCPtr);
55 			}
56 			swigCPtr = 0;
57 		}
58 		super.delete();
59 	}
60 
61   static public class CompoundPrimitiveManager extends btPrimitiveManagerBase {
62   	private long swigCPtr;
63 
CompoundPrimitiveManager(final String className, long cPtr, boolean cMemoryOwn)64   	protected CompoundPrimitiveManager(final String className, long cPtr, boolean cMemoryOwn) {
65   		super(className, CollisionJNI.btGImpactCompoundShape_CompoundPrimitiveManager_SWIGUpcast(cPtr), cMemoryOwn);
66   		swigCPtr = cPtr;
67   	}
68 
69   	/** Construct a new CompoundPrimitiveManager, normally you should not need this constructor it's intended for low-level usage. */
CompoundPrimitiveManager(long cPtr, boolean cMemoryOwn)70   	public CompoundPrimitiveManager(long cPtr, boolean cMemoryOwn) {
71   		this("CompoundPrimitiveManager", cPtr, cMemoryOwn);
72   		construct();
73   	}
74 
75   	@Override
reset(long cPtr, boolean cMemoryOwn)76   	protected void reset(long cPtr, boolean cMemoryOwn) {
77   		if (!destroyed)
78   			destroy();
79   		super.reset(CollisionJNI.btGImpactCompoundShape_CompoundPrimitiveManager_SWIGUpcast(swigCPtr = cPtr), cMemoryOwn);
80   	}
81 
getCPtr(CompoundPrimitiveManager obj)82   	public static long getCPtr(CompoundPrimitiveManager obj) {
83   		return (obj == null) ? 0 : obj.swigCPtr;
84   	}
85 
86   	@Override
finalize()87   	protected void finalize() throws Throwable {
88   		if (!destroyed)
89   			destroy();
90   		super.finalize();
91   	}
92 
delete()93     @Override protected synchronized void delete() {
94   		if (swigCPtr != 0) {
95   			if (swigCMemOwn) {
96   				swigCMemOwn = false;
97   				CollisionJNI.delete_btGImpactCompoundShape_CompoundPrimitiveManager(swigCPtr);
98   			}
99   			swigCPtr = 0;
100   		}
101   		super.delete();
102   	}
103 
setCompoundShape(btGImpactCompoundShape value)104     public void setCompoundShape(btGImpactCompoundShape value) {
105       CollisionJNI.btGImpactCompoundShape_CompoundPrimitiveManager_compoundShape_set(swigCPtr, this, btGImpactCompoundShape.getCPtr(value), value);
106     }
107 
getCompoundShape()108     public btGImpactCompoundShape getCompoundShape() {
109       long cPtr = CollisionJNI.btGImpactCompoundShape_CompoundPrimitiveManager_compoundShape_get(swigCPtr, this);
110       return (cPtr == 0) ? null : new btGImpactCompoundShape(cPtr, false);
111     }
112 
CompoundPrimitiveManager(btGImpactCompoundShape.CompoundPrimitiveManager compound)113     public CompoundPrimitiveManager(btGImpactCompoundShape.CompoundPrimitiveManager compound) {
114       this(CollisionJNI.new_btGImpactCompoundShape_CompoundPrimitiveManager__SWIG_0(btGImpactCompoundShape.CompoundPrimitiveManager.getCPtr(compound), compound), true);
115     }
116 
CompoundPrimitiveManager(btGImpactCompoundShape compoundShape)117     public CompoundPrimitiveManager(btGImpactCompoundShape compoundShape) {
118       this(CollisionJNI.new_btGImpactCompoundShape_CompoundPrimitiveManager__SWIG_1(btGImpactCompoundShape.getCPtr(compoundShape), compoundShape), true);
119     }
120 
CompoundPrimitiveManager()121     public CompoundPrimitiveManager() {
122       this(CollisionJNI.new_btGImpactCompoundShape_CompoundPrimitiveManager__SWIG_2(), true);
123     }
124 
125   }
126 
btGImpactCompoundShape(boolean children_has_transform)127   public btGImpactCompoundShape(boolean children_has_transform) {
128     this(CollisionJNI.new_btGImpactCompoundShape__SWIG_0(children_has_transform), true);
129   }
130 
btGImpactCompoundShape()131   public btGImpactCompoundShape() {
132     this(CollisionJNI.new_btGImpactCompoundShape__SWIG_1(), true);
133   }
134 
getCompoundPrimitiveManager()135   public btGImpactCompoundShape.CompoundPrimitiveManager getCompoundPrimitiveManager() {
136     long cPtr = CollisionJNI.btGImpactCompoundShape_getCompoundPrimitiveManager(swigCPtr, this);
137     return (cPtr == 0) ? null : new btGImpactCompoundShape.CompoundPrimitiveManager(cPtr, false);
138   }
139 
addChildShape(Matrix4 localTransform, btCollisionShape shape)140   public void addChildShape(Matrix4 localTransform, btCollisionShape shape) {
141     CollisionJNI.btGImpactCompoundShape_addChildShape__SWIG_0(swigCPtr, this, localTransform, btCollisionShape.getCPtr(shape), shape);
142   }
143 
addChildShape(btCollisionShape shape)144   public void addChildShape(btCollisionShape shape) {
145     CollisionJNI.btGImpactCompoundShape_addChildShape__SWIG_1(swigCPtr, this, btCollisionShape.getCPtr(shape), shape);
146   }
147 
getChildShape(int index)148   public btCollisionShape getChildShape(int index) {
149     long cPtr = CollisionJNI.btGImpactCompoundShape_getChildShape__SWIG_0(swigCPtr, this, index);
150     return (cPtr == 0) ? null : btCollisionShape.newDerivedObject(cPtr, false);
151   }
152 
153 }
154