org.bytedeco.bullet.BulletCollision.btOptimizedBvh Maven / Gradle / Ivy
// Targeted by JavaCPP version 1.5.8: DO NOT EDIT THIS FILE
package org.bytedeco.bullet.BulletCollision;
import java.nio.*;
import org.bytedeco.javacpp.*;
import org.bytedeco.javacpp.annotation.*;
import static org.bytedeco.javacpp.presets.javacpp.*;
import org.bytedeco.bullet.LinearMath.*;
import static org.bytedeco.bullet.global.LinearMath.*;
import static org.bytedeco.bullet.global.BulletCollision.*;
/**The btOptimizedBvh extends the btQuantizedBvh to create AABB tree for triangle meshes, through the btStridingMeshInterface. */
@Properties(inherit = org.bytedeco.bullet.presets.BulletCollision.class)
public class btOptimizedBvh extends btQuantizedBvh {
static { Loader.load(); }
/** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */
public btOptimizedBvh(Pointer p) { super(p); }
/** Native array allocator. Access with {@link Pointer#position(long)}. */
public btOptimizedBvh(long size) { super((Pointer)null); allocateArray(size); }
private native void allocateArray(long size);
@Override public btOptimizedBvh position(long position) {
return (btOptimizedBvh)super.position(position);
}
@Override public btOptimizedBvh getPointer(long i) {
return new btOptimizedBvh((Pointer)this).offsetAddress(i);
}
public btOptimizedBvh() { super((Pointer)null); allocate(); }
private native void allocate();
public native void build(btStridingMeshInterface triangles, @Cast("bool") boolean useQuantizedAabbCompression, @Const @ByRef btVector3 bvhAabbMin, @Const @ByRef btVector3 bvhAabbMax);
public native void refit(btStridingMeshInterface triangles, @Const @ByRef btVector3 aabbMin, @Const @ByRef btVector3 aabbMax);
public native void refitPartial(btStridingMeshInterface triangles, @Const @ByRef btVector3 aabbMin, @Const @ByRef btVector3 aabbMax);
public native void updateBvhNodes(btStridingMeshInterface meshInterface, int firstNode, int endNode, int index);
/** Data buffer MUST be 16 byte aligned */
public native @Cast("bool") boolean serializeInPlace(Pointer o_alignedDataBuffer, @Cast("unsigned") int i_dataBufferSize, @Cast("bool") boolean i_swapEndian);
/**deSerializeInPlace loads and initializes a BVH from a buffer in memory 'in place' */
public static native btOptimizedBvh deSerializeInPlace(Pointer i_alignedDataBuffer, @Cast("unsigned int") int i_dataBufferSize, @Cast("bool") boolean i_swapEndian);
}