@NoOffset @Properties(inherit=liquidfun.class) public class b2ChainShape extends b2Shape
Pointer.CustomDeallocator, Pointer.Deallocator, Pointer.NativeDeallocator, Pointer.ReferenceCounter| Constructor and Description |
|---|
b2ChainShape() |
b2ChainShape(long size)
Native array allocator.
|
b2ChainShape(Pointer p)
Pointer cast constructor.
|
| Modifier and Type | Method and Description |
|---|---|
b2Shape |
Clone(b2BlockAllocator allocator)
Implement b2Shape.
|
void |
ComputeAABB(b2AABB aabb,
b2Transform transform,
int childIndex)
Given a transform, compute the associated axis aligned bounding box for a child shape.
|
void |
ComputeDistance(b2Transform xf,
b2Vec2 p,
float[] distance,
b2Vec2 normal,
int childIndex) |
void |
ComputeDistance(b2Transform xf,
b2Vec2 p,
FloatBuffer distance,
b2Vec2 normal,
int childIndex) |
void |
ComputeDistance(b2Transform xf,
b2Vec2 p,
FloatPointer distance,
b2Vec2 normal,
int childIndex)
Compute the distance from the current shape to the specified point.
|
void |
ComputeMass(b2MassData massData,
float density)
Chains have zero mass.
|
void |
CreateChain(b2Vec2 vertices,
int count)
Create a chain with isolated end vertices.
|
void |
CreateLoop(b2Vec2 vertices,
int count)
Create a loop.
|
int |
GetChildCount()
Get the number of child primitives.
|
void |
GetChildEdge(b2EdgeShape edge,
int index)
Get a child edge.
|
int |
m_count()
The vertex count.
|
b2ChainShape |
m_count(int setter) |
boolean |
m_hasNextVertex() |
b2ChainShape |
m_hasNextVertex(boolean setter) |
boolean |
m_hasPrevVertex() |
b2ChainShape |
m_hasPrevVertex(boolean setter) |
b2Vec2 |
m_nextVertex() |
b2ChainShape |
m_nextVertex(b2Vec2 setter) |
b2Vec2 |
m_prevVertex() |
b2ChainShape |
m_prevVertex(b2Vec2 setter) |
b2Vec2 |
m_vertices()
The vertices.
|
b2ChainShape |
m_vertices(b2Vec2 setter) |
b2ChainShape |
position(long position) |
boolean |
RayCast(b2RayCastOutput output,
b2RayCastInput input,
b2Transform transform,
int childIndex)
Implement b2Shape.
|
void |
SetNextVertex(b2Vec2 nextVertex)
Establish connectivity to a vertex that follows the last vertex.
|
void |
SetPrevVertex(b2Vec2 prevVertex)
Establish connectivity to a vertex that precedes the first vertex.
|
boolean |
TestPoint(b2Transform transform,
b2Vec2 p)
This always return false.
|
GetType, m_radius, m_radius, m_type, m_typeaddress, asBuffer, asByteBuffer, availablePhysicalBytes, calloc, capacity, capacity, close, deallocate, deallocate, deallocateReferences, deallocator, deallocator, equals, fill, formatBytes, free, hashCode, isNull, limit, limit, malloc, maxBytes, maxPhysicalBytes, memchr, memcmp, memcpy, memmove, memset, offsetof, parseBytes, physicalBytes, position, put, realloc, referenceCount, releaseReference, retainReference, setNull, sizeof, toString, totalBytes, totalPhysicalBytes, withDeallocator, zeropublic b2ChainShape(Pointer p)
Pointer.Pointer(Pointer).public b2ChainShape(long size)
Pointer.position(long).public b2ChainShape()
public b2ChainShape position(long position)
public void CreateLoop(@Const b2Vec2 vertices, @Cast(value="int32") int count)
vertices - an array of vertices, these are copiedcount - the vertex countpublic void CreateChain(@Const b2Vec2 vertices, @Cast(value="int32") int count)
vertices - an array of vertices, these are copiedcount - the vertex countpublic void SetPrevVertex(@Const @ByRef b2Vec2 prevVertex)
public void SetNextVertex(@Const @ByRef b2Vec2 nextVertex)
public b2Shape Clone(b2BlockAllocator allocator)
@Cast(value="int32") public int GetChildCount()
b2ShapeGetChildCount in class b2Shapeb2Shape::GetChildCountpublic void GetChildEdge(b2EdgeShape edge, @Cast(value="int32") int index)
@Cast(value="bool") public boolean TestPoint(@Const @ByRef b2Transform transform, @Const @ByRef b2Vec2 p)
public void ComputeDistance(@Const @ByRef b2Transform xf, @Const @ByRef b2Vec2 p, @Cast(value="float32*") FloatPointer distance, b2Vec2 normal, @Cast(value="int32") int childIndex)
b2ShapeComputeDistance in class b2Shapexf - the shape world transform.p - a point in world coordinates.distance - returns the distance from the current shape.normal - returns the direction in which the distance increases.public void ComputeDistance(@Const @ByRef b2Transform xf, @Const @ByRef b2Vec2 p, @Cast(value="float32*") FloatBuffer distance, b2Vec2 normal, @Cast(value="int32") int childIndex)
ComputeDistance in class b2Shapepublic void ComputeDistance(@Const @ByRef b2Transform xf, @Const @ByRef b2Vec2 p, @Cast(value="float32*") float[] distance, b2Vec2 normal, @Cast(value="int32") int childIndex)
ComputeDistance in class b2Shape@Cast(value="bool") public boolean RayCast(b2RayCastOutput output, @Const @ByRef b2RayCastInput input, @Const @ByRef b2Transform transform, @Cast(value="int32") int childIndex)
public void ComputeAABB(b2AABB aabb, @Const @ByRef b2Transform transform, @Cast(value="int32") int childIndex)
b2ShapeComputeAABB in class b2Shapeaabb - returns the axis aligned box.transform - the world transform of the shape.childIndex - the child shapeb2Shape::ComputeAABBpublic void ComputeMass(b2MassData massData, @Cast(value="float32") float density)
ComputeMass in class b2ShapemassData - returns the mass data for this shape.density - the density in kilograms per meter squared.b2Shape::ComputeMasspublic b2Vec2 m_vertices()
public b2ChainShape m_vertices(b2Vec2 setter)
public b2ChainShape m_count(int setter)
public b2ChainShape m_prevVertex(b2Vec2 setter)
public b2ChainShape m_nextVertex(b2Vec2 setter)
public b2ChainShape m_hasPrevVertex(boolean setter)
public b2ChainShape m_hasNextVertex(boolean setter)
Copyright © 2019. All rights reserved.