/* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). * Version 3.0.10 * * Do not make changes to this file unless you know what you are doing--modify * the SWIG interface file instead. * ----------------------------------------------------------------------------- */ package com.badlogic.gdx.physics.bullet.collision; import com.badlogic.gdx.physics.bullet.BulletBase; import com.badlogic.gdx.physics.bullet.linearmath.*; import com.badlogic.gdx.math.Vector3; import com.badlogic.gdx.math.Quaternion; import com.badlogic.gdx.math.Matrix3; import com.badlogic.gdx.math.Matrix4; public class ContactCache extends BulletBase { private long swigCPtr; protected ContactCache(final String className, long cPtr, boolean cMemoryOwn) { super(className, cPtr, cMemoryOwn); swigCPtr = cPtr; } /** Construct a new ContactCache, normally you should not need this constructor it's intended for low-level usage. */ public ContactCache(long cPtr, boolean cMemoryOwn) { this("ContactCache", cPtr, cMemoryOwn); construct(); } @Override protected void reset(long cPtr, boolean cMemoryOwn) { if (!destroyed) destroy(); super.reset(swigCPtr = cPtr, cMemoryOwn); } public static long getCPtr(ContactCache obj) { return (obj == null) ? 0 : obj.swigCPtr; } @Override protected void finalize() throws Throwable { if (!destroyed) destroy(); super.finalize(); } @Override protected synchronized void delete() { if (swigCPtr != 0) { if (swigCMemOwn) { swigCMemOwn = false; CollisionJNI.delete_ContactCache(swigCPtr); } swigCPtr = 0; } super.delete(); } protected void swigDirectorDisconnect() { swigCMemOwn = false; delete(); } public void swigReleaseOwnership() { swigCMemOwn = false; CollisionJNI.ContactCache_change_ownership(this, swigCPtr, false); } public void swigTakeOwnership() { swigCMemOwn = true; CollisionJNI.ContactCache_change_ownership(this, swigCPtr, true); } public ContactCache() { this(false); enable(); } public void setCacheTime(float value) { CollisionJNI.ContactCache_cacheTime_set(swigCPtr, this, value); } public float getCacheTime() { return CollisionJNI.ContactCache_cacheTime_get(swigCPtr, this); } private ContactCache(boolean dummy) { this(CollisionJNI.new_ContactCache(dummy), true); CollisionJNI.ContactCache_director_connect(this, swigCPtr, swigCMemOwn, true); } public void enable() { CollisionJNI.ContactCache_enable(swigCPtr, this); } public void disable() { CollisionJNI.ContactCache_disable(swigCPtr, this); } public boolean isEnabled() { return CollisionJNI.ContactCache_isEnabled(swigCPtr, this); } public void onContactStarted(btPersistentManifold manifold, boolean match0, boolean match1) { CollisionJNI.ContactCache_onContactStarted(swigCPtr, this, btPersistentManifold.getCPtr(manifold), manifold, match0, match1); } public void onContactEnded(btCollisionObject colObj0, boolean match0, btCollisionObject colObj1, boolean match1) { CollisionJNI.ContactCache_onContactEnded(swigCPtr, this, btCollisionObject.getCPtr(colObj0), colObj0, match0, btCollisionObject.getCPtr(colObj1), colObj1, match1); } public void clear() { CollisionJNI.ContactCache_clear(swigCPtr, this); } public void update(float delta) { CollisionJNI.ContactCache_update(swigCPtr, this, delta); } }