com.badlogic.gdx.physics.bullet.collision.btPrimitiveTriangle Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gdx-bullet Show documentation
Show all versions of gdx-bullet Show documentation
Android/Desktop/iOS/HTML5 game development framework
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 3.0.11
*
* 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 btPrimitiveTriangle extends BulletBase {
private long swigCPtr;
protected btPrimitiveTriangle(final String className, long cPtr, boolean cMemoryOwn) {
super(className, cPtr, cMemoryOwn);
swigCPtr = cPtr;
}
/** Construct a new btPrimitiveTriangle, normally you should not need this constructor it's intended for low-level usage. */
public btPrimitiveTriangle(long cPtr, boolean cMemoryOwn) {
this("btPrimitiveTriangle", cPtr, cMemoryOwn);
construct();
}
@Override
protected void reset(long cPtr, boolean cMemoryOwn) {
if (!destroyed)
destroy();
super.reset(swigCPtr = cPtr, cMemoryOwn);
}
public static long getCPtr(btPrimitiveTriangle 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_btPrimitiveTriangle(swigCPtr);
}
swigCPtr = 0;
}
super.delete();
}
public void setVertices(btVector3 value) {
CollisionJNI.btPrimitiveTriangle_vertices_set(swigCPtr, this, btVector3.getCPtr(value), value);
}
public btVector3 getVertices() {
long cPtr = CollisionJNI.btPrimitiveTriangle_vertices_get(swigCPtr, this);
return (cPtr == 0) ? null : new btVector3(cPtr, false);
}
public void setPlane(btVector4 value) {
CollisionJNI.btPrimitiveTriangle_plane_set(swigCPtr, this, btVector4.getCPtr(value), value);
}
public btVector4 getPlane() {
long cPtr = CollisionJNI.btPrimitiveTriangle_plane_get(swigCPtr, this);
return (cPtr == 0) ? null : new btVector4(cPtr, false);
}
public void setMargin(float value) {
CollisionJNI.btPrimitiveTriangle_margin_set(swigCPtr, this, value);
}
public float getMargin() {
return CollisionJNI.btPrimitiveTriangle_margin_get(swigCPtr, this);
}
public void setDummy(float value) {
CollisionJNI.btPrimitiveTriangle_dummy_set(swigCPtr, this, value);
}
public float getDummy() {
return CollisionJNI.btPrimitiveTriangle_dummy_get(swigCPtr, this);
}
public btPrimitiveTriangle() {
this(CollisionJNI.new_btPrimitiveTriangle(), true);
}
public void buildTriPlane() {
CollisionJNI.btPrimitiveTriangle_buildTriPlane(swigCPtr, this);
}
public boolean overlap_test_conservative(btPrimitiveTriangle other) {
return CollisionJNI.btPrimitiveTriangle_overlap_test_conservative(swigCPtr, this, btPrimitiveTriangle.getCPtr(other), other);
}
public void get_edge_plane(int edge_index, btVector4 plane) {
CollisionJNI.btPrimitiveTriangle_get_edge_plane(swigCPtr, this, edge_index, btVector4.getCPtr(plane), plane);
}
public void applyTransform(Matrix4 t) {
CollisionJNI.btPrimitiveTriangle_applyTransform(swigCPtr, this, t);
}
public int clip_triangle(btPrimitiveTriangle other, btVector3 clipped_points) {
return CollisionJNI.btPrimitiveTriangle_clip_triangle(swigCPtr, this, btPrimitiveTriangle.getCPtr(other), other, btVector3.getCPtr(clipped_points), clipped_points);
}
public boolean find_triangle_collision_clip_method(btPrimitiveTriangle other, GIM_TRIANGLE_CONTACT contacts) {
return CollisionJNI.btPrimitiveTriangle_find_triangle_collision_clip_method(swigCPtr, this, btPrimitiveTriangle.getCPtr(other), other, GIM_TRIANGLE_CONTACT.getCPtr(contacts), contacts);
}
}