Java Doc for Transform3D.java in  » 6.0-JDK-Modules » java-3d » javax » media » j3d » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » 6.0 JDK Modules » java 3d » javax.media.j3d 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   javax.media.j3d.Transform3D

Transform3D
public class Transform3D (Code)
A generalized transform object represented internally as a 4x4 double-precision floating point matrix. The mathematical representation is row major, as in traditional matrix mathematics. A Transform3D is used to perform translations, rotations, and scaling and shear effects.

A transform has an associated type, and all type classification is left to the Transform3D object. A transform will typically have multiple types, unless it is a general, unclassifiable matrix, in which case it won't be assigned a type.

The Transform3D type is internally computed when the transform object is constructed and updated any time it is modified. A matrix will typically have multiple types. For example, the type associated with an identity matrix is the result of ORing all of the types, except for ZERO and NEGATIVE_DETERMINANT, together. There are public methods available to get the ORed type of the transformation, the sign of the determinant, and the least general matrix type. The matrix type flags are defined as follows:

  • ZERO - zero matrix. All of the elements in the matrix have the value 0.
  • IDENTITY - identity matrix. A matrix with ones on its main diagonal and zeros every where else.
  • SCALE - the matrix is a uniform scale matrix - there are no rotational or translation components.
  • ORTHOGONAL - the four row vectors that make up an orthogonal matrix form a basis, meaning that they are mutually orthogonal. The scale is unity and there are no translation components.
  • RIGID - the upper 3 X 3 of the matrix is orthogonal, and there is a translation component-the scale is unity.
  • CONGRUENT - this is an angle- and length-preserving matrix, meaning that it can translate, rotate, and reflect about an axis, and scale by an amount that is uniform in all directions. These operations preserve the distance between any two points, and the angle between any two intersecting lines.
  • AFFINE - an affine matrix can translate, rotate, reflect, scale anisotropically, and shear. Lines remain straight, and parallel lines remain parallel, but the angle between intersecting lines can change.
A matrix is also classified by the sign of its determinant:

    NEGATIVE_DETERMINANT - this matrix has a negative determinant. An orthogonal matrix with a positive determinant is a rotation matrix. An orthogonal matrix with a negative determinant is a reflection and rotation matrix.

