Java源码示例:com.bulletphysics.util.ObjectArrayList

示例1
private CollisionShape defaultCollisionShape(final IShape geom) {
	final ObjectArrayList<Vector3f> points = new ObjectArrayList<>();
	for (final ILocation loc : geom.getPoints()) {
		points.add(new Vector3f((float) loc.toGamaPoint().x, (float) loc.toGamaPoint().y,
				(float) loc.toGamaPoint().z));
	}
	return new ConvexHullShape(points);
}
 
示例2
protected void createShape(float[] points) {
    ObjectArrayList<Vector3f> pointList = new ObjectArrayList<Vector3f>();
    for (int i = 0; i < points.length; i += 3) {
        pointList.add(new Vector3f(points[i], points[i + 1], points[i + 2]));
    }
    cShape = new ConvexHullShape(pointList);
    cShape.setLocalScaling(Converter.convert(getScale()));
    cShape.setMargin(margin);
}
 
示例3
protected void createShape(float[] points) {
    ObjectArrayList<Vector3f> pointList = new ObjectArrayList<Vector3f>();
    for (int i = 0; i < points.length; i += 3) {
        pointList.add(new Vector3f(points[i], points[i + 1], points[i + 2]));
    }
    cShape = new ConvexHullShape(pointList);
    cShape.setLocalScaling(Converter.convert(getScale()));
    cShape.setMargin(margin);
}
 
示例4
public MyBConvexHull(PApplet p, float mass,  ObjectArrayList<Vector3f> vertices, Vector3f position,  boolean inertia) {
  super(p, mass, vertices, position, inertia);
}
 
示例5
public MyBConvexHull(PApplet p, float mass,  ObjectArrayList<Vector3f> vertices, Vector3f position,  boolean inertia) {
  super(p, mass, vertices, position, inertia);
}