Aviatrix3D
2.0 Beta 2

org.j3d.aviatrix3d.rendering
Interface ViewEnvironmentCullable

All Superinterfaces:
Cullable
All Known Implementing Classes:
ViewEnvironment

public interface ViewEnvironmentCullable
extends Cullable

A cullable that represents a single visual composited layer.

A layer has zero or more viewports to process.

Version:
$Revision: 2.2 $
Author:
Justin Couch

Field Summary
static int ORTHOGRAPHIC_PROJECTION
          The projection type is perspective mode
static int PERSPECTIVE_PROJECTION
          The projection type is perspective mode
static int VIEW_HEIGHT
          Index into the viewport size array for the height
static int VIEW_WIDTH
          Index into the viewport size array for the width
static int VIEW_X
          Index into the viewport size array for the X position
static int VIEW_Y
          Index into the viewport size array for the Y position
 
Method Summary
 double getFieldOfView()
          Get the currently set field of view.
 int getProjectionType()
          Get the type of view environment defined.
 void getViewFrustum(double[] frustum)
          Get the frustum based on the projectionType.
 int[] getViewportDimensions()
          Get the currently set dimensions of the viewport.
 boolean isStereoEnabled()
          Check to see if stereo has been enabled for this environment.
 

Field Detail

PERSPECTIVE_PROJECTION

public static final int PERSPECTIVE_PROJECTION
The projection type is perspective mode

See Also:
Constant Field Values

ORTHOGRAPHIC_PROJECTION

public static final int ORTHOGRAPHIC_PROJECTION
The projection type is perspective mode

See Also:
Constant Field Values

VIEW_X

public static final int VIEW_X
Index into the viewport size array for the X position

See Also:
Constant Field Values

VIEW_Y

public static final int VIEW_Y
Index into the viewport size array for the Y position

See Also:
Constant Field Values

VIEW_WIDTH

public static final int VIEW_WIDTH
Index into the viewport size array for the width

See Also:
Constant Field Values

VIEW_HEIGHT

public static final int VIEW_HEIGHT
Index into the viewport size array for the height

See Also:
Constant Field Values
Method Detail

isStereoEnabled

public boolean isStereoEnabled()
Check to see if stereo has been enabled for this environment.

Returns:
true if stereo rendering is to be used

getProjectionType

public int getProjectionType()
Get the type of view environment defined.


getViewFrustum

public void getViewFrustum(double[] frustum)
Get the frustum based on the projectionType. Perspective used the current view setup of FoV, near and far clipping distances and the aspectRatio ratio, generate the 6 parameters that describe a view frustum. These parameters are what could be used as arguments to the glFrustum call. The parameter order for perspective is: [x min, x max, y min, y max, z near, z far] Orthographic uses the parameters specified in the setOrthoParams. The parameter order for orthographic: [left, right, bottom, top, near, far]

Parameters:
frustum - An array at least 6 in length for the values generated

getFieldOfView

public double getFieldOfView()
Get the currently set field of view. The field of view is specified in degrees.

Returns:
A value 0 <= x <= 180;

getViewportDimensions

public int[] getViewportDimensions()
Get the currently set dimensions of the viewport. This is automatically pushed down from the parent Viewport instance. The values are described as
viewport[0] = x
viewport[1] = y
viewport[2] = width
viewport[3] = height

Returns:
The current viewport size

Aviatrix3D
2.0 Beta 2

Latest Info from http://aviatrix3d.j3d.org/
Copyright © 2003 - 2006 j3d.org