The Java 3D model for 4 X 4 transformations is:

     [ m00 m01 m02 m03 ]   [ x ]   [ x' ]
     [ m10 m11 m12 m13 ] . [ y ] = [ y' ]
     [ m20 m21 m22 m23 ]   [ z ]   [ z' ]
     [ m30 m31 m32 m33 ]   [ w ]   [ w' ]
     x' = m00 . x+m01 . y+m02 . z+m03 . w
     y' = m10 . x+m11 . y+m12 . z+m13 . w
     z' = m20 . x+m21 . y+m22 . z+m23 . w
     w' = m30 . x+m31 . y+m32 . z+m33 . w
     

Note: When transforming a Point3f or a Point3d, the input w is set to 1. When transforming a Vector3f or Vector3d, the input w is set to 0.



Field Summary
final public static  intAFFINE
     An affine matrix can translate, rotate, reflect, scale anisotropically, and shear.
final public static  intCONGRUENT
     This is an angle and length preserving matrix, meaning that it can translate, rotate, and reflect about an axis, and scale by an amount that is uniform in all directions.
final static  doubleEPSILON
    
final static  doubleEPSILON_ABSOLUTE
    
final static  doubleEPSILON_RELATIVE
    
final public static  intIDENTITY
     An identity matrix.
final public static  intNEGATIVE_DETERMINANT
     This matrix has a negative determinant; an orthogonal matrix with a positive determinant is a rotation matrix; an orthogonal matrix with a negative determinant is a reflection and rotation matrix.
final public static  intORTHOGONAL
     The four row vectors that make up an orthogonal matrix form a basis, meaning that they are mutually orthogonal; an orthogonal matrix with positive determinant is a pure rotation matrix; a negative determinant indicates a rotation and a reflection.
final public static  intRIGID
     This matrix is a rotation and a translation with unity scale; The upper 3x3 of the matrix is orthogonal, and there is a translation component.
final public static  intSCALE
     A Uniform scale matrix with no translation or other off-diagonal components.
final public static  intTRANSLATION
     A translation-only matrix with ones on the diagonal.
final public static  intZERO
     A zero matrix.
 booleanautoNormalize
    
 double[]mat
    
 double[]rot
    
 double[]scales
    

Constructor Summary
public  Transform3D(Matrix4f m1)
     Constructs and initializes a transform from the 4 x 4 matrix.
public  Transform3D(Matrix4d m1)
     Constructs and initializes a transform from the 4 x 4 matrix.
public  Transform3D(Transform3D t1)
     Constructs and initializes a transform from the Transform3D object.
public  Transform3D()
     Constructs and initializes a transform to the identity matrix.
public  Transform3D(float[] matrix)
     Constructs and initializes a transform from the float array of length 16; the top row of the matrix is initialized to the first four elements of the array, and so on.
public  Transform3D(double[] matrix)
     Constructs and initializes a transform from the double precision array of length 16; the top row of the matrix is initialized to the first four elements of the array, and so on.
public  Transform3D(Quat4d q1, Vector3d t1, double s)
     Constructs and initializes a transform from the quaternion, translation, and scale values.
public  Transform3D(Quat4f q1, Vector3d t1, double s)
     Constructs and initializes a transform from the quaternion, translation, and scale values.
public  Transform3D(Quat4f q1, Vector3f t1, float s)
     Constructs and initializes a transform from the quaternion, translation, and scale values.
public  Transform3D(GMatrix m1)
     Constructs a transform and initializes it to the upper 4 x 4 of the GMatrix argument.
public  Transform3D(Matrix3f m1, Vector3d t1, double s)
     Constructs and initializes a transform from the rotation matrix, translation, and scale values.
public  Transform3D(Matrix3d m1, Vector3d t1, double s)
     Constructs and initializes a transform from the rotation matrix, translation, and scale values.
public  Transform3D(Matrix3f m1, Vector3f t1, float s)
     Constructs and initializes a transform from the rotation matrix, translation, and scale values.

Method Summary
final public  voidadd(Transform3D t1)
     Adds this transform to transform t1 and places the result into this: this = this + t1.
final public  voidadd(Transform3D t1, Transform3D t2)
     Adds transforms t1 and t2 and places the result into this transform.
final  doubleaffineDeterminant()
    
static  intcompute_2X2(double f, double g, double h, double[] single_values, double[] snl, double[] csl, double[] snr, double[] csr, int index)
    
static  doublecompute_rot(double f, double g, double[] sin, double[] cos, int index, int first)
    
final static  doublecompute_shift(double f, double g, double h)
    
final static  doubled_sign(double a, double b)
    
final public  doubledeterminant()
     Calculates and returns the determinant of this transform.
public  booleanepsilonEquals(Transform3D t1, double epsilon)
     Returns true if the L-infinite distance between this matrix and matrix m1 is less than or equal to the epsilon parameter, otherwise returns false.
public  booleanequals(Transform3D t1)
     Returns true if all of the data members of transform t1 are equal to the corresponding data members in this Transform3D.
public  booleanequals(Object o1)
     Returns true if the Object o1 is of type Transform3D and all of the data members of o1 are equal to the corresponding data members in this Transform3D.
Parameters:
  o1 - the object with which the comparison is made.
public  voidfrustum(double left, double right, double bottom, double top, double near, double far)
     Creates a perspective projection transform that mimics a standard, camera-based, view-model.
final public  voidget(double[] matrix)
     Places the values of this transform into the double precision array of length 16.
final public  voidget(float[] matrix)
     Places the values of this transform into the single precision array of length 16.
final public  voidget(Matrix3d m1)
     Places the normalized rotational component of this transform into the 3x3 matrix argument.
final public  voidget(Matrix3f m1)
     Places the normalized rotational component of this transform into the 3x3 matrix argument.
final public  voidget(Quat4f q1)
     Places the quaternion equivalent of the normalized rotational component of this transform into the quaternion parameter.
final public  voidget(Quat4d q1)
     Places the quaternion equivalent of the normalized rotational component of this transform into the quaternion parameter.
final public  voidget(Matrix4d matrix)
     Places the values of this transform into the double precision matrix argument.
final public  voidget(Matrix4f matrix)
     Places the values of this transform into the single precision matrix argument.
final public  doubleget(Quat4d q1, Vector3d t1)
     Places the quaternion equivalent of the normalized rotational component of this transform into the quaternion parameter; places the translational component into the Vector parameter.
final public  floatget(Quat4f q1, Vector3f t1)
     Places the quaternion equivalent of the normalized rotational component of this transform into the quaternion parameter; places the translational component into the Vector parameter.
final public  doubleget(Quat4f q1, Vector3d t1)
     Places the quaternion equivalent of the normalized rotational component of this transform into the quaternion parameter; places the translational component into the Vector parameter.
final public  doubleget(Matrix3d m1, Vector3d t1)
     Places the normalized rotational component of this transform into the matrix parameter; place the translational component into the vector parameter.
final public  floatget(Matrix3f m1, Vector3f t1)
     Places the normalized rotational component of this transform into the matrix parameter; place the translational component into the vector parameter.
final public  doubleget(Matrix3f m1, Vector3d t1)
     Places the normalized rotational component of this transform into the matrix parameter; place the translational component into the vector parameter.
final public  voidget(Vector3f trans)
     Retrieves the translational components of this transform.
final public  voidget(Vector3d trans)
     Retrieves the translational components of this transform.
final public  booleangetAutoNormalize()
     Returns the state of auto-normalization.
final public  intgetBestType()
     Returns the least general type of this matrix; the order of generality from least to most is: ZERO, IDENTITY, SCALE/TRANSLATION, ORTHOGONAL, RIGID, CONGRUENT, AFFINE.
final public  booleangetDeterminantSign()
     Returns the sign of the determinant of this matrix; a return value of true indicates a non-negative determinant; a return value of false indicates a negative determinant.
 doublegetDistanceScale()
    
final  voidgetRotation(Transform3D t)
    
final public  voidgetRotationScale(Matrix3f m1)
     Gets the upper 3x3 values of this matrix and places them into the matrix m1.
final public  voidgetRotationScale(Matrix3d m1)
     Gets the upper 3x3 values of this matrix and places them into the matrix m1.
final public  doublegetScale()
     Returns the uniform scale factor of this matrix.
final public  voidgetScale(Vector3d scale)
     Gets the possibly non-uniform scale components of the current transform and places them into the scale vector.
final public  intgetType()
     Returns the type of this matrix as an or'ed bitmask of of all of the type classifications to which it belongs.
synchronized  voidgetWithLock(Transform3D t1)
    
public  inthashCode()
     Returns a hash code value based on the data values in this object.
final public  voidinvert(Transform3D t1)
     Sets the value of this transform to the inverse of the passed Transform3D parameter.
final public  voidinvert()
     Inverts this transform in place.
final  voidinvertAffine(Transform3D t1)
     Affine invert routine.
final  voidinvertAffine()
     Affine invert routine.
final  voidinvertGeneral(Transform3D t1)
     General invert routine.
final  booleanisAffine()
    
final  booleanisCongruent()
    
final  booleanisOrtho()
    
final  booleanisRigid()
    
public  voidlookAt(Point3d eye, Point3d center, Vector3d up)
     Helping function that specifies the position and orientation of a view matrix.
static  voidluBacksubstitution(double[] matrix1, int[] row_perm, double[] matrix2)
     Solves a set of linear equations.
static  booleanluDecomposition(double[] matrix0, int[] row_perm)
     Given a 4x4 array "matrix0", this function replaces it with the LU decomposition of a row-wise permutation of itself.
final static  doublemax(double a, double b)
    
final static  doublemin(double a, double b)
    
final public  voidmul(double scalar)
     Multiplies each element of this transform by a scalar.
final public  voidmul(double scalar, Transform3D t1)
     Multiplies each element of transform t1 by a scalar and places the result into this.
final public  voidmul(Transform3D t1)
     Sets the value of this transform to the result of multiplying itself with transform t1 (this = this * t1).
final public  voidmul(Transform3D t1, Transform3D t2)
     Sets the value of this transform to the result of multiplying transform t1 by transform t2 (this = t1*t2).
final public  voidmulInverse(Transform3D t1)
     Multiplies this transform by the inverse of transform t1.
final public  voidmulInverse(Transform3D t1, Transform3D t2)
     Multiplies transform t1 by the inverse of transform t2.
final public  voidmulTransposeBoth(Transform3D t1, Transform3D t2)
     Multiplies the transpose of transform t1 by the transpose of transform t2 and places the result into this transform (this = transpose(t1) * transpose(t2)).
final public  voidmulTransposeLeft(Transform3D t1, Transform3D t2)
     Multiplies the transpose of transform t1 by transform t2 and places the result into this matrix (this = transpose(t1) * t2).
final public  voidmulTransposeRight(Transform3D t1, Transform3D t2)
     Multiplies transform t1 by the transpose of transform t2 and places the result into this transform (this = t1 * transpose(t2)).
final public  voidnormalize()
     Normalizes the rotational components (upper 3x3) of this matrix in place using a Singular Value Decomposition (SVD). This operation ensures that the column vectors of this matrix are orthogonal to each other.
final public  voidnormalize(Transform3D t1)
     Normalizes the rotational components (upper 3x3) of transform t1 using a Singular Value Decomposition (SVD), and places the result into this transform. This operation ensures that the column vectors of this matrix are orthogonal to each other.
final public  voidnormalizeCP()
     Normalizes the rotational components (upper 3x3) of this transform in place using a Cross Product (CP) normalization. This operation ensures that the column vectors of this matrix are orthogonal to each other.
final public  voidnormalizeCP(Transform3D t1)
     Normalizes the rotational components (upper 3x3) of transform t1 using a Cross Product (CP) normalization, and places the result into this transform. This operation ensures that the column vectors of this matrix are orthogonal to each other.
public  voidortho(double left, double right, double bottom, double top, double near, double far)
     Creates an orthographic projection transform that mimics a standard, camera-based, view-model.
public  voidperspective(double fovx, double aspect, double zNear, double zFar)
     Creates a perspective projection transform that mimics a standard, camera-based, view-model.
public  voidrotX(double angle)
     Sets the value of this transform to a counter clockwise rotation about the x axis.
public  voidrotY(double angle)
     Sets the value of this transform to a counter clockwise rotation about the y axis.
public  voidrotZ(double angle)
     Sets the value of this transform to a counter clockwise rotation about the z axis.
final  booleanrotateZero()
    
final public  voidscaleAdd(double s, Transform3D t1, Transform3D t2)
     Scales transform t1 by a Uniform scale matrix with scale factor s and then adds transform t2 (this = S*t1 + t2).
final public  voidscaleAdd(double s, Transform3D t1)
     Scales this transform by a Uniform scale matrix with scale factor s and then adds transform t1 (this = S*this + t1).
final public  voidset(Quat4f q1)
     Sets the value of this transform to the matrix conversion of the single precision quaternion argument; the non-rotational components are set as if this were an identity matrix.
final public  voidset(Quat4d q1)
     Sets the value of this transform to the matrix conversion of the double precision quaternion argument; the non-rotational components are set as if this were an identity matrix.
final public  voidset(AxisAngle4f a1)
     Sets the value of this transform to the matrix conversion of the single precision axis-angle argument; all of the matrix values are modified.
final public  voidset(AxisAngle4d a1)
     Sets the value of this transform to the matrix conversion of the double precision axis-angle argument; all of the matrix values are modified.
final public  voidset(Vector3f trans)
     Sets the translational value of this matrix to the Vector3f parameter values, and sets the other components of the matrix as if this transform were an identity matrix.
final public  voidset(Vector3d trans)
     Sets the translational value of this matrix to the Vector3d paramter values, and sets the other components of the matrix as if this transform were an identity matrix.
final public  voidset(Quat4d q1, Vector3d t1, double s)
     Sets the value of this matrix from the rotation expressed by the quaternion q1, the translation t1, and the scale s.
final public  voidset(Quat4f q1, Vector3d t1, double s)
     Sets the value of this matrix from the rotation expressed by the quaternion q1, the translation t1, and the scale s.
final public  voidset(Quat4f q1, Vector3f t1, float s)
     Sets the value of this matrix from the rotation expressed by the quaternion q1, the translation t1, and the scale s.
final public  voidset(Matrix3f m1, Vector3f t1, float s)
     Sets the value of this matrix from the rotation expressed by the rotation matrix m1, the translation t1, and the scale s.
final public  voidset(Matrix3f m1, Vector3d t1, double s)
     Sets the value of this matrix from the rotation expressed by the rotation matrix m1, the translation t1, and the scale s.
final public  voidset(Matrix3d m1, Vector3d t1, double s)
     Sets the value of this matrix from the rotation expressed by the rotation matrix m1, the translation t1, and the scale s.
final public  voidset(GMatrix matrix)
     Sets the matrix values of this transform to the matrix values in the upper 4x4 corner of the GMatrix parameter.
final public  voidset(Transform3D t1)
     Sets the matrix, type, and state of this transform to the matrix, type, and state of transform t1.
final public  voidset(double[] matrix)
     Sets the matrix values of this transform to the matrix values in the double precision array parameter.
final public  voidset(float[] matrix)
     Sets the matrix values of this transform to the matrix values in the single precision array parameter.
final public  voidset(Matrix4d m1)
     Sets the matrix values of this transform to the matrix values in the double precision Matrix4d argument.
final public  voidset(Matrix4f m1)
     Sets the matrix values of this transform to the matrix values in the single precision Matrix4f argument.
final public  voidset(Matrix3f m1)
     Sets the rotational component (upper 3x3) of this transform to the matrix values in the single precision Matrix3f argument; the other elements of this transform are initialized as if this were an identity matrix (i.e., affine matrix with no translational component).
final public  voidset(Matrix3d m1)
     Sets the rotational component (upper 3x3) of this transform to the matrix values in the double precision Matrix3d argument; the other elements of this transform are initialized as if this were an identity matrix (ie, affine matrix with no translational component).
final public  voidset(double scale)
     Sets the value of this transform to a uniform scale; all of the matrix values are modified.
final public  voidset(double scale, Vector3d v1)
     Sets the value of this transform to a scale and translation matrix; the scale is not applied to the translation and all of the matrix values are modified.
final public  voidset(float scale, Vector3f v1)
     Sets the value of this transform to a scale and translation matrix; the scale is not applied to the translation and all of the matrix values are modified.
final public  voidset(Vector3d v1, double scale)
     Sets the value of this transform to a scale and translation matrix; the translation is scaled by the scale factor and all of the matrix values are modified.
final public  voidset(Vector3f v1, float scale)
     Sets the value of this transform to a scale and translation matrix; the translation is scaled by the scale factor and all of the matrix values are modified.
final public  voidsetAutoNormalize(boolean autoNormalize)
     Sets a flag that enables or disables automatic SVD normalization.
final public  voidsetEuler(Vector3d euler)
     Sets the rotational component (upper 3x3) of this transform to the rotation matrix converted from the Euler angles provided; the other non-rotational elements are set as if this were an identity matrix. The euler parameter is a Vector3d consisting of three rotation angles applied first about the X, then Y then Z axis. These rotations are applied using a static frame of reference.
final public  voidsetIdentity()
     Sets this transform to the identity matrix.
final public  voidsetNonUniformScale(double xScale, double yScale, double zScale)
     Replaces the current transform with a non-uniform scale transform.
final  voidsetOrthoDirtyBit()
    
final public  voidsetRotation(Matrix3d m1)
     Sets the rotational component (upper 3x3) of this transform to the matrix values in the double precision Matrix3d argument; the other elements of this transform are unchanged; any pre-existing scale will be preserved; the argument matrix m1 will be checked for proper normalization when this transform is internally classified.
final public  voidsetRotation(Matrix3f m1)
     Sets the rotational component (upper 3x3) of this transform to the matrix values in the single precision Matrix3f argument; the other elements of this transform are unchanged; any pre-existing scale will be preserved; the argument matrix m1 will be checked for proper normalization when this transform is internally classified.
final public  voidsetRotation(Quat4f q1)
     Sets the rotational component (upper 3x3) of this transform to the matrix equivalent values of the quaternion argument; the other elements of this transform are unchanged; any pre-existing scale in the transform is preserved.
final public  voidsetRotation(Quat4d q1)
     Sets the rotational component (upper 3x3) of this transform to the matrix equivalent values of the quaternion argument; the other elements of this transform are unchanged; any pre-existing scale in the transform is preserved.
final public  voidsetRotation(AxisAngle4d a1)
     Sets the rotational component (upper 3x3) of this transform to the matrix equivalent values of the axis-angle argument; the other elements of this transform are unchanged; any pre-existing scale in the transform is preserved.
final public  voidsetRotation(AxisAngle4f a1)
     Sets the rotational component (upper 3x3) of this transform to the matrix equivalent values of the axis-angle argument; the other elements of this transform are unchanged; any pre-existing scale in the transform is preserved.
final public  voidsetRotationScale(Matrix3f m1)
     Replaces the upper 3x3 matrix values of this transform with the values in the matrix m1.
final public  voidsetRotationScale(Matrix3d m1)
     Replaces the upper 3x3 matrix values of this transform with the values in the matrix m1.
final public  voidsetScale(double scale)
     Sets the scale component of the current transform; any existing scale is first factored out of the existing transform before the new scale is applied.
final public  voidsetScale(Vector3d scale)
     Sets the possibly non-uniform scale component of the current transform; any existing scale is first factored out of the existing transform before the new scale is applied.
final public  voidsetTranslation(Vector3f trans)
     Replaces the translational components of this transform to the values in the Vector3f argument; the other values of this transform are not modified.
final public  voidsetTranslation(Vector3d trans)
     Replaces the translational components of this transform to the values in the Vector3d argument; the other values of this transform are not modified.
synchronized  voidsetWithLock(Transform3D t1)
    
final public  voidsetZero()
     Sets this transform to all zeros.
final public  voidsub(Transform3D t1)
     Subtracts transform t1 from this transform and places the result into this: this = this - t1.
final public  voidsub(Transform3D t1, Transform3D t2)
     Subtracts transform t2 from transform t1 and places the result into this: this = t1 - t2.
public  StringtoString()
     Returns the matrix elements of this transform as a string.
 voidtransform(Point3d point, Point4d pointOut)
     Transforms the point parameter with this transform and places the result into pointOut.
final public  voidtransform(Vector4d vec, Vector4d vecOut)
     Transform the vector vec using this transform and place the result into vecOut.
final public  voidtransform(Vector4d vec)
     Transform the vector vec using this Transform and place the result back into vec.
final public  voidtransform(Vector4f vec, Vector4f vecOut)
     Transform the vector vec using this Transform and place the result into vecOut.
final public  voidtransform(Vector4f vec)
     Transform the vector vec using this Transform and place the result back into vec.
final public  voidtransform(Point3d point, Point3d pointOut)
     Transforms the point parameter with this transform and places the result into pointOut.
final public  voidtransform(Point3d point)
     Transforms the point parameter with this transform and places the result back into point.
final public  voidtransform(Vector3d normal, Vector3d normalOut)
     Transforms the normal parameter by this transform and places the value into normalOut.
final public  voidtransform(Vector3d normal)
     Transforms the normal parameter by this transform and places the value back into normal.
final public  voidtransform(Point3f point, Point3f pointOut)
     Transforms the point parameter with this transform and places the result into pointOut.
final public  voidtransform(Point3f point)
     Transforms the point parameter with this transform and places the result back into point.
final public  voidtransform(Vector3f normal, Vector3f normalOut)
     Transforms the normal parameter by this transform and places the value into normalOut.
final public  voidtransform(Vector3f normal)
     Transforms the normal parameter by this transform and places the value back into normal.
final public  voidtranspose()
     Transposes this matrix in place.
final public  voidtranspose(Transform3D t1)
     Transposes transform t1 and places the value into this transform.
final  booleanzeroTranslation()
    

Field Detail
AFFINE
final public static int AFFINE(Code)
An affine matrix can translate, rotate, reflect, scale anisotropically, and shear. Lines remain straight, and parallel lines remain parallel, but the angle between intersecting lines can change. In order for a transform to be classified as affine, the 4th row must be: [0, 0, 0, 1].



CONGRUENT
final public static int CONGRUENT(Code)
This is an angle and length preserving matrix, meaning that it can translate, rotate, and reflect about an axis, and scale by an amount that is uniform in all directions. These operations preserve the distance between any two points and the angle between any two intersecting lines.



EPSILON
final static double EPSILON(Code)



EPSILON_ABSOLUTE
final static double EPSILON_ABSOLUTE(Code)



EPSILON_RELATIVE
final static double EPSILON_RELATIVE(Code)



IDENTITY
final public static int IDENTITY(Code)
An identity matrix.



NEGATIVE_DETERMINANT
final public static int NEGATIVE_DETERMINANT(Code)
This matrix has a negative determinant; an orthogonal matrix with a positive determinant is a rotation matrix; an orthogonal matrix with a negative determinant is a reflection and rotation matrix.



ORTHOGONAL
final public static int ORTHOGONAL(Code)
The four row vectors that make up an orthogonal matrix form a basis, meaning that they are mutually orthogonal; an orthogonal matrix with positive determinant is a pure rotation matrix; a negative determinant indicates a rotation and a reflection.



RIGID
final public static int RIGID(Code)
This matrix is a rotation and a translation with unity scale; The upper 3x3 of the matrix is orthogonal, and there is a translation component.



SCALE
final public static int SCALE(Code)
A Uniform scale matrix with no translation or other off-diagonal components.



TRANSLATION
final public static int TRANSLATION(Code)
A translation-only matrix with ones on the diagonal.



ZERO
final public static int ZERO(Code)
A zero matrix.



autoNormalize
boolean autoNormalize(Code)



mat
double[] mat(Code)



rot
double[] rot(Code)



scales
double[] scales(Code)




Constructor Detail
Transform3D
public Transform3D(Matrix4f m1)(Code)
Constructs and initializes a transform from the 4 x 4 matrix. The type of the constructed transform will be classified automatically.
Parameters:
  m1 - the 4 x 4 transformation matrix



Transform3D
public Transform3D(Matrix4d m1)(Code)
Constructs and initializes a transform from the 4 x 4 matrix. The type of the constructed transform will be classified automatically.
Parameters:
  m1 - the 4 x 4 transformation matrix



Transform3D
public Transform3D(Transform3D t1)(Code)
Constructs and initializes a transform from the Transform3D object.
Parameters:
  t1 - the transformation object to be copied



Transform3D
public Transform3D()(Code)
Constructs and initializes a transform to the identity matrix.



Transform3D
public Transform3D(float[] matrix)(Code)
Constructs and initializes a transform from the float array of length 16; the top row of the matrix is initialized to the first four elements of the array, and so on. The type of the transform object is classified internally.
Parameters:
  matrix - a float array of 16



Transform3D
public Transform3D(double[] matrix)(Code)
Constructs and initializes a transform from the double precision array of length 16; the top row of the matrix is initialized to the first four elements of the array, and so on. The type of the transform is classified internally.
Parameters:
  matrix - a float array of 16



Transform3D
public Transform3D(Quat4d q1, Vector3d t1, double s)(Code)
Constructs and initializes a transform from the quaternion, translation, and scale values. The scale is applied only to the rotational components of the matrix (upper 3 x 3) and not to the translational components of the matrix.
Parameters:
  q1 - the quaternion value representing the rotational component
Parameters:
  t1 - the translational component of the matrix
Parameters:
  s - the scale value applied to the rotational components



Transform3D
public Transform3D(Quat4f q1, Vector3d t1, double s)(Code)
Constructs and initializes a transform from the quaternion, translation, and scale values. The scale is applied only to the rotational components of the matrix (upper 3 x 3) and not to the translational components of the matrix.
Parameters:
  q1 - the quaternion value representing the rotational component
Parameters:
  t1 - the translational component of the matrix
Parameters:
  s - the scale value applied to the rotational components



Transform3D
public Transform3D(Quat4f q1, Vector3f t1, float s)(Code)
Constructs and initializes a transform from the quaternion, translation, and scale values. The scale is applied only to the rotational components of the matrix (upper 3 x 3) and not to the translational components of the matrix.
Parameters:
  q1 - the quaternion value representing the rotational component
Parameters:
  t1 - the translational component of the matrix
Parameters:
  s - the scale value applied to the rotational components



Transform3D
public Transform3D(GMatrix m1)(Code)
Constructs a transform and initializes it to the upper 4 x 4 of the GMatrix argument. If the parameter matrix is smaller than 4 x 4, the remaining elements in the transform matrix are assigned to zero.
Parameters:
  m1 - the GMatrix



Transform3D
public Transform3D(Matrix3f m1, Vector3d t1, double s)(Code)
Constructs and initializes a transform from the rotation matrix, translation, and scale values. The scale is applied only to the rotational component of the matrix (upper 3x3) and not to the translational component of the matrix.
Parameters:
  m1 - the rotation matrix representing the rotational component
Parameters:
  t1 - the translational component of the matrix
Parameters:
  s - the scale value applied to the rotational components



Transform3D
public Transform3D(Matrix3d m1, Vector3d t1, double s)(Code)
Constructs and initializes a transform from the rotation matrix, translation, and scale values. The scale is applied only to the rotational components of the matrix (upper 3x3) and not to the translational components of the matrix.
Parameters:
  m1 - the rotation matrix representing the rotational component
Parameters:
  t1 - the translational component of the matrix
Parameters:
  s - the scale value applied to the rotational components



Transform3D
public Transform3D(Matrix3f m1, Vector3f t1, float s)(Code)
Constructs and initializes a transform from the rotation matrix, translation, and scale values. The scale is applied only to the rotational components of the matrix (upper 3x3) and not to the translational components of the matrix.
Parameters:
  m1 - the rotation matrix representing the rotational component
Parameters:
  t1 - the translational component of the matrix
Parameters:
  s - the scale value applied to the rotational components




Method Detail
add
final public void add(Transform3D t1)(Code)
Adds this transform to transform t1 and places the result into this: this = this + t1.
Parameters:
  t1 - the transform to be added to this transform



add
final public void add(Transform3D t1, Transform3D t2)(Code)
Adds transforms t1 and t2 and places the result into this transform.
Parameters:
  t1 - the transform to be added
Parameters:
  t2 - the transform to be added



affineDeterminant
final double affineDeterminant()(Code)



compute_2X2
static int compute_2X2(double f, double g, double h, double[] single_values, double[] snl, double[] csl, double[] snr, double[] csr, int index)(Code)



compute_rot
static double compute_rot(double f, double g, double[] sin, double[] cos, int index, int first)(Code)



compute_shift
final static double compute_shift(double f, double g, double h)(Code)



d_sign
final static double d_sign(double a, double b)(Code)



determinant
final public double determinant()(Code)
Calculates and returns the determinant of this transform. the double precision determinant



epsilonEquals
public boolean epsilonEquals(Transform3D t1, double epsilon)(Code)
Returns true if the L-infinite distance between this matrix and matrix m1 is less than or equal to the epsilon parameter, otherwise returns false. The L-infinite distance is equal to MAX[i=0,1,2,3 ; j=0,1,2,3 ; abs[(this.m(i,j) - m1.m(i,j)]
Parameters:
  t1 - the transform to be compared to this transform
Parameters:
  epsilon - the threshold value



equals
public boolean equals(Transform3D t1)(Code)
Returns true if all of the data members of transform t1 are equal to the corresponding data members in this Transform3D.
Parameters:
  t1 - the transform with which the comparison is made true or false



equals
public boolean equals(Object o1)(Code)
Returns true if the Object o1 is of type Transform3D and all of the data members of o1 are equal to the corresponding data members in this Transform3D.
Parameters:
  o1 - the object with which the comparison is made. true or false



frustum
public void frustum(double left, double right, double bottom, double top, double near, double far)(Code)
Creates a perspective projection transform that mimics a standard, camera-based, view-model. This transform maps coordinates from Eye Coordinates (EC) to Clipping Coordinates (CC). Note that unlike the similar function in OpenGL, the clipping coordinates generated by the resulting transform are in a right-handed coordinate system (as are all other coordinate systems in Java 3D).

The frustum function-call establishes a view model with the eye at the apex of a symmetric view frustum. The arguments define the frustum and its associated perspective projection: (left, bottom, -near) and (right, top, -near) specify the point on the near clipping plane that maps onto the lower-left and upper-right corners of the window respectively, assuming the eye is located at (0, 0, 0).
Parameters:
  left - the vertical line on the left edge of the nearclipping plane mapped to the left edge of the graphics window
Parameters:
  right - the vertical line on the right edge of the nearclipping plane mapped to the right edge of the graphics window
Parameters:
  bottom - the horizontal line on the bottom edge of the nearclipping plane mapped to the bottom edge of the graphics window
Parameters:
  top - the horizontal line on the top edge of the near
Parameters:
  near - the distance to the frustum's near clipping plane.This value must be positive, (the value -near is the location of thenear clip plane).
Parameters:
  far - the distance to the frustum's far clipping plane.This value must be positive, and must be greater than near.




get
final public void get(double[] matrix)(Code)
Places the values of this transform into the double precision array of length 16. The first four elements of the array will contain the top row of the transform matrix, etc.
Parameters:
  matrix - the double precision array of length 16



get
final public void get(float[] matrix)(Code)
Places the values of this transform into the single precision array of length 16. The first four elements of the array will contain the top row of the transform matrix, etc.
Parameters:
  matrix - the single precision array of length 16



get
final public void get(Matrix3d m1)(Code)
Places the normalized rotational component of this transform into the 3x3 matrix argument.
Parameters:
  m1 - the matrix into which the rotational component is placed



get
final public void get(Matrix3f m1)(Code)
Places the normalized rotational component of this transform into the 3x3 matrix argument.
Parameters:
  m1 - the matrix into which the rotational component is placed



get
final public void get(Quat4f q1)(Code)
Places the quaternion equivalent of the normalized rotational component of this transform into the quaternion parameter.
Parameters:
  q1 - the quaternion into which the rotation component is placed



get
final public void get(Quat4d q1)(Code)
Places the quaternion equivalent of the normalized rotational component of this transform into the quaternion parameter.
Parameters:
  q1 - the quaternion into which the rotation component is placed



get
final public void get(Matrix4d matrix)(Code)
Places the values of this transform into the double precision matrix argument.
Parameters:
  matrix - the double precision matrix



get
final public void get(Matrix4f matrix)(Code)
Places the values of this transform into the single precision matrix argument.
Parameters:
  matrix - the single precision matrix



get
final public double get(Quat4d q1, Vector3d t1)(Code)
Places the quaternion equivalent of the normalized rotational component of this transform into the quaternion parameter; places the translational component into the Vector parameter.
Parameters:
  q1 - the quaternion representing the rotation
Parameters:
  t1 - the translation component the scale component of this transform



get
final public float get(Quat4f q1, Vector3f t1)(Code)
Places the quaternion equivalent of the normalized rotational component of this transform into the quaternion parameter; places the translational component into the Vector parameter.
Parameters:
  q1 - the quaternion representing the rotation
Parameters:
  t1 - the translation component the scale component of this transform



get
final public double get(Quat4f q1, Vector3d t1)(Code)
Places the quaternion equivalent of the normalized rotational component of this transform into the quaternion parameter; places the translational component into the Vector parameter.
Parameters:
  q1 - the quaternion representing the rotation
Parameters:
  t1 - the translation component the scale component of this transform



get
final public double get(Matrix3d m1, Vector3d t1)(Code)
Places the normalized rotational component of this transform into the matrix parameter; place the translational component into the vector parameter.
Parameters:
  m1 - the normalized matrix representing the rotation
Parameters:
  t1 - the translation component the scale component of this transform



get
final public float get(Matrix3f m1, Vector3f t1)(Code)
Places the normalized rotational component of this transform into the matrix parameter; place the translational component into the vector parameter.
Parameters:
  m1 - the normalized matrix representing the rotation
Parameters:
  t1 - the translation component the scale component of this transform



get
final public double get(Matrix3f m1, Vector3d t1)(Code)
Places the normalized rotational component of this transform into the matrix parameter; place the translational component into the vector parameter.
Parameters:
  m1 - the normalized matrix representing the rotation
Parameters:
  t1 - the translation component the scale component of this transform



get
final public void get(Vector3f trans)(Code)
Retrieves the translational components of this transform.
Parameters:
  trans - the vector that will receive the translational component



get
final public void get(Vector3d trans)(Code)
Retrieves the translational components of this transform.
Parameters:
  trans - the vector that will receive the translational component



getAutoNormalize
final public boolean getAutoNormalize()(Code)
Returns the state of auto-normalization. boolean state of auto-normalization



getBestType
final public int getBestType()(Code)
Returns the least general type of this matrix; the order of generality from least to most is: ZERO, IDENTITY, SCALE/TRANSLATION, ORTHOGONAL, RIGID, CONGRUENT, AFFINE. If the matrix is ORTHOGONAL, calling the method getDeterminantSign() will yield more information. the least general matrix type



getDeterminantSign
final public boolean getDeterminantSign()(Code)
Returns the sign of the determinant of this matrix; a return value of true indicates a non-negative determinant; a return value of false indicates a negative determinant. A value of true will be returned if the determinant is NaN. In general, an orthogonal matrix with a positive determinant is a pure rotation matrix; an orthogonal matrix with a negative determinant is a both a rotation and a reflection matrix. determinant sign : true means non-negative, false means negative



getDistanceScale
double getDistanceScale()(Code)
get the scaling factor of matrix in this transform, use for distance scaling



getRotation
final void getRotation(Transform3D t)(Code)



getRotationScale
final public void getRotationScale(Matrix3f m1)(Code)
Gets the upper 3x3 values of this matrix and places them into the matrix m1.
Parameters:
  m1 - the matrix that will hold the values



getRotationScale
final public void getRotationScale(Matrix3d m1)(Code)
Gets the upper 3x3 values of this matrix and places them into the matrix m1.
Parameters:
  m1 - the matrix that will hold the values



getScale
final public double getScale()(Code)
Returns the uniform scale factor of this matrix. If the matrix has non-uniform scale factors, the largest of the x, y, and z scale factors will be returned. the scale factor of this matrix



getScale
final public void getScale(Vector3d scale)(Code)
Gets the possibly non-uniform scale components of the current transform and places them into the scale vector.
Parameters:
  scale - the vector into which the x,y,z scale values will be placed



getType
final public int getType()(Code)
Returns the type of this matrix as an or'ed bitmask of of all of the type classifications to which it belongs. or'ed bitmask of all of the type classificationsof this transform



getWithLock
synchronized void getWithLock(Transform3D t1)(Code)



hashCode
public int hashCode()(Code)
Returns a hash code value based on the data values in this object. Two different Transform3D objects with identical data values (i.e., Transform3D.equals returns true) will return the same hash number. Two Transform3D objects with different data members may return the same hash value, although this is not likely. the integer hash code value



invert
final public void invert(Transform3D t1)(Code)
Sets the value of this transform to the inverse of the passed Transform3D parameter. This method uses the transform type to determine the optimal algorithm for inverting transform t1.
Parameters:
  t1 - the transform to be inverted
exception:
  SingularMatrixException - thrown if transform t1 isnot invertible



invert
final public void invert()(Code)
Inverts this transform in place. This method uses the transform type to determine the optimal algorithm for inverting this transform.
exception:
  SingularMatrixException - thrown if this transform isnot invertible



invertAffine
final void invertAffine(Transform3D t1)(Code)
Affine invert routine. Inverts t1 and places the result in "this".



invertAffine
final void invertAffine()(Code)
Affine invert routine. Inverts "this" matrix in place.



invertGeneral
final void invertGeneral(Transform3D t1)(Code)
General invert routine. Inverts t1 and places the result in "this". Note that this routine handles both the "this" version and the non-"this" version. Also note that since this routine is slow anyway, we won't worry about allocating a little bit of garbage.



isAffine
final boolean isAffine()(Code)



isCongruent
final boolean isCongruent()(Code)



isOrtho
final boolean isOrtho()(Code)



isRigid
final boolean isRigid()(Code)



lookAt
public void lookAt(Point3d eye, Point3d center, Vector3d up)(Code)
Helping function that specifies the position and orientation of a view matrix. The inverse of this transform can be used to control the ViewPlatform object within the scene graph.
Parameters:
  eye - the location of the eye
Parameters:
  center - a point in the virtual world where the eye is looking
Parameters:
  up - an up vector specifying the frustum's up direction



luBacksubstitution
static void luBacksubstitution(double[] matrix1, int[] row_perm, double[] matrix2)(Code)
Solves a set of linear equations. The input parameters "matrix1", and "row_perm" come from luDecompostionD4x4 and do not change here. The parameter "matrix2" is a set of column vectors assembled into a 4x4 matrix of floating-point values. The procedure takes each column of "matrix2" in turn and treats it as the right-hand side of the matrix equation Ax = LUx = b. The solution vector replaces the original column of the matrix. If "matrix2" is the identity matrix, the procedure replaces its contents with the inverse of the matrix from which "matrix1" was originally derived.



luDecomposition
static boolean luDecomposition(double[] matrix0, int[] row_perm)(Code)
Given a 4x4 array "matrix0", this function replaces it with the LU decomposition of a row-wise permutation of itself. The input parameters are "matrix0" and "dimen". The array "matrix0" is also an output parameter. The vector "row_perm[4]" is an output parameter that contains the row permutations resulting from partial pivoting. The output parameter "even_row_xchg" is 1 when the number of row exchanges is even, or -1 otherwise. Assumes data type is always double. This function is similar to luDecomposition, except that it is tuned specifically for 4x4 matrices. true if the matrix is nonsingular, or false otherwise.



max
final static double max(double a, double b)(Code)



min
final static double min(double a, double b)(Code)



mul
final public void mul(double scalar)(Code)
Multiplies each element of this transform by a scalar.
Parameters:
  scalar - the scalar multiplier



mul
final public void mul(double scalar, Transform3D t1)(Code)
Multiplies each element of transform t1 by a scalar and places the result into this. Transform t1 is not modified.
Parameters:
  scalar - the scalar multiplier
Parameters:
  t1 - the original transform



mul
final public void mul(Transform3D t1)(Code)
Sets the value of this transform to the result of multiplying itself with transform t1 (this = this * t1).
Parameters:
  t1 - the other transform



mul
final public void mul(Transform3D t1, Transform3D t2)(Code)
Sets the value of this transform to the result of multiplying transform t1 by transform t2 (this = t1*t2).
Parameters:
  t1 - the left transform
Parameters:
  t2 - the right transform



mulInverse
final public void mulInverse(Transform3D t1)(Code)
Multiplies this transform by the inverse of transform t1. The final value is placed into this matrix (this = this*t1^-1).
Parameters:
  t1 - the matrix whose inverse is computed.



mulInverse
final public void mulInverse(Transform3D t1, Transform3D t2)(Code)
Multiplies transform t1 by the inverse of transform t2. The final value is placed into this matrix (this = t1*t2^-1).
Parameters:
  t1 - the left transform in the multiplication
Parameters:
  t2 - the transform whose inverse is computed.



mulTransposeBoth
final public void mulTransposeBoth(Transform3D t1, Transform3D t2)(Code)
Multiplies the transpose of transform t1 by the transpose of transform t2 and places the result into this transform (this = transpose(t1) * transpose(t2)).
Parameters:
  t1 - the transform on the left hand side of the multiplication
Parameters:
  t2 - the transform on the right hand side of the multiplication



mulTransposeLeft
final public void mulTransposeLeft(Transform3D t1, Transform3D t2)(Code)
Multiplies the transpose of transform t1 by transform t2 and places the result into this matrix (this = transpose(t1) * t2).
Parameters:
  t1 - the transform whose transpose is computed
Parameters:
  t2 - the transform on the right hand side of the multiplication



mulTransposeRight
final public void mulTransposeRight(Transform3D t1, Transform3D t2)(Code)
Multiplies transform t1 by the transpose of transform t2 and places the result into this transform (this = t1 * transpose(t2)).
Parameters:
  t1 - the transform on the left hand side of the multiplication
Parameters:
  t2 - the transform whose transpose is computed



normalize
final public void normalize()(Code)
Normalizes the rotational components (upper 3x3) of this matrix in place using a Singular Value Decomposition (SVD). This operation ensures that the column vectors of this matrix are orthogonal to each other. The primary use of this method is to correct for floating point errors that accumulate over time when concatenating a large number of rotation matrices. Note that the scale of the matrix is not altered by this method.



normalize
final public void normalize(Transform3D t1)(Code)
Normalizes the rotational components (upper 3x3) of transform t1 using a Singular Value Decomposition (SVD), and places the result into this transform. This operation ensures that the column vectors of this matrix are orthogonal to each other. The primary use of this method is to correct for floating point errors that accumulate over time when concatenating a large number of rotation matrices. Note that the scale of the matrix is not altered by this method.
Parameters:
  t1 - the source transform, which is not modified



normalizeCP
final public void normalizeCP()(Code)
Normalizes the rotational components (upper 3x3) of this transform in place using a Cross Product (CP) normalization. This operation ensures that the column vectors of this matrix are orthogonal to each other. The primary use of this method is to correct for floating point errors that accumulate over time when concatenating a large number of rotation matrices. Note that the scale of the matrix is not altered by this method.



normalizeCP
final public void normalizeCP(Transform3D t1)(Code)
Normalizes the rotational components (upper 3x3) of transform t1 using a Cross Product (CP) normalization, and places the result into this transform. This operation ensures that the column vectors of this matrix are orthogonal to each other. The primary use of this method is to correct for floating point errors that accumulate over time when concatenating a large number of rotation matrices. Note that the scale of the matrix is not altered by this method.
Parameters:
  t1 - the transform to be normalized



ortho
public void ortho(double left, double right, double bottom, double top, double near, double far)(Code)
Creates an orthographic projection transform that mimics a standard, camera-based, view-model. This transform maps coordinates from Eye Coordinates (EC) to Clipping Coordinates (CC). Note that unlike the similar function in OpenGL, the clipping coordinates generated by the resulting transform are in a right-handed coordinate system (as are all other coordinate systems in Java 3D).
Parameters:
  left - the vertical line on the left edge of the nearclipping plane mapped to the left edge of the graphics window
Parameters:
  right - the vertical line on the right edge of the nearclipping plane mapped to the right edge of the graphics window
Parameters:
  bottom - the horizontal line on the bottom edge of the nearclipping plane mapped to the bottom edge of the graphics window
Parameters:
  top - the horizontal line on the top edge of the nearclipping plane mapped to the top edge of the graphics window
Parameters:
  near - the distance to the frustum's near clipping plane(the value -near is the location of the near clip plane)
Parameters:
  far - the distance to the frustum's far clipping plane



perspective
public void perspective(double fovx, double aspect, double zNear, double zFar)(Code)
Creates a perspective projection transform that mimics a standard, camera-based, view-model. This transform maps coordinates from Eye Coordinates (EC) to Clipping Coordinates (CC). Note that unlike the similar function in OpenGL, the clipping coordinates generated by the resulting transform are in a right-handed coordinate system (as are all other coordinate systems in Java 3D). Also note that the field of view is specified in radians.
Parameters:
  fovx - specifies the field of view in the x direction, in radians
Parameters:
  aspect - specifies the aspect ratio and thus the field ofview in the x direction. The aspect ratio is the ratio of x to y,or width to height.
Parameters:
  zNear - the distance to the frustum's near clipping plane.This value must be positive, (the value -zNear is the location of thenear clip plane).
Parameters:
  zFar - the distance to the frustum's far clipping plane



rotX
public void rotX(double angle)(Code)
Sets the value of this transform to a counter clockwise rotation about the x axis. All of the non-rotational components are set as if this were an identity matrix.
Parameters:
  angle - the angle to rotate about the X axis in radians



rotY
public void rotY(double angle)(Code)
Sets the value of this transform to a counter clockwise rotation about the y axis. All of the non-rotational components are set as if this were an identity matrix.
Parameters:
  angle - the angle to rotate about the Y axis in radians



rotZ
public void rotZ(double angle)(Code)
Sets the value of this transform to a counter clockwise rotation about the z axis. All of the non-rotational components are set as if this were an identity matrix.
Parameters:
  angle - the angle to rotate about the Z axis in radians



rotateZero
final boolean rotateZero()(Code)



scaleAdd
final public void scaleAdd(double s, Transform3D t1, Transform3D t2)(Code)
Scales transform t1 by a Uniform scale matrix with scale factor s and then adds transform t2 (this = S*t1 + t2).
Parameters:
  s - the scale factor
Parameters:
  t1 - the transform to be scaled
Parameters:
  t2 - the transform to be added



scaleAdd
final public void scaleAdd(double s, Transform3D t1)(Code)
Scales this transform by a Uniform scale matrix with scale factor s and then adds transform t1 (this = S*this + t1).
Parameters:
  s - the scale factor
Parameters:
  t1 - the transform to be added



set
final public void set(Quat4f q1)(Code)
Sets the value of this transform to the matrix conversion of the single precision quaternion argument; the non-rotational components are set as if this were an identity matrix.
Parameters:
  q1 - the quaternion to be converted



set
final public void set(Quat4d q1)(Code)
Sets the value of this transform to the matrix conversion of the double precision quaternion argument; the non-rotational components are set as if this were an identity matrix.
Parameters:
  q1 - the quaternion to be converted



set
final public void set(AxisAngle4f a1)(Code)
Sets the value of this transform to the matrix conversion of the single precision axis-angle argument; all of the matrix values are modified.
Parameters:
  a1 - the axis-angle to be converted (x, y, z, angle)



set
final public void set(AxisAngle4d a1)(Code)
Sets the value of this transform to the matrix conversion of the double precision axis-angle argument; all of the matrix values are modified.
Parameters:
  a1 - the axis-angle to be converted (x, y, z, angle)



set
final public void set(Vector3f trans)(Code)
Sets the translational value of this matrix to the Vector3f parameter values, and sets the other components of the matrix as if this transform were an identity matrix.
Parameters:
  trans - the translational component



set
final public void set(Vector3d trans)(Code)
Sets the translational value of this matrix to the Vector3d paramter values, and sets the other components of the matrix as if this transform were an identity matrix.
Parameters:
  trans - the translational component



set
final public void set(Quat4d q1, Vector3d t1, double s)(Code)
Sets the value of this matrix from the rotation expressed by the quaternion q1, the translation t1, and the scale s.
Parameters:
  q1 - the rotation expressed as a quaternion
Parameters:
  t1 - the translation
Parameters:
  s - the scale value



set
final public void set(Quat4f q1, Vector3d t1, double s)(Code)
Sets the value of this matrix from the rotation expressed by the quaternion q1, the translation t1, and the scale s.
Parameters:
  q1 - the rotation expressed as a quaternion
Parameters:
  t1 - the translation
Parameters:
  s - the scale value



set
final public void set(Quat4f q1, Vector3f t1, float s)(Code)
Sets the value of this matrix from the rotation expressed by the quaternion q1, the translation t1, and the scale s.
Parameters:
  q1 - the rotation expressed as a quaternion
Parameters:
  t1 - the translation
Parameters:
  s - the scale value



set
final public void set(Matrix3f m1, Vector3f t1, float s)(Code)
Sets the value of this matrix from the rotation expressed by the rotation matrix m1, the translation t1, and the scale s. The scale is only applied to the rotational component of the matrix (upper 3x3) and not to the translational component of the matrix.
Parameters:
  m1 - the rotation matrix
Parameters:
  t1 - the translation
Parameters:
  s - the scale value



set
final public void set(Matrix3f m1, Vector3d t1, double s)(Code)
Sets the value of this matrix from the rotation expressed by the rotation matrix m1, the translation t1, and the scale s. The scale is only applied to the rotational component of the matrix (upper 3x3) and not to the translational component of the matrix.
Parameters:
  m1 - the rotation matrix
Parameters:
  t1 - the translation
Parameters:
  s - the scale value



set
final public void set(Matrix3d m1, Vector3d t1, double s)(Code)
Sets the value of this matrix from the rotation expressed by the rotation matrix m1, the translation t1, and the scale s. The scale is only applied to the rotational component of the matrix (upper 3x3) and not to the translational component of the matrix.
Parameters:
  m1 - the rotation matrix
Parameters:
  t1 - the translation
Parameters:
  s - the scale value



set
final public void set(GMatrix matrix)(Code)
Sets the matrix values of this transform to the matrix values in the upper 4x4 corner of the GMatrix parameter. If the parameter matrix is smaller than 4x4, the remaining elements in the transform matrix are assigned to zero. The transform matrix type is classified internally by the Transform3D class.
Parameters:
  matrix - the general matrix from which the Transform3D matrix is derived



set
final public void set(Transform3D t1)(Code)
Sets the matrix, type, and state of this transform to the matrix, type, and state of transform t1.
Parameters:
  t1 - the transform to be copied



set
final public void set(double[] matrix)(Code)
Sets the matrix values of this transform to the matrix values in the double precision array parameter. The matrix type is classified internally by the Transform3D class.
Parameters:
  matrix - the double precision array of length 16 in row major format



set
final public void set(float[] matrix)(Code)
Sets the matrix values of this transform to the matrix values in the single precision array parameter. The matrix type is classified internally by the Transform3D class.
Parameters:
  matrix - the single precision array of length 16 in row major format



set
final public void set(Matrix4d m1)(Code)
Sets the matrix values of this transform to the matrix values in the double precision Matrix4d argument. The transform type is classified internally by the Transform3D class.
Parameters:
  m1 - the double precision 4x4 matrix



set
final public void set(Matrix4f m1)(Code)
Sets the matrix values of this transform to the matrix values in the single precision Matrix4f argument. The transform type is classified internally by the Transform3D class.
Parameters:
  m1 - the single precision 4x4 matrix



set
final public void set(Matrix3f m1)(Code)
Sets the rotational component (upper 3x3) of this transform to the matrix values in the single precision Matrix3f argument; the other elements of this transform are initialized as if this were an identity matrix (i.e., affine matrix with no translational component).
Parameters:
  m1 - the single precision 3x3 matrix



set
final public void set(Matrix3d m1)(Code)
Sets the rotational component (upper 3x3) of this transform to the matrix values in the double precision Matrix3d argument; the other elements of this transform are initialized as if this were an identity matrix (ie, affine matrix with no translational component).
Parameters:
  m1 - the double precision 3x3 matrix



set
final public void set(double scale)(Code)
Sets the value of this transform to a uniform scale; all of the matrix values are modified.
Parameters:
  scale - the scale factor for the transform



set
final public void set(double scale, Vector3d v1)(Code)
Sets the value of this transform to a scale and translation matrix; the scale is not applied to the translation and all of the matrix values are modified.
Parameters:
  scale - the scale factor for the transform
Parameters:
  v1 - the translation amount



set
final public void set(float scale, Vector3f v1)(Code)
Sets the value of this transform to a scale and translation matrix; the scale is not applied to the translation and all of the matrix values are modified.
Parameters:
  scale - the scale factor for the transform
Parameters:
  v1 - the translation amount



set
final public void set(Vector3d v1, double scale)(Code)
Sets the value of this transform to a scale and translation matrix; the translation is scaled by the scale factor and all of the matrix values are modified.
Parameters:
  v1 - the translation amount
Parameters:
  scale - the scale factor for the transform AND the translation



set
final public void set(Vector3f v1, float scale)(Code)
Sets the value of this transform to a scale and translation matrix; the translation is scaled by the scale factor and all of the matrix values are modified.
Parameters:
  v1 - the translation amount
Parameters:
  scale - the scale factor for the transform AND the translation



setAutoNormalize
final public void setAutoNormalize(boolean autoNormalize)(Code)
Sets a flag that enables or disables automatic SVD normalization. If this flag is enabled, an automatic SVD normalization of the rotational components (upper 3x3) of this matrix is done after every subsequent matrix operation that modifies this matrix. This is functionally equivalent to calling normalize() after every subsequent call, but may be less computationally expensive. The default value for this parameter is false.
Parameters:
  autoNormalize - the boolean state of auto normalization



setEuler
final public void setEuler(Vector3d euler)(Code)
Sets the rotational component (upper 3x3) of this transform to the rotation matrix converted from the Euler angles provided; the other non-rotational elements are set as if this were an identity matrix. The euler parameter is a Vector3d consisting of three rotation angles applied first about the X, then Y then Z axis. These rotations are applied using a static frame of reference. In other words, the orientation of the Y rotation axis is not affected by the X rotation and the orientation of the Z rotation axis is not affected by the X or Y rotation.
Parameters:
  euler - the Vector3d consisting of three rotation angles about X,Y,Z



setIdentity
final public void setIdentity()(Code)
Sets this transform to the identity matrix.



setNonUniformScale
final public void setNonUniformScale(double xScale, double yScale, double zScale)(Code)
Replaces the current transform with a non-uniform scale transform. All values of the existing transform are replaced.
Parameters:
  xScale - the new X scale amount
Parameters:
  yScale - the new Y scale amount
Parameters:
  zScale - the new Z scale amount



setOrthoDirtyBit
final void setOrthoDirtyBit()(Code)



setRotation
final public void setRotation(Matrix3d m1)(Code)
Sets the rotational component (upper 3x3) of this transform to the matrix values in the double precision Matrix3d argument; the other elements of this transform are unchanged; any pre-existing scale will be preserved; the argument matrix m1 will be checked for proper normalization when this transform is internally classified.
Parameters:
  m1 - the double precision 3x3 matrix



setRotation
final public void setRotation(Matrix3f m1)(Code)
Sets the rotational component (upper 3x3) of this transform to the matrix values in the single precision Matrix3f argument; the other elements of this transform are unchanged; any pre-existing scale will be preserved; the argument matrix m1 will be checked for proper normalization when this transform is internally classified.
Parameters:
  m1 - the single precision 3x3 matrix



setRotation
final public void setRotation(Quat4f q1)(Code)
Sets the rotational component (upper 3x3) of this transform to the matrix equivalent values of the quaternion argument; the other elements of this transform are unchanged; any pre-existing scale in the transform is preserved.
Parameters:
  q1 - the quaternion that specifies the rotation



setRotation
final public void setRotation(Quat4d q1)(Code)
Sets the rotational component (upper 3x3) of this transform to the matrix equivalent values of the quaternion argument; the other elements of this transform are unchanged; any pre-existing scale in the transform is preserved.
Parameters:
  q1 - the quaternion that specifies the rotation



setRotation
final public void setRotation(AxisAngle4d a1)(Code)
Sets the rotational component (upper 3x3) of this transform to the matrix equivalent values of the axis-angle argument; the other elements of this transform are unchanged; any pre-existing scale in the transform is preserved.
Parameters:
  a1 - the axis-angle to be converted (x, y, z, angle)



setRotation
final public void setRotation(AxisAngle4f a1)(Code)
Sets the rotational component (upper 3x3) of this transform to the matrix equivalent values of the axis-angle argument; the other elements of this transform are unchanged; any pre-existing scale in the transform is preserved.
Parameters:
  a1 - the axis-angle to be converted (x, y, z, angle)



setRotationScale
final public void setRotationScale(Matrix3f m1)(Code)
Replaces the upper 3x3 matrix values of this transform with the values in the matrix m1.
Parameters:
  m1 - the matrix that will be the new upper 3x3



setRotationScale
final public void setRotationScale(Matrix3d m1)(Code)
Replaces the upper 3x3 matrix values of this transform with the values in the matrix m1.
Parameters:
  m1 - the matrix that will be the new upper 3x3



setScale
final public void setScale(double scale)(Code)
Sets the scale component of the current transform; any existing scale is first factored out of the existing transform before the new scale is applied.
Parameters:
  scale - the new scale amount



setScale
final public void setScale(Vector3d scale)(Code)
Sets the possibly non-uniform scale component of the current transform; any existing scale is first factored out of the existing transform before the new scale is applied.
Parameters:
  scale - the new x,y,z scale values



setTranslation
final public void setTranslation(Vector3f trans)(Code)
Replaces the translational components of this transform to the values in the Vector3f argument; the other values of this transform are not modified.
Parameters:
  trans - the translational component



setTranslation
final public void setTranslation(Vector3d trans)(Code)
Replaces the translational components of this transform to the values in the Vector3d argument; the other values of this transform are not modified.
Parameters:
  trans - the translational component



setWithLock
synchronized void setWithLock(Transform3D t1)(Code)



setZero
final public void setZero()(Code)
Sets this transform to all zeros.



sub
final public void sub(Transform3D t1)(Code)
Subtracts transform t1 from this transform and places the result into this: this = this - t1.
Parameters:
  t1 - the transform to be subtracted from this transform



sub
final public void sub(Transform3D t1, Transform3D t2)(Code)
Subtracts transform t2 from transform t1 and places the result into this: this = t1 - t2.
Parameters:
  t1 - the left transform
Parameters:
  t2 - the right transform



toString
public String toString()(Code)
Returns the matrix elements of this transform as a string. the matrix elements of this transform



transform
void transform(Point3d point, Point4d pointOut)(Code)
Transforms the point parameter with this transform and places the result into pointOut. The fourth element of the point input paramter is assumed to be one.
Parameters:
  point - the input point to be transformed
Parameters:
  pointOut - the transformed point



transform
final public void transform(Vector4d vec, Vector4d vecOut)(Code)
Transform the vector vec using this transform and place the result into vecOut.
Parameters:
  vec - the double precision vector to be transformed
Parameters:
  vecOut - the vector into which the transformed values are placed



transform
final public void transform(Vector4d vec)(Code)
Transform the vector vec using this Transform and place the result back into vec.
Parameters:
  vec - the double precision vector to be transformed



transform
final public void transform(Vector4f vec, Vector4f vecOut)(Code)
Transform the vector vec using this Transform and place the result into vecOut.
Parameters:
  vec - the single precision vector to be transformed
Parameters:
  vecOut - the vector into which the transformed values are placed



transform
final public void transform(Vector4f vec)(Code)
Transform the vector vec using this Transform and place the result back into vec.
Parameters:
  vec - the single precision vector to be transformed



transform
final public void transform(Point3d point, Point3d pointOut)(Code)
Transforms the point parameter with this transform and places the result into pointOut. The fourth element of the point input paramter is assumed to be one.
Parameters:
  point - the input point to be transformed
Parameters:
  pointOut - the transformed point



transform
final public void transform(Point3d point)(Code)
Transforms the point parameter with this transform and places the result back into point. The fourth element of the point input paramter is assumed to be one.
Parameters:
  point - the input point to be transformed



transform
final public void transform(Vector3d normal, Vector3d normalOut)(Code)
Transforms the normal parameter by this transform and places the value into normalOut. The fourth element of the normal is assumed to be zero.
Parameters:
  normal - the input normal to be transformed
Parameters:
  normalOut - the transformed normal



transform
final public void transform(Vector3d normal)(Code)
Transforms the normal parameter by this transform and places the value back into normal. The fourth element of the normal is assumed to be zero.
Parameters:
  normal - the input normal to be transformed



transform
final public void transform(Point3f point, Point3f pointOut)(Code)
Transforms the point parameter with this transform and places the result into pointOut. The fourth element of the point input paramter is assumed to be one.
Parameters:
  point - the input point to be transformed
Parameters:
  pointOut - the transformed point



transform
final public void transform(Point3f point)(Code)
Transforms the point parameter with this transform and places the result back into point. The fourth element of the point input paramter is assumed to be one.
Parameters:
  point - the input point to be transformed



transform
final public void transform(Vector3f normal, Vector3f normalOut)(Code)
Transforms the normal parameter by this transform and places the value into normalOut. The fourth element of the normal is assumed to be zero. Note: For correct lighting results, if a transform has uneven scaling surface normals should transformed by the inverse transpose of the transform. This the responsibility of the application and is not done automatically by this method.
Parameters:
  normal - the input normal to be transformed
Parameters:
  normalOut - the transformed normal



transform
final public void transform(Vector3f normal)(Code)
Transforms the normal parameter by this transform and places the value back into normal. The fourth element of the normal is assumed to be zero. Note: For correct lighting results, if a transform has uneven scaling surface normals should transformed by the inverse transpose of the transform. This the responsibility of the application and is not done automatically by this method.
Parameters:
  normal - the input normal to be transformed



transpose
final public void transpose()(Code)
Transposes this matrix in place.



transpose
final public void transpose(Transform3D t1)(Code)
Transposes transform t1 and places the value into this transform. The transform t1 is not modified.
Parameters:
  t1 - the transform whose transpose is placed into this transform



zeroTranslation
final boolean zeroTranslation()(Code)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.