Class Index | File Index

Classes


Class threedee.Frustum

A frustum.
Defined in: Frustum.js.

Class Summary
Constructor Attributes Constructor Name and Description
 
threedee.Frustum(width, height, scale, far, near)
Constructs a new view frustum for the specified screen size and scale factor.
Method Summary
Method Attributes Method Name and Description
 
clipPolygon(polygon)
Clips the specified polygon.
Class Detail
threedee.Frustum(width, height, scale, far, near)
Constructs a new view frustum for the specified screen size and scale factor. Optionaly you can specify the near and far clipping distance.
Parameters:
{number} width
The screen width in pixels
{number} height
The screen height in pixels
{number} scale
The scale factor. This is the factor you multiply the X and Y coordinates with before dividing them by the Z coordinate to project the 3D coordinates to 2D coordinates
{number=} far
The optional far clipping distance. Defaults to null which means no far clipping is performed.
{number=} near
The optional near clipping distance. Defaults to 10
Method Detail
{boolean} clipPolygon(polygon)
Clips the specified polygon. Returns false if polygon was completely clipped away and true if it is still visible.
Parameters:
{threedee.RenderPolygon} polygon
The polygon to clip.
Returns:
{boolean} False if polygon is still visible, true if it was completely clipped away.

Documentation generated by JsDoc Toolkit 2.4.0 on Tue Jan 03 2012 16:18:57 GMT+0100 (CET)