@NoOffset @Properties(inherit=LinearMath.class) public class btVector3 extends Pointer
Pointer.CustomDeallocator, Pointer.Deallocator, Pointer.NativeDeallocator, Pointer.ReferenceCounter
Constructor and Description |
---|
btVector3()
\brief No initialization constructor
|
btVector3(double _x,
double _y,
double _z)
\brief Constructor from scalars
|
btVector3(long size)
Native array allocator.
|
btVector3(Pointer p)
Pointer cast constructor.
|
Modifier and Type | Method and Description |
---|---|
btVector3 |
absolute()
\brief Return a vector with the absolute values of each element
|
btVector3 |
addPut(btVector3 v)
\brief Add a vector to this one
|
double |
angle(btVector3 v)
\brief Return the angle between this and another vector
|
DoublePointer |
asDoublePointer()
operator btScalar*() replaces operator[], using implicit conversion.
|
int |
closestAxis() |
btVector3 |
cross(btVector3 v)
\brief Return the cross product between this and another vector
|
void |
deSerialize(btVector3DoubleData dataIn) |
void |
deSerialize(btVector3FloatData dataIn) |
void |
deSerializeDouble(btVector3DoubleData dataIn) |
void |
deSerializeFloat(btVector3FloatData dataIn) |
double |
distance(btVector3 v)
\brief Return the distance between the ends of this and another vector
This is symantically treating the vector like a point
|
double |
distance2(btVector3 v)
\brief Return the distance squared between the ends of this and another vector
This is symantically treating the vector like a point
|
btVector3 |
dividePut(double s)
\brief Inversely scale the vector
|
double |
dot(btVector3 v)
\brief Return the dot product
|
btVector3 |
dot3(btVector3 v0,
btVector3 v1,
btVector3 v2) |
boolean |
equals(btVector3 other) |
int |
furthestAxis() |
boolean |
fuzzyZero() |
btVector3 |
getPointer(long i) |
void |
getSkewSymmetricMatrix(btVector3 v0,
btVector3 v1,
btVector3 v2) |
double |
getX()
\brief Return the x value
|
double |
getY()
\brief Return the y value
|
double |
getZ()
\brief Return the z value
|
boolean |
isZero() |
double |
length()
\brief Return the length of the vector
|
double |
length2()
\brief Return the length of the vector squared
|
btVector3 |
lerp(btVector3 v,
double t)
\brief Return the linear interpolation between this and another vector
|
DoublePointer |
m_floats() |
double |
m_floats(int i) |
btVector3 |
m_floats(int i,
double setter) |
int |
maxAxis()
\brief Return the axis with the largest value
Note return values are 0,1,2 for x, y, or z
|
long |
maxDot(btVector3 array,
long array_count,
double[] dotOut) |
long |
maxDot(btVector3 array,
long array_count,
DoubleBuffer dotOut) |
long |
maxDot(btVector3 array,
long array_count,
DoublePointer dotOut)
\brief returns index of maximum dot product between this and vectors in array[]
|
int |
minAxis()
\brief Return the axis with the smallest value
Note return values are 0,1,2 for x, y, or z
|
long |
minDot(btVector3 array,
long array_count,
double[] dotOut) |
long |
minDot(btVector3 array,
long array_count,
DoubleBuffer dotOut) |
long |
minDot(btVector3 array,
long array_count,
DoublePointer dotOut)
\brief returns index of minimum dot product between this and vectors in array[]
|
btVector3 |
multiplyPut(btVector3 v)
\brief Elementwise multiply this vector by the other
|
btVector3 |
multiplyPut(double s)
\brief Scale the vector
|
double |
norm()
\brief Return the norm (length) of the vector
|
btVector3 |
normalize()
\brief Normalize this vector
x^2 + y^2 + z^2 = 1
|
btVector3 |
normalized()
\brief Return a normalized version of this vector
|
boolean |
notEquals(btVector3 other) |
btVector3 |
position(long position) |
btVector3 |
rotate(btVector3 wAxis,
double angle)
\brief Return a rotated version of this vector
|
double |
safeNorm()
\brief Return the norm (length) of the vector
|
btVector3 |
safeNormalize() |
void |
serialize(btVector3DoubleData dataOut) |
void |
serializeDouble(btVector3DoubleData dataOut) |
void |
serializeFloat(btVector3FloatData dataOut) |
void |
setInterpolate3(btVector3 v0,
btVector3 v1,
double rt) |
void |
setMax(btVector3 other)
\brief Set each element to the max of the current values and the values of another btVector3
|
void |
setMin(btVector3 other)
\brief Set each element to the min of the current values and the values of another btVector3
|
void |
setValue(double _x,
double _y,
double _z) |
void |
setW(double _w)
\brief Set the w value
|
void |
setX(double _x)
\brief Set the x value
|
void |
setY(double _y)
\brief Set the y value
|
void |
setZ(double _z)
\brief Set the z value
|
void |
setZero() |
btVector3 |
subtractPut(btVector3 v)
\brief Subtract a vector from this one
|
double |
triple(btVector3 v1,
btVector3 v2) |
double |
w()
\brief Return the w value
|
double |
x()
\brief Return the x value
|
double |
y()
\brief Return the y value
|
double |
z()
\brief Return the z value
|
address, asBuffer, asByteBuffer, availablePhysicalBytes, calloc, capacity, capacity, close, deallocate, deallocate, deallocateReferences, deallocator, deallocator, equals, fill, formatBytes, free, getDirectBufferAddress, getPointer, getPointer, getPointer, hashCode, interruptDeallocatorThread, isNull, isNull, limit, limit, malloc, maxBytes, maxPhysicalBytes, memchr, memcmp, memcpy, memmove, memset, offsetAddress, offsetof, offsetof, parseBytes, physicalBytes, physicalBytesInaccurate, position, put, realloc, referenceCount, releaseReference, retainReference, setNull, sizeof, sizeof, toString, totalBytes, totalCount, totalPhysicalBytes, withDeallocator, zero
public btVector3(Pointer p)
Pointer(Pointer)
.public btVector3(long size)
Pointer.position(long)
.public btVector3()
public btVector3 getPointer(long i)
getPointer
in class Pointer
public btVector3 m_floats(int i, double setter)
@MemberGetter @Cast(value="btScalar*") public DoublePointer m_floats()
@ByRef @Name(value="operator +=") public btVector3 addPut(@Const @ByRef btVector3 v)
The
- vector to add to this one@ByRef @Name(value="operator -=") public btVector3 subtractPut(@Const @ByRef btVector3 v)
The
- vector to subtract@ByRef @Name(value="operator *=") public btVector3 multiplyPut(@Cast(value="const btScalar") double s)
s
- Scale factor@ByRef @Name(value="operator /=") public btVector3 dividePut(@Cast(value="const btScalar") double s)
s
- Scale factor to divide by@Cast(value="btScalar") public double dot(@Const @ByRef btVector3 v)
v
- The other vector in the dot product@Cast(value="btScalar") public double length2()
@Cast(value="btScalar") public double safeNorm()
@Cast(value="btScalar") public double distance2(@Const @ByRef btVector3 v)
@Cast(value="btScalar") public double distance(@Const @ByRef btVector3 v)
@ByVal public btVector3 rotate(@Const @ByRef btVector3 wAxis, @Cast(value="const btScalar") double angle)
wAxis
- The axis to rotate aboutangle
- The angle to rotate by@Cast(value="btScalar") public double angle(@Const @ByRef btVector3 v)
v
- The other vector@ByVal public btVector3 absolute()
@ByVal public btVector3 cross(@Const @ByRef btVector3 v)
v
- The other vector@Cast(value="btScalar") public double triple(@Const @ByRef btVector3 v1, @Const @ByRef btVector3 v2)
public int minAxis()
public int maxAxis()
public int furthestAxis()
public int closestAxis()
public void setInterpolate3(@Const @ByRef btVector3 v0, @Const @ByRef btVector3 v1, @Cast(value="btScalar") double rt)
@ByVal public btVector3 lerp(@Const @ByRef btVector3 v, @Cast(value="const btScalar") double t)
v
- The other vectort
- The ration of this to v (t = 0 => return this, t=1 => return other)@ByRef @Name(value="operator *=") public btVector3 multiplyPut(@Const @ByRef btVector3 v)
v
- The other vector@Cast(value="btScalar*") @Name(value="operator btScalar*") public DoublePointer asDoublePointer()
@Cast(value="bool") @Name(value="operator ==") public boolean equals(@Const @ByRef btVector3 other)
@Cast(value="bool") @Name(value="operator !=") public boolean notEquals(@Const @ByRef btVector3 other)
public void setMax(@Const @ByRef btVector3 other)
other
- The other btVector3 to compare withpublic void setMin(@Const @ByRef btVector3 other)
other
- The other btVector3 to compare withpublic void setValue(@Cast(value="const btScalar") double _x, @Cast(value="const btScalar") double _y, @Cast(value="const btScalar") double _z)
public void setZero()
public void serialize(@ByRef btVector3DoubleData dataOut)
public void deSerialize(@Const @ByRef btVector3DoubleData dataIn)
public void deSerialize(@Const @ByRef btVector3FloatData dataIn)
public void serializeFloat(@ByRef btVector3FloatData dataOut)
public void deSerializeFloat(@Const @ByRef btVector3FloatData dataIn)
public void serializeDouble(@ByRef btVector3DoubleData dataOut)
public void deSerializeDouble(@Const @ByRef btVector3DoubleData dataIn)
public long maxDot(@Const btVector3 array, long array_count, @Cast(value="btScalar*") @ByRef DoublePointer dotOut)
array
- The other vectorsarray_count
- The number of other vectorsdotOut
- The maximum dot productpublic long maxDot(@Const btVector3 array, long array_count, @Cast(value="btScalar*") @ByRef DoubleBuffer dotOut)
public long maxDot(@Const btVector3 array, long array_count, @Cast(value="btScalar*") @ByRef double[] dotOut)
public long minDot(@Const btVector3 array, long array_count, @Cast(value="btScalar*") @ByRef DoublePointer dotOut)
array
- The other vectorsarray_count
- The number of other vectorsdotOut
- The minimum dot productpublic long minDot(@Const btVector3 array, long array_count, @Cast(value="btScalar*") @ByRef DoubleBuffer dotOut)
public long minDot(@Const btVector3 array, long array_count, @Cast(value="btScalar*") @ByRef double[] dotOut)
Copyright © 2024. All rights reserved.