Class Index | File Index

Classes


Class TransformStack

Represents a full stack for model, view and projection matrices (OpenGL-like).
Defined in: benchgl.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
Creates a new TransformStack.
Method Summary
Method Attributes Method Name and Description
 
Gets the current model matrix.
 
Gets the inverse of the current model matrix.
 
Gets the inverse of the transposed of the current model matrix.
 
Gets the transposed version of the current model matrix.
 
Gets the current modelView matrix.
 
Gets the inverse of the current modelView matrix.
 
Gets the inverse of the transposed of the current modelView matrix.
 
Gets the transposed version of the current modelView matrix.
 
Gets the normal matrix (aka the inverse transpose of the modelView matrix).
 
Gets the current projection matrix.
 
Gets the inverse of the current projection matrix.
 
Gets the inverse of the transposed of the current projection matrix.
 
Gets the transposed version of the current projection matrix.
 
Gets the current view matrix.
 
Gets the inverse of the current view matrix.
 
Gets the inverse of the transposed of the current view matrix.
 
Gets the transposed version of the current view matrix.
 
Loads the identity on the current stack.
 
lookAt(eye, direction, up)
Apply a lookAt transformation to the current stack.
 
Sets the current stack as the model stack.
 
multiply(The)
Multiply a matrix with the current stack.
 
perspective(fovy, aspect, near, far)
Apply a perspective transformation to the current stack.
 
Pops out the matrix on top of the current stack.
 
Sets the current stack as the projection stack.
 
Push the matrix on top of the current stack.
 
rotate(angle, x, y, z)
Apply a rotation to the current stack.
 
rotateXYZ(rx, ry, rz)
Apply a rotation around x, y and z axes to the current stack.
 
scale(x, y, z)
Apply a scale transformation to the current stack.
 
translate(x, y, z)
Apply a translation to the current stack.
 
view()
Sets the current stack as the view stack.
Class Detail
TransformStack()
Creates a new TransformStack.
Method Detail
{Matrix4} getModelMatrix()
Gets the current model matrix.
Returns:
{Matrix4} The current model matrix.

{Matrix4} getModelMatrixInverse()
Gets the inverse of the current model matrix.
Returns:
{Matrix4} The current model matrix inverted.

{Matrix4} getModelMatrixInverseTranspose()
Gets the inverse of the transposed of the current model matrix.
Returns:
{Matrix4} The current model matrix inverted transposed.

{Matrix4} getModelMatrixTranspose()
Gets the transposed version of the current model matrix.
Returns:
{Matrix4} The current model matrix transposed.

{Matrix4} getModelViewMatrix()
Gets the current modelView matrix.
Returns:
{Matrix4} The current projection matrix.

{Matrix4} getModelViewMatrixInverse()
Gets the inverse of the current modelView matrix.
Returns:
{Matrix4} The current modelView matrix inverted.

{Matrix4} getModelViewMatrixInverseTranspose()
Gets the inverse of the transposed of the current modelView matrix.
Returns:
{Matrix4} The current modelView matrix inverted transposed.

{Matrix4} getModelViewMatrixTranspose()
Gets the transposed version of the current modelView matrix.
Returns:
{Matrix4} The current modelView matrix transposed.

{Matrix4} getNormalMatrix()
Gets the normal matrix (aka the inverse transpose of the modelView matrix).
Returns:
{Matrix4} The current modelView matrix inverted transposed.

{Matrix4} getProjectionMatrix()
Gets the current projection matrix.
Returns:
{Matrix4} The current projection matrix.

{Matrix4} getProjectionMatrixInverse()
Gets the inverse of the current projection matrix.
Returns:
{Matrix4} The current projection matrix inverted.

{Matrix4} getProjectionMatrixInverseTranspose()
Gets the inverse of the transposed of the current projection matrix.
Returns:
{Matrix4} The current projection matrix inverted transposed.

{Matrix4} getProjectionMatrixTranspose()
Gets the transposed version of the current projection matrix.
Returns:
{Matrix4} The current projection matrix transposed.

{Matrix4} getViewMatrix()
Gets the current view matrix.
Returns:
{Matrix4} The current view matrix.

{Matrix4} getViewMatrixInverse()
Gets the inverse of the current view matrix.
Returns:
{Matrix4} The current view matrix inverted.

{Matrix4} getViewMatrixInverseTranspose()
Gets the inverse of the transposed of the current view matrix.
Returns:
{Matrix4} The current view matrix inverted transposed.

{Matrix4} getViewMatrixTranspose()
Gets the transposed version of the current view matrix.
Returns:
{Matrix4} The current view matrix transposed.

{TransformStack} loadIdentity()
Loads the identity on the current stack.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} lookAt(eye, direction, up)
Apply a lookAt transformation to the current stack.
Parameters:
{Vector3} eye
The eye vector.
{Vector3} direction
The direction vector.
{Vector3} up
The up vector.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} model()
Sets the current stack as the model stack.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} multiply(The)
Multiply a matrix with the current stack.
Parameters:
{Matrix4} The
matrix to multiply with.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} perspective(fovy, aspect, near, far)
Apply a perspective transformation to the current stack.
Parameters:
{Number} fovy
The vertical field of view angle.
{Number} aspect
The aspect ratio aka the horizontal field of view angle.
{Number} near
The near clipping plane.
{Number} far
The far clipping plane.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} popMatrix()
Pops out the matrix on top of the current stack.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} projection()
Sets the current stack as the projection stack.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} pushMatrix()
Push the matrix on top of the current stack.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} rotate(angle, x, y, z)
Apply a rotation to the current stack.
Parameters:
{Number} angle
The rotation angle.
{Number} x
The rotation axis x coordinate.
{Number} y
The rotation axis y coordinate.
{Number} z
The rotation axis z coordinate.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} rotateXYZ(rx, ry, rz)
Apply a rotation around x, y and z axes to the current stack.
Parameters:
{Number} rx
The rotation angle around X axis.
{Number} ry
The rotation angle around Y axis.
{Number} rz
The rotation angle around Z axis.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} scale(x, y, z)
Apply a scale transformation to the current stack.
Parameters:
{Number} x
The x scale factor.
{Number} y
The y scale factor.
{Number} z
The z scale factor.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} translate(x, y, z)
Apply a translation to the current stack.
Parameters:
{Number} x
The x translation factor.
{Number} y
The y translation factor.
{Number} z
The z translation factor.
Returns:
{TransformStack} Returns this TransformStack.

{TransformStack} view()
Sets the current stack as the view stack.
Returns:
{TransformStack} Returns this TransformStack.

Documentation generated by JsDoc Toolkit 2.4.0 on Thu May 19 2011 00:47:49 GMT+0200 (CEST)