Java Doc for View.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.View

View
public class View extends Object (Code)
The View object contains all parameters needed in rendering a three dimensional scene from one viewpoint. A view contains a list of Canvas3D objects that the view is rendered into. It exists outside of the scene graph, but attaches to a ViewPlatform leaf node object in the scene graph. It also contains a reference to a PhysicalBody and a PhysicalEnvironment object.

The View object is the main Java 3D object for controlling the Java 3D viewing model. All of the components that specify the view transform used to render to the 3D canvases are either contained in the View object or in objects that are referenced by the View object.

Java 3D allows applications to specify multiple simultaneously active View objects, each controlling its own set of canvases.

The Java 3D View object has several instance variables and methods, but most are calibration variables or user-helping functions. The viewing policies defined by the View object are described below.

Policies

The View object defines the following policies:

  • View policy - informs Java 3D whether it should generate the view using the head-tracked system of transformations or the head-mounted system of transformations. These policies are attached to the Java 3D View object. There are two view policies:
    • SCREEN_VIEW - specifies that Java 3D should compute a new viewpoint using the sequence of transforms appropriate to screen-based head-tracked display environments (fish-tank VR/portals/VR-desks). This is the default setting.
    • HMD_VIEW - specifies that Java 3D should compute a new viewpoint using the sequence of transforms appropriate to head mounted display environments. This policy is not available in compatibility mode (see the setCompatibilityModeEnable method description).
  • Projection policy - specifies whether Java 3D should generate a parallel projection or a perspective projection. This policy is attached to the Java 3D View object. There are two projection policies:
    • PARALLEL_PROJECTION - specifies that a parallel projection transform is computed.
    • PERSPECTIVE_PROJECTION - specifies that a perspective projection transform is computed. This is the default policy.
  • Screen scale policy - specifies where the screen scale comes from. There are two screen scale policies:
    • SCALE_SCREEN_SIZE - specifies that the scale is derived from the physical screen according to the following formula (this is the default mode):
      • screenScale = physicalScreenWidth / 2.0

    • SCALE_EXPLICIT - pecifies that the scale is taken directly from the user-provided screenScale attribute (see the setScreenScale method description).
  • Window resize policy - specifies how Java 3D modifies the view when users resize windows. When users resize or move windows, Java 3D can choose to think of the window as attached either to the physical world or to the virtual world. The window resize policy allows an application to specify how the view model will handle resizing requests. There are two window resize policies:
    • VIRTUAL_WORLD - implies that the original image remains the same size on the screen but the user sees more or less of the virtual world depending on whether the window grew or shrank in size.
    • PHYSICAL_WORLD - implies that the original image continues to fill the window in the same way using more or less pixels depending on whether the window grew or shrank in size.
  • Window movement policy - specifies what part of the virtual world Java 3D draws as a function of window placement on the screen. There are two window movement policies:
    • VIRTUAL_WORLD - implies that the image seen in the window changes as the position of the window shifts on the screen. (This mode acts as if the window were a window into the virtual world.)
    • PHYSICAL_WORLD - implies that the image seen in the window remains the same no matter where the user positions the window on the screen.
  • Window eyepoint policy - comes into effect in a non-head-tracked environment. The policy tells Java 3D how to construct a new view frustum based on changes in the field of view and in the Canvas3D's location on the screen. The policy only comes into effect when the application changes a parameter that can change the placement of the eyepoint relative to the view frustum. There are three window eyepoint policies:
    • RELATIVE_TO_SCREEN - tells Java 3D to interpret the eye's position relative to the entire screen. No matter where an end user moves a window (a Canvas3D), Java 3D continues to interpret the eye's position relative to the screen. This implies that the view frustum changes shape whenever an end user moves the location of a window on the screen. In this mode, the field of view is read-only.
    • RELATIVE_TO_WINDOW - specifies that Java 3D should interpret the eye's position information relative to the window (Canvas3D). No matter where an end user moves a window (a Canvas3D), Java 3D continues to interpret the eye's position relative to that window. This implies that the frustum remains the same no matter where the end user moves the window on the screen. In this mode, the field of view is read-only.
    • RELATIVE_TO_FIELD_OF_VIEW - tells Java 3D that it should modify the eyepoint position so it is located at the appropriate place relative to the window to match the specified field of view. This implies that the view frustum will change whenever the application changes the field of view. In this mode, the eye position is read-only. This is the default setting.
    • RELATIVE_TO_COEXISTENCE - tells Java 3D to interpret the eye's position in coexistence coordinates. In this mode, the eye position is taken from the view (rather than the Canvas3D) and transformed from coexistence coordinates to image plate coordinates for each Canvas3D. The resulting eye position is relative to the screen. As in RELATIVE_TO_SCREEN mode, this implies that the view frustum changes shape whenever an end user moves the location of a window on the screen. In this mode, the field of view is read-only.
  • Front and back clip policies - specifies how Java 3D interprets clipping distances to both the near and far clip planes. The policies can contain one of four values specifying whether a distance measurement should be interpreted in the physical or the virtual world and whether that distance measurement should be interpreted relative to the physical eyepoint or the physical screen. The front and back clip policies are specified separately. The front clip policy determines where Java 3D places the front clipping plane. The back clip policy determines where Java 3D places the back clipping plane. The values for both front and back clipping planes are:
    • VIRTUAL_EYE - specifies that the associated distance is from the eye and in units of virtual distance.
    • PHYSICAL_EYE - specifies that the associated distance is from the eye and in units of physical distance (in meters). This is the default policy for both front and back clipping.
    • VIRTUAL_SCREEN - specifies that the associated distance is from the screen and in units of virtual distance.
    • PHYSICAL_SCREEN - specifies that the associated distance is from the screen and in units of physical distance (in meters).
  • Visibility policy - specifies how visible and invisible objects are drawn. There are three visibility policies:
    • VISIBILITY_DRAW_VISIBLE - only visible objects are drawn (this is the default).
    • VISIBILITY_DRAW_INVISIBLE - only invisible objects are drawn.
    • VISIBILITY_DRAW_ALL - both visible and invisible objects are drawn.
  • Transparency sorting policy - specifies whether and how transparent objects are sorted. Sorting multiple transparent objects is necessary to avoid artifacts caused by overlapping transparent objects. There are two transparency sorting policies:
    • TRANSPARENCY_SORT_NONE - no depth sorting of transparent objects is performed (this is the default). Transparent objects are drawn after opaque objects, but are not sorted from back to front.
    • TRANSPARENCY_SORT_GEOMETRY - transparent objects are depth-sorted on a per-geometry basis. Each geometry object of each transparent Shape3D node is drawn from back to front. Note that this policy will not split geometry into smaller pieces, so intersecting or intertwined objects may not be sorted correctly. The method used for determining which geometry is closer is implementation dependent.
Projection and Clip Parameters

The projection and clip parameters determine the view model's field of view and the front and back clipping distances.

  • Field of view - specifies the view model's horizontal field of view in radians, when in the default non-head-tracked mode. This value is ignored when the view model is operating in head-tracked mode, or when the Canvas3D's window eyepoint policy is set to a value other than the default setting of RELATIVE_TO_FIELD_OF_VIEW.
  • Front clip distance - specifies the distance away from the clip origin, specified by the front clip policy variable, in the direction of gaze where objects stop disappearing. Objects closer than the clip origin (eye or screen) plus the front clip distance are not drawn. Measurements are done in the space (physical or virtual) that is specified by the associated front clip policy parameter.
  • Back clip distance - specifies the distance away from the clip origin (specified by the back clip policy variable) in the direction of gaze where objects begin disappearing. Objects farther away from the clip origin (eye or screen) plus the back clip distance are not drawn. Measurements are done in the space (physical or virtual) that is specified by the associated back clip policy parameter. The View object's back clip distance is ignored if the scene graph contains an active Clip leaf node.
  • There are several considerations to take into account when choosing values for the front and back clip distances.

    • The front clip distance must be greater than 0.0 in physical eye coordinates.
    • The front clipping plane must be in front of the back clipping plane, that is, the front clip distance must be less than the back clip distance in physical eye coordinates.
    • The front and back clip distances, in physical eye coordinates, must be less than the largest positive single-precision floating point value, Float.MAX_VALUE. In practice, since these physical eye coordinate distances are in meters, the values should be much less than that.
    • The ratio of the back distance divided by the front distance, in physical eye coordinates, affects Z-buffer precision. This ratio should be less than about 3000 to accommodate 16-bit Z-buffers. Values of 100 to less than 1000 will produce better results.
    Violating any of the above rules will result in undefined behavior. In many cases, no picture will be drawn.

Frame Start Time, Duration, and Number

There are five methods used to get information about system execution and performance:

    getCurrentFrameStartTime returns the time at which the most recent rendering frame started.

    getLastFrameDuration returns the duration, in milliseconds, of the most recently completed rendering frame.

    getFrameNumber returns the frame number for this view.

    getMaxFrameStartTimes retrieves the implementation-dependent maximum number of frames whose start times will be recorded by the system.

    getFrameStartTimes copies the last k frame start time values into the user-specified array.

View Traversal and Behavior Scheduling

The following methods control the traversal, the rendering, and the execution of the behavior scheduler for this view:

    startBehaviorScheduler starts the behavior scheduler running after it has been stopped.

    stopBehaviorScheduler stops the behavior scheduler after all currently-scheduled behaviors are executed.

    isBehaviorSchedulerRunning retrieves a flag that indicates whether the behavior scheduler is currently running.

    startView starts traversing this view and starts the renderers associated with all canvases attached to this view.

    stopView stops traversing this view after the current state of the scene graph is reflected on all canvases attached to this view.

    isViewRunning returns a flag indicating whether the traverser is currently running on this view.

Note: The above six methods are heavy-weight methods intended for verification and image capture (recording). They are not intended to be used for flow control.

Scene Antialiasing

The following methods set and retrieve the scene antialiasing flag. Scene antialiasing is either enabled or disabled for this view. If enabled, the entire scene will be antialiased on each canvas in which scene antialiasing is available. Scene antialiasing is disabled by default.

    setSceneAntialiasingEnable sets the scene antialiasing flag.

    getSceneAntialiasingEnable returns the scene antialiasing flag.

Note that line and point antialiasing are independent of scene antialiasing. If antialiasing is enabled for lines and points, the lines and points will be antialiased prior to scene antialiasing. If scene antialiasing is disabled, antialiased lines and points will still be antialiased.

Note: Scene antialiasing is ignored in pure immediate mode, but is supported in mixed-immediate mode.

Depth Buffer

The following two methods enable and disable automatic freezing of the depth buffer for objects rendered during the transparent rendering pass (that is, objects rendered using alpha blending) for this view. If enabled, depth buffer writes are disabled during the transparent rendering pass regardless of the value of the depth-buffer-write-enable flag in the RenderingAttributes object for a particular node. This flag is enabled by default.

    setDepthBufferFreezeTransparent enables depth buffer freezing.

    getDepthBufferFreezeTransparent retrieves the depth buffer flag.

Transparent objects include BLENDED transparent primitives and antialiased lines and points. Transparent objects do not include opaque objects or primitives rendered with SCREEN_DOOR transparency.

Sensors

The following methods retrieve the sensor's location in the virtual world:

    getSensorToVworld takes the sensor's last reading and generates a sensor-to-vworld coordinate system transform. This Transform3D object takes points in that sensor's local coordinate system and transforms them into virtual world coordinates.

    getSensorHotSpotInVworld retrieves the specified sensor's last hotspot location in virtual world coordinates.

Compatibility Mode

A camera-based view model allows application programmers to think about the images displayed on the computer screen as if a virtual camera took those images. Such a view model allows application programmers to position and orient a virtual camera within a virtual scene, to manipulate some parameters of the virtual camera's lens (specify its field of view), and to specify the locations of the near and far clipping planes.

Java 3D allows applications to enable compatibility mode for room-mounted, non-head-tracked display environments, or to disable compatibility mode using the following methods. Camera-based viewing functions are only available in compatibility mode.

    setCompatibilityModeEnable turns compatibility mode on or off. Compatibility mode is disabled by default.

    getCompatabilityModeEnable returns the compatibility mode enable flag.

Use of these view-compatibility functions will disable some of Java 3D's view model features and limit the portability of Java 3D programs. These methods are primarily intended to help jump-start porting of existing applications.

Setting the Viewing Transform

The View object provides the following compatibility-mode methods that operate on the viewing transform.

    setVpcToEc a compatibility mode method that specifies the ViewPlatform coordinates (VPC) to eye coordinates viewing transform.

    getVpcToEc returns the VPC.

Setting the Projection Transform

The View object provides the following compatibility-mode methods that operate on the projection transform:

    The setLeftProjection and setRightProjection methods specify a viewing frustum for the left and right eye that transforms points in eye coordinates to clipping coordinates.

    The getLeftProjection and getRightProjection methods return the viewing frustum for the left and right eye.

Additional Information

For more information, see the Introduction to the Java 3D API and View Model documents.
See Also:   Canvas3D
See Also:   PhysicalBody
See Also:   PhysicalEnvironment
See Also:   ViewPlatform
See Also:   TransparencyAttributes



Field Summary
final static  intCLIP_DIRTY
    
final static  intCOEXISTENCE_CENTERING_ENABLE_DIRTY
    
final static  intCOMPATIBILITY_MODE_DIRTY
    
final public static  intCYCLOPEAN_EYE_VIEW
     Specifies that monoscopic view generated should be the view as seen from the 'center eye', the fictional eye half-way between the left and right eye.
final static  intFIELD_OF_VIEW_DIRTY
    
final public static  intHMD_VIEW
     Specifies that the viewing environment for this view is a head-mounted display environment. In this mode, Java 3D will compute new viewpoints using that sequence of transforms appropriate to head-mounted display environments.
final public static  intLEFT_EYE_VIEW
     Specifies that monoscopic view generated should be the view as seen from the left eye.
final static  intLEFT_MANUAL_EYE_IN_COEXISTENCE_DIRTY
    
final static  intMONOSCOPIC_VIEW_POLICY_DIRTY
    
final public static  intNOMINAL_FEET
     Specifies a policy whereby the origin of physical or virtual coordinates is relative to the position of the nominal feet.
final public static  intNOMINAL_HEAD
     Specifies a policy whereby the origin of physical or virtual coordinates is relative to the position of the nominal head.
final public static  intNOMINAL_SCREEN
     Specifies a policy whereby the origin of physical or virtual coordinates is relative to the screen.
final static  intNUMBER_FRAME_START_TIMES
    
final static  intOTHER_ATTRS_CHANGED
    
final public static  intPARALLEL_PROJECTION
     Specifies that Java 3D should generate a parallel projection matrix for this View.
final static  intPB_EAR_POSITION_DIRTY
    
final static  intPB_EYE_POSITION_DIRTY
    
final static  intPB_NOMINAL_EYE_HEIGHT_FROM_GROUND_DIRTY
    
final static  intPB_NOMINAL_EYE_OFFSET_FROM_NOMINAL_SCREEN_DIRTY
    
final public static  intPERSPECTIVE_PROJECTION
     Specifies that Java 3D should generate a perspective projection matrix for this View.
final static  intPE_COE_CENTER_IN_PWORLD_POLICY_DIRTY
    
final static  intPE_COE_TO_TRACKER_BASE_DIRTY
    
final static  intPE_TRACKING_AVAILABLE_DIRTY
    
final public static  intPHYSICAL_EYE
     Specifies that the associated distance is measured from the eye in meters.
final public static  intPHYSICAL_SCREEN
     Specifies that the associated distance is measured from the screen in meters.
final public static  intPHYSICAL_WORLD
     Policy for resizing and moving windows.
final static  intPROJECTION_POLICY_DIRTY
    
final public static  intRELATIVE_TO_COEXISTENCE
     Policy for placing the eyepoint in non-head-tracked modes. Specifies that Java 3D should interpret the fixed eyepoint position in the view as relative to the origin of coexistence coordinates.
final public static  intRELATIVE_TO_FIELD_OF_VIEW
     Policy for placing the eyepoint in non-head-tracked modes.
final public static  intRELATIVE_TO_SCREEN
     Policy for placing the eyepoint in non-head-tracked modes.
final public static  intRELATIVE_TO_WINDOW
     Policy for placing the eyepoint in non-head-tracked modes.
final public static  intRIGHT_EYE_VIEW
     Specifies that monoscopic view generated should be the view as seen from the right eye.
final static  intRIGHT_MANUAL_EYE_IN_COEXISTENCE_DIRTY
    
final public static  intSCALE_EXPLICIT
     Specifies that the screen scale for this view is taken directly from the user-provided screenScale parameter.
final public static  intSCALE_SCREEN_SIZE
     Specifies that the screen scale for this view is derived from the physical screen size.
final static  intSCREEN_SCALE_DIRTY
    
final static  intSCREEN_SCALE_POLICY_DIRTY
    
final public static  intSCREEN_VIEW
     Specifies that the viewing environment for this view is a standard screen-based display environment.
final static  intTRACKING_ENABLE_DIRTY
    
final public static  intTRANSPARENCY_SORT_GEOMETRY
     Policy that specifies that transparent objects are sorted from back to front on a per-geometry basis.
final public static  intTRANSPARENCY_SORT_NONE
     Policy that specifies that no sorting of transparent objects is done.
final static  intTRANSP_SORT_POLICY_CHANGED
    
final static  intUSER_HEAD_TO_VWORLD_ENABLE_DIRTY
    
final static  intVIEW_POLICY_DIRTY
    
final public static  intVIRTUAL_EYE
     Specifies that the associated distance is measured from the eye in virtual world coordinates.
final public static  intVIRTUAL_SCREEN
     Specifies that the associated distance is measured from the screen in virtual world coordinates.
final public static  intVIRTUAL_WORLD
     Policy for resizing and moving windows.
final public static  intVISIBILITY_DRAW_ALL
     Policy that specifies that both visible and invisible objects should be drawn.
final public static  intVISIBILITY_DRAW_INVISIBLE
     Policy that specifies that only invisible objects should be drawn.
final public static  intVISIBILITY_DRAW_VISIBLE
     Policy that specifies that only visible objects should be drawn.
final static  intVISIBILITY_POLICY_DIRTY
    
final static  intVPR_VIEWPLATFORM_DIRTY
    
final static  intVPR_VIEW_ATTACH_POLICY_DIRTY
    
final static  intWINDOW_EYE_POINT_POLICY_DIRTY
    
final static  intWINDOW_MOVEMENT_POLICY_DIRTY
    
final static  intWINDOW_RESIZE_POLICY_DIRTY
    
 booleanactive
    
 booleanactiveStatus
    
 doublebackClipDistance
    
 intbackClipPolicy
     Defines the policy for placing the back clipping plane.
 booleancoexistenceCenteringEnable
    
 Transform3DcompatLeftProjection
    
 Transform3DcompatRightProjection
    
 Transform3DcompatVpcToEc
    
 booleancompatibilityModeEnable
    
 longcurrentFrameDuration
    
 intcurrentFrameIndex
    
 longcurrentFrameNumber
    
 longcurrentFrameStartTime
    
 booleandepthBufferFreezeTransparent
    
volatile  booleandoneUnregister
    
 doublefieldOfView
    
 booleanfirstTime
    
 longframeNumber
    
 long[]frameNumbers
    
 long[]frameStartTimes
    
 doublefrontClipDistance
    
 intfrontClipPolicy
     Defines the policy for placing the front clipping plane.
 booleaninCanvasCallback
    
volatile  booleaninRenderThreadData
    
 booleanisMinCycleTimeAchieve
    
volatile  booleanisRunning
    
 Point3dleftManualEyeInCoexistence
    
 booleanlocalEyeLightingEnable
    
 longminFrameCycleTime
    
 intmonoscopicViewPolicy
    
 PhysicalBodyphysicalBody
    
 PhysicalEnvironmentphysicalEnvironment
    
 booleanprimaryView
    
 intprojectionPolicy
    
 RenderBinrenderBin
    
 booleanrenderBinReady
    
volatile  booleanrenderOnceFinish
    
 longresetUnivCount
    
 Point3drightManualEyeInCoexistence
    
 booleansceneAntialiasingEnable
    
 doublescreenScale
    
 intscreenScalePolicy
    
 longsleepTime
    
 SoundRenderersoundRenderer
    
 SoundSchedulersoundScheduler
    
 longstartTime
    
 booleanstopBehavior
    
 longstopTime
    
 intstopViewCount
     use for stop view, when stopview, set to count -1, when reach 1, call stopView() in MC and reset to -1.
 booleantrackingEnable
     Flag to enable tracking, if so allowed by the trackingAvailable flag.
 inttransparencySortingPolicy
     Defines the transparency sorting policy.
 VirtualUniverseuniverse
    
 longuniverseCount
    
 booleanuserHeadToVworldEnable
     This setting enables the continuous updating by Java 3D of the userHeadToVworld transform.
 intvDirtyMask
    
 ViewCacheviewCache
    
 IntegerviewId
    
 intviewIndex
    
 intviewPolicy
    
 Viewerviewer
    
 intvisibilityPolicy
     Defines the visibility policy.
 intwindowEyepointPolicy
    
 intwindowMovementPolicy
    
 intwindowResizePolicy
    

Constructor Summary
public  View()
     Constructs a View object with default parameters.

Method Summary
 voidactivate(VirtualUniverse universe)
     This activates all traversers and renderers associated with this view.
public  voidaddCanvas3D(Canvas3D canvas3D)
     Adds the given Canvas3D at the end of the list.
 voidassignViewId()
    
public  voidattachViewPlatform(ViewPlatform vp)
     Attach viewPlatform structure to this view.
 booleancheckBehaviorSchedulerState(String s1, String s2)
     Check if BehaviorScheduler is in valid state to start/stop itself.
 voidcheckView()
    
 voidcheckViewState(String s1, String s2)
     This will throw IllegalStateException if not in valid state for start/stop request.
 voidcleanupViewId()
    
 voidcomputeCanvasesCached()
    
 voidcomputeCycleTime()
    
 voiddeactivate()
     This deactivates all traversers and renderers associated with this view.
 voidevaluateActive()
    
public  EnumerationgetAllCanvas3Ds()
     Gets the enumeration object of all the Canvas3Ds.
public  doublegetBackClipDistance()
     Returns the view model's back clip distance.
public  intgetBackClipPolicy()
     Returns the view model's current back clip policy.
public  Canvas3DgetCanvas3D(int index)
     Gets the Canvas3D at the specified index position.
 Canvas3D[][]getCanvasList(boolean canCompute)
    
 Canvas3D[]getCanvases()
    
public  booleangetCoexistenceCenteringEnable()
     Retrieves the coexistenceCentering enable flag.
public  booleangetCompatibilityModeEnable()
     Retrieves the compatibility mode enable flag.
public  longgetCurrentFrameStartTime()
     This method returns the time at which the most recent rendering frame started.
public  booleangetDepthBufferFreezeTransparent()
     Retrieves the current value of the depth buffer freeze transparent flag for this view.
public  doublegetFieldOfView()
     Returns the current field of view.
 Canvas3DgetFirstCanvas()
    
public  longgetFrameNumber()
     This method returns the frame number for this view.
public  longgetFrameStartTimes(long[] times)
     Copies the last k frame start time values into the user-specified array.
public  doublegetFrontClipDistance()
     Returns the view model's front clip distance.
public  intgetFrontClipPolicy()
     Returns the view model's current front clip policy.
public  longgetLastFrameDuration()
     This method returns the duration, in milliseconds, of the most recently completed rendering frame.
public  voidgetLeftManualEyeInCoexistence(Point3d position)
     Retrieves the position of the user-specified, manual left eye in coexistence coordinates and copies that value into the object provided.
public  voidgetLeftProjection(Transform3D projection)
     Compatibility mode method that retrieves the current compatibility mode projection transform for the left eye and places it into the specified object.
public  booleangetLocalEyeLightingEnable()
     Retrieves a flag that indicates whether or not local eye lighting is enabled for this view.
 intgetLongestScreenList()
    
public static  intgetMaxFrameStartTimes()
     Retrieves the implementation-dependent maximum number of frames whose start times will be recorded by the system.
public  longgetMinimumFrameCycleTime()
     Retrieves the minimum frame cycle time, in milliseconds, for this view.
public  intgetMonoscopicViewPolicy()
    
public  PhysicalBodygetPhysicalBody()
     Returns a reference to the view model's PhysicalBody object.
public  PhysicalEnvironmentgetPhysicalEnvironment()
     Returns a reference to the view model's PhysicalEnvironment object.
public  intgetProjectionPolicy()
     Retrieves the current projection policy for this View.
public  voidgetRightManualEyeInCoexistence(Point3d position)
     Retrieves the position of the user-specified, manual right eye in coexistence coordinates and copies that value into the object provided.
public  voidgetRightProjection(Transform3D projection)
     Compatibility mode method that retrieves the current compatibility mode projection transform for the right eye and places it into the specified object.
public  booleangetSceneAntialiasingEnable()
     Returns a flag that indicates whether or not scene antialiasing is enabled for this view.
public  doublegetScreenScale()
    
public  intgetScreenScalePolicy()
     Returns the current screen scale policy, one of: SCALE_SCREEN_SIZE or SCALE_EXPLICIT.
 Screen3D[]getScreens()
    
public  voidgetSensorHotspotInVworld(Sensor sensor, Point3f position)
     Retrieves the position of the specified Sensor's hotspot in virtual-world coordinates and copies that value into the position provided.
public  voidgetSensorHotspotInVworld(Sensor sensor, Point3d position)
     Retrieves the position of the specified Sensor's hotspot in virtual-world coordinates and copies that value into the position provided.
public  voidgetSensorToVworld(Sensor sensor, Transform3D t)
     Computes the sensor to virtual-world transform and copies that value into the transform provided. The computed transforms takes points in the sensor's coordinate system and produces the point's corresponding value in virtual-world coordinates.
public  booleangetTrackingEnable()
     Returns a status flag indicating whether or not head tracking is enabled.
public  intgetTransparencySortingPolicy()
     Retrieves the current transparency sorting policy.
public  voidgetUserHeadToVworld(Transform3D t)
     Retrieves the user-head to virtual-world transform and copies that value into the transform provided.
public  booleangetUserHeadToVworldEnable()
     Returns a status flag indicating whether or not Java 3D is continuously updating the userHeadToVworldEnable transform.
public  ViewPlatformgetViewPlatform()
    
public  intgetViewPolicy()
     Retrieves the current view computation policy for this View.
public  intgetVisibilityPolicy()
     Retrieves the current visibility policy.
public  voidgetVpcToEc(Transform3D vpcToEc)
     Compatibility mode method that retrieves the current ViewPlatform Coordinates (VPC) system to Eye Coordinates (EC) transform and copies it into the specified object.
public  intgetWindowEyepointPolicy()
     Returns the current window eyepoint policy, one of: RELATIVE_TO_SCREEN, RELATIVE_TO_WINDOW, RELATIVE_TO_FIELD_OF_VIEW or RELATIVE_TO_COEXISTENCE.
public  intgetWindowMovementPolicy()
     Returns the current window movement policy, one of: VIRTUAL_WORLD or PHYSICAL_WORLD.
public  intgetWindowResizePolicy()
     Returns the current window resize policy, one of: VIRTUAL_WORLD or PHYSICAL_WORLD.
public  intindexOfCanvas3D(Canvas3D canvas3D)
     Retrieves the index of the specified Canvas3D in this View's list of Canvas3Ds
Parameters:
  canvas3D - the Canvas3D to be looked up.
public  voidinsertCanvas3D(Canvas3D canvas3D, int index)
     Inserts the Canvas3D at the given index position.
final public  booleanisBehaviorSchedulerRunning()
     Retrieves a flag that indicates whether the behavior scheduler is currently running.
final public  booleanisViewRunning()
     Retrieves a flag that indicates whether the traverser is currently running on this view.
public  intnumCanvas3Ds()
     Returns the number of Canvas3Ds in this View.
public  voidremoveAllCanvas3Ds()
     Removes all Canvas3Ds from this View.
public  voidremoveCanvas3D(int index)
     Removes the Canvas3D from the given index position.
public  voidremoveCanvas3D(Canvas3D canvas3D)
     Removes the specified Canvas3D from this View's list of Canvas3Ds.
public  voidrenderOnce()
     Renders one frame for a stopped View.
public  voidrepaint()
     Requests that this View be scheduled for rendering as soon as possible.
 voidreset()
    
 voidsendEventToSoundScheduler(AWTEvent evt)
    
public  voidsetBackClipDistance(double distance)
     Sets the view model's back clip distance. The parameter specifies the distance from the eyepoint in the direction of gaze to where objects begin disappearing. Objects farther away from the eye than the back clip distance are not drawn. The default value is 10.0 meters.

There are several considerations that need to be taken into account when choosing values for the front and back clip distances.

public  voidsetBackClipPolicy(int policy)
     Sets the view model's back clip policy, the policy Java 3D uses in computing where to place the back clip plane.
public  voidsetCanvas3D(Canvas3D canvas3D, int index)
     Sets given Canvas3D at the given index position.
public  voidsetCoexistenceCenteringEnable(boolean flag)
     Sets the coexistenceCentering enable flag to true or false. If the coexistenceCentering flag is true, the center of coexistence in image plate coordinates, as specified by the trackerBaseToImagePlate transform, is translated to the center of either the window or the screen in image plate coordinates, according to the value of windowMovementPolicy.

By default, coexistenceCentering is enabled.

public  voidsetCompatibilityModeEnable(boolean flag)
     Sets the compatibility mode enable flag to true or false.
public  voidsetDepthBufferFreezeTransparent(boolean flag)
     Enables or disables automatic freezing of the depth buffer for objects rendered during the transparent rendering pass (i.e., objects rendered using alpha blending) for this view.
public  voidsetFieldOfView(double fieldOfView)
     Sets the field of view used to compute the projection transform.
 voidsetFrameTimingValues()
    
public  voidsetFrontClipDistance(double distance)
     Sets the view model's front clip distance. This value specifies the distance away from the eyepoint in the direction of gaze where objects stop disappearing. Objects closer to the eye than the front clip distance are not drawn.
public  voidsetFrontClipPolicy(int policy)
     Sets the view model's front clip policy, the policy Java 3D uses in computing where to place the front clip plane.
public  voidsetLeftManualEyeInCoexistence(Point3d position)
     Sets the position of the manual left eye in coexistence coordinates.
public  voidsetLeftProjection(Transform3D projection)
     Compatibility mode method that specifies a viewing frustum for the left eye that transforms points in Eye Coordinates (EC) to Clipping Coordinates (CC).
public  voidsetLocalEyeLightingEnable(boolean flag)
     Sets a flag that indicates whether the local eyepoint is used in lighting calculations for perspective projections. If this flag is set to true, the view vector is calculated per-vertex based on the direction from the actual eyepoint to the vertex. If this flag is set to false, a single view vector is computed from the eyepoint to the center of the view frustum.
public  voidsetMinimumFrameCycleTime(long minimumTime)
     Sets the minimum frame cycle time, in milliseconds, for this view.
public  voidsetMonoscopicViewPolicy(int policy)
    
public  voidsetPhysicalBody(PhysicalBody physicalBody)
     Sets the view model's physical body to the PhysicalBody object provided.
public  voidsetPhysicalEnvironment(PhysicalEnvironment physicalEnvironment)
     Sets the view model's physical environment to the PhysicalEnvironment object provided.
public  voidsetProjectionPolicy(int policy)
     Sets the projection policy for this View. This variable specifies the type of projection transform that will be generated.
public  voidsetRightManualEyeInCoexistence(Point3d position)
     Sets the position of the manual right eye in coexistence coordinates.
public  voidsetRightProjection(Transform3D projection)
     Compatibility mode method that specifies a viewing frustum for the right eye that transforms points in Eye Coordinates (EC) to Clipping Coordinates (CC).
public  voidsetSceneAntialiasingEnable(boolean flag)
     Enables or disables scene antialiasing for this view.
public  voidsetScreenScale(double scale)
     Sets the screen scale value for this view.
public  voidsetScreenScalePolicy(int policy)
     Sets the screen scale policy for this view. This policy specifies how the screen scale is derived. The value is either SCALE_SCREEN_SIZE or SCALE_EXPLICIT. A value of SCALE_SCREEN_SIZE specifies that the scale is derived from the size of the physical screen.
public  voidsetTrackingEnable(boolean flag)
     Turns head tracking on or off for this view.
public  voidsetTransparencySortingPolicy(int policy)
     Sets the transparency sorting policy for this view.
 voidsetUniverse(VirtualUniverse universe)
    
public  voidsetUserHeadToVworldEnable(boolean flag)
     Turns on or off the continuous updating of the userHeadToVworld transform.
public  voidsetViewPolicy(int policy)
     Sets the policy for view computation.
public  voidsetVisibilityPolicy(int policy)
     Sets the visibility policy for this view.
public  voidsetVpcToEc(Transform3D vpcToEc)
     Compatibility mode method that specifies the ViewPlatform Coordinates (VPC) to Eye Coordinates (EC) transform.
public  voidsetWindowEyepointPolicy(int policy)
     Sets the view model's window eyepoint policy. This variable specifies how Java 3D handles the predefined eye point in a non-head-tracked environment.
public  voidsetWindowMovementPolicy(int policy)
     Sets the window movement policy. This variable specifies what part of the virtual world Java 3D draws as a function of window placement on the screen.
public  voidsetWindowResizePolicy(int policy)
     Sets the window resize policy. This variable specifies how Java 3D modifies the view when users resize windows.
final public  voidstartBehaviorScheduler()
     Starts the behavior scheduler running after it has been stopped.
final public  voidstartView()
     Starts traversing this view, and starts the renderers associated with all canvases attached to this view.
final public  long[]stopBehaviorScheduler()
     Stops the behavior scheduler after all currently scheduled behaviors are executed.
final public  voidstopView()
     Stops traversing the scene graph for this view after the current state of the scene graph is reflected on all canvases attached to this view.
final  voidupdateViewCache()
     Update the view cache associated with this view.

Field Detail
CLIP_DIRTY
final static int CLIP_DIRTY(Code)



COEXISTENCE_CENTERING_ENABLE_DIRTY
final static int COEXISTENCE_CENTERING_ENABLE_DIRTY(Code)



COMPATIBILITY_MODE_DIRTY
final static int COMPATIBILITY_MODE_DIRTY(Code)



CYCLOPEAN_EYE_VIEW
final public static int CYCLOPEAN_EYE_VIEW(Code)
Specifies that monoscopic view generated should be the view as seen from the 'center eye', the fictional eye half-way between the left and right eye.
See Also:   Canvas3D.setMonoscopicViewPolicy



FIELD_OF_VIEW_DIRTY
final static int FIELD_OF_VIEW_DIRTY(Code)



HMD_VIEW
final public static int HMD_VIEW(Code)
Specifies that the viewing environment for this view is a head-mounted display environment. In this mode, Java 3D will compute new viewpoints using that sequence of transforms appropriate to head-mounted display environments. These environments are generally head-tracked.
See Also:   View.setViewPolicy



LEFT_EYE_VIEW
final public static int LEFT_EYE_VIEW(Code)
Specifies that monoscopic view generated should be the view as seen from the left eye.
See Also:   Canvas3D.setMonoscopicViewPolicy



LEFT_MANUAL_EYE_IN_COEXISTENCE_DIRTY
final static int LEFT_MANUAL_EYE_IN_COEXISTENCE_DIRTY(Code)



MONOSCOPIC_VIEW_POLICY_DIRTY
final static int MONOSCOPIC_VIEW_POLICY_DIRTY(Code)



NOMINAL_FEET
final public static int NOMINAL_FEET(Code)
Specifies a policy whereby the origin of physical or virtual coordinates is relative to the position of the nominal feet. When used as a view attach policy, this sets the origin of view platform coordinates to be at the ground plane.
See Also:   ViewPlatform.setViewAttachPolicy
See Also:   PhysicalEnvironment.setCoexistenceCenterInPworldPolicy



NOMINAL_HEAD
final public static int NOMINAL_HEAD(Code)
Specifies a policy whereby the origin of physical or virtual coordinates is relative to the position of the nominal head. When used as a view attach policy, this sets the origin of view platform coordinates to be at the eyepoint.
See Also:   ViewPlatform.setViewAttachPolicy
See Also:   PhysicalEnvironment.setCoexistenceCenterInPworldPolicy



NOMINAL_SCREEN
final public static int NOMINAL_SCREEN(Code)
Specifies a policy whereby the origin of physical or virtual coordinates is relative to the screen. When used as a view attach policy, this sets the origin of view platform coordinates to be at the center of the window or screen, in effect, allowing the user to view objects from an optimal viewpoint.
See Also:   ViewPlatform.setViewAttachPolicy
See Also:   PhysicalEnvironment.setCoexistenceCenterInPworldPolicy



NUMBER_FRAME_START_TIMES
final static int NUMBER_FRAME_START_TIMES(Code)



OTHER_ATTRS_CHANGED
final static int OTHER_ATTRS_CHANGED(Code)



PARALLEL_PROJECTION
final public static int PARALLEL_PROJECTION(Code)
Specifies that Java 3D should generate a parallel projection matrix for this View.
See Also:   View.setProjectionPolicy



PB_EAR_POSITION_DIRTY
final static int PB_EAR_POSITION_DIRTY(Code)



PB_EYE_POSITION_DIRTY
final static int PB_EYE_POSITION_DIRTY(Code)



PB_NOMINAL_EYE_HEIGHT_FROM_GROUND_DIRTY
final static int PB_NOMINAL_EYE_HEIGHT_FROM_GROUND_DIRTY(Code)



PB_NOMINAL_EYE_OFFSET_FROM_NOMINAL_SCREEN_DIRTY
final static int PB_NOMINAL_EYE_OFFSET_FROM_NOMINAL_SCREEN_DIRTY(Code)



PERSPECTIVE_PROJECTION
final public static int PERSPECTIVE_PROJECTION(Code)
Specifies that Java 3D should generate a perspective projection matrix for this View. This is the default mode.
See Also:   View.setProjectionPolicy



PE_COE_CENTER_IN_PWORLD_POLICY_DIRTY
final static int PE_COE_CENTER_IN_PWORLD_POLICY_DIRTY(Code)



PE_COE_TO_TRACKER_BASE_DIRTY
final static int PE_COE_TO_TRACKER_BASE_DIRTY(Code)



PE_TRACKING_AVAILABLE_DIRTY
final static int PE_TRACKING_AVAILABLE_DIRTY(Code)



PHYSICAL_EYE
final public static int PHYSICAL_EYE(Code)
Specifies that the associated distance is measured from the eye in meters. Policy for interpreting clip plane distances. Used in specifying the policy in frontClipPolicy and backClipPolicy. This is the default policy for both front and back clipping.
See Also:   View.setFrontClipPolicy
See Also:   View.setBackClipPolicy



PHYSICAL_SCREEN
final public static int PHYSICAL_SCREEN(Code)
Specifies that the associated distance is measured from the screen in meters. Policy for interpreting clip plane distances. Used in specifying the policy in frontClipPolicy and backClipPolicy.
See Also:   View.setFrontClipPolicy
See Also:   View.setBackClipPolicy



PHYSICAL_WORLD
final public static int PHYSICAL_WORLD(Code)
Policy for resizing and moving windows. Used in specifying windowResizePolicy and windowMovementPolicy. PHYSICAL_WORLD specifies that the specified action takes place only in the physical world.
See Also:   View.setWindowResizePolicy
See Also:   View.setWindowMovementPolicy



PROJECTION_POLICY_DIRTY
final static int PROJECTION_POLICY_DIRTY(Code)



RELATIVE_TO_COEXISTENCE
final public static int RELATIVE_TO_COEXISTENCE(Code)
Policy for placing the eyepoint in non-head-tracked modes. Specifies that Java 3D should interpret the fixed eyepoint position in the view as relative to the origin of coexistence coordinates. This eyepoint is transformed from coexistence coordinates to image plate coordinates for each Canvas3D. As in RELATIVE_TO_SCREEN mode, this implies that the view frustum shape will change whenever a user moves the location of a window on the screen.
See Also:   View.setWindowEyepointPolicy
since:
   Java 3D 1.2



RELATIVE_TO_FIELD_OF_VIEW
final public static int RELATIVE_TO_FIELD_OF_VIEW(Code)
Policy for placing the eyepoint in non-head-tracked modes. Specifies that Java 3D should modify the position of the eyepoint to match any changes in field of view; the view frustum will change whenever the application program changes the field of view.

NOTE: when this policy is specified, the Z coordinate of the derived eyepoint is used in place of nominalEyeOffsetFromNominalScreen.
See Also:   View.setWindowEyepointPolicy




RELATIVE_TO_SCREEN
final public static int RELATIVE_TO_SCREEN(Code)
Policy for placing the eyepoint in non-head-tracked modes. Specifies that Java 3D should interpret the given fixed eyepoint position as relative to the entire screen. This implies that the view frustum shape will change whenever a user moves the location of a window on the screen.
See Also:   View.setWindowEyepointPolicy



RELATIVE_TO_WINDOW
final public static int RELATIVE_TO_WINDOW(Code)
Policy for placing the eyepoint in non-head-tracked modes. Specifies that Java 3D should interpret the given fixed-eyepoint position as relative to the window.
See Also:   View.setWindowEyepointPolicy



RIGHT_EYE_VIEW
final public static int RIGHT_EYE_VIEW(Code)
Specifies that monoscopic view generated should be the view as seen from the right eye.
See Also:   Canvas3D.setMonoscopicViewPolicy



RIGHT_MANUAL_EYE_IN_COEXISTENCE_DIRTY
final static int RIGHT_MANUAL_EYE_IN_COEXISTENCE_DIRTY(Code)



SCALE_EXPLICIT
final public static int SCALE_EXPLICIT(Code)
Specifies that the screen scale for this view is taken directly from the user-provided screenScale parameter.
See Also:   View.setScreenScalePolicy
See Also:   View.setScreenScale



SCALE_SCREEN_SIZE
final public static int SCALE_SCREEN_SIZE(Code)
Specifies that the screen scale for this view is derived from the physical screen size. This scale factor is computed as follows:
    physical_screen_width / 2.0
This allows an application to define a world in a normalized [-1,1] space and view it on a screen of any size.
See Also:   View.setScreenScalePolicy



SCREEN_SCALE_DIRTY
final static int SCREEN_SCALE_DIRTY(Code)



SCREEN_SCALE_POLICY_DIRTY
final static int SCREEN_SCALE_POLICY_DIRTY(Code)



SCREEN_VIEW
final public static int SCREEN_VIEW(Code)
Specifies that the viewing environment for this view is a standard screen-based display environment. In this mode, Java 3D will compute new viewpoints using that sequence of transforms appropriate to screen-based, display environments, that may or may not include head tracking (e.g., a monoscopic screen, fish-tank VR, portals, VR-desks). This is the default mode.
See Also:   View.setViewPolicy



TRACKING_ENABLE_DIRTY
final static int TRACKING_ENABLE_DIRTY(Code)



TRANSPARENCY_SORT_GEOMETRY
final public static int TRANSPARENCY_SORT_GEOMETRY(Code)
Policy that specifies that transparent objects are sorted from back to front on a per-geometry basis.
See Also:   View.setTransparencySortingPolicy
since:
   Java 3D 1.3



TRANSPARENCY_SORT_NONE
final public static int TRANSPARENCY_SORT_NONE(Code)
Policy that specifies that no sorting of transparent objects is done. This is the default mode.
See Also:   View.setTransparencySortingPolicy
since:
   Java 3D 1.3



TRANSP_SORT_POLICY_CHANGED
final static int TRANSP_SORT_POLICY_CHANGED(Code)



USER_HEAD_TO_VWORLD_ENABLE_DIRTY
final static int USER_HEAD_TO_VWORLD_ENABLE_DIRTY(Code)



VIEW_POLICY_DIRTY
final static int VIEW_POLICY_DIRTY(Code)



VIRTUAL_EYE
final public static int VIRTUAL_EYE(Code)
Specifies that the associated distance is measured from the eye in virtual world coordinates. Policy for interpreting clip plane distances. Used in specifying the policy in frontClipPolicy and backClipPolicy.
See Also:   View.setFrontClipPolicy
See Also:   View.setBackClipPolicy



VIRTUAL_SCREEN
final public static int VIRTUAL_SCREEN(Code)
Specifies that the associated distance is measured from the screen in virtual world coordinates. Policy for interpreting clip plane distances. Used in specifying the policy in frontClipPolicy and backClipPolicy.
See Also:   View.setFrontClipPolicy
See Also:   View.setBackClipPolicy



VIRTUAL_WORLD
final public static int VIRTUAL_WORLD(Code)
Policy for resizing and moving windows. Used in specifying windowResizePolicy and windowMovementPolicy. VIRTUAL_WORLD specifies that the associated action takes place in the virtual world as well as in the physical world.
See Also:   View.setWindowResizePolicy
See Also:   View.setWindowMovementPolicy



VISIBILITY_DRAW_ALL
final public static int VISIBILITY_DRAW_ALL(Code)
Policy that specifies that both visible and invisible objects should be drawn.
See Also:   View.setVisibilityPolicy
since:
   Java 3D 1.2



VISIBILITY_DRAW_INVISIBLE
final public static int VISIBILITY_DRAW_INVISIBLE(Code)
Policy that specifies that only invisible objects should be drawn.
See Also:   View.setVisibilityPolicy
since:
   Java 3D 1.2



VISIBILITY_DRAW_VISIBLE
final public static int VISIBILITY_DRAW_VISIBLE(Code)
Policy that specifies that only visible objects should be drawn. This is the default mode.
See Also:   View.setVisibilityPolicy
since:
   Java 3D 1.2



VISIBILITY_POLICY_DIRTY
final static int VISIBILITY_POLICY_DIRTY(Code)



VPR_VIEWPLATFORM_DIRTY
final static int VPR_VIEWPLATFORM_DIRTY(Code)



VPR_VIEW_ATTACH_POLICY_DIRTY
final static int VPR_VIEW_ATTACH_POLICY_DIRTY(Code)



WINDOW_EYE_POINT_POLICY_DIRTY
final static int WINDOW_EYE_POINT_POLICY_DIRTY(Code)



WINDOW_MOVEMENT_POLICY_DIRTY
final static int WINDOW_MOVEMENT_POLICY_DIRTY(Code)



WINDOW_RESIZE_POLICY_DIRTY
final static int WINDOW_RESIZE_POLICY_DIRTY(Code)



active
boolean active(Code)



activeStatus
boolean activeStatus(Code)



backClipDistance
double backClipDistance(Code)



backClipPolicy
int backClipPolicy(Code)
Defines the policy for placing the back clipping plane.



coexistenceCenteringEnable
boolean coexistenceCenteringEnable(Code)



compatLeftProjection
Transform3D compatLeftProjection(Code)



compatRightProjection
Transform3D compatRightProjection(Code)



compatVpcToEc
Transform3D compatVpcToEc(Code)



compatibilityModeEnable
boolean compatibilityModeEnable(Code)



currentFrameDuration
long currentFrameDuration(Code)



currentFrameIndex
int currentFrameIndex(Code)



currentFrameNumber
long currentFrameNumber(Code)



currentFrameStartTime
long currentFrameStartTime(Code)



depthBufferFreezeTransparent
boolean depthBufferFreezeTransparent(Code)



doneUnregister
volatile boolean doneUnregister(Code)



fieldOfView
double fieldOfView(Code)



firstTime
boolean firstTime(Code)



frameNumber
long frameNumber(Code)



frameNumbers
long[] frameNumbers(Code)



frameStartTimes
long[] frameStartTimes(Code)



frontClipDistance
double frontClipDistance(Code)



frontClipPolicy
int frontClipPolicy(Code)
Defines the policy for placing the front clipping plane. Legal values include PHYSICAL_EYE, PHYSICAL_SCREEN, VIRTUAL_EYE, and VIRTUAL_SCREEN.



inCanvasCallback
boolean inCanvasCallback(Code)



inRenderThreadData
volatile boolean inRenderThreadData(Code)



isMinCycleTimeAchieve
boolean isMinCycleTimeAchieve(Code)
False if current frame cycle time less than minimum frame cycle time



isRunning
volatile boolean isRunning(Code)



leftManualEyeInCoexistence
Point3d leftManualEyeInCoexistence(Code)



localEyeLightingEnable
boolean localEyeLightingEnable(Code)



minFrameCycleTime
long minFrameCycleTime(Code)



monoscopicViewPolicy
int monoscopicViewPolicy(Code)



physicalBody
PhysicalBody physicalBody(Code)



physicalEnvironment
PhysicalEnvironment physicalEnvironment(Code)



primaryView
boolean primaryView(Code)



projectionPolicy
int projectionPolicy(Code)



renderBin
RenderBin renderBin(Code)



renderBinReady
boolean renderBinReady(Code)



renderOnceFinish
volatile boolean renderOnceFinish(Code)



resetUnivCount
long resetUnivCount(Code)



rightManualEyeInCoexistence
Point3d rightManualEyeInCoexistence(Code)



sceneAntialiasingEnable
boolean sceneAntialiasingEnable(Code)



screenScale
double screenScale(Code)



screenScalePolicy
int screenScalePolicy(Code)



sleepTime
long sleepTime(Code)



soundRenderer
SoundRenderer soundRenderer(Code)



soundScheduler
SoundScheduler soundScheduler(Code)



startTime
long startTime(Code)



stopBehavior
boolean stopBehavior(Code)



stopTime
long stopTime(Code)



stopViewCount
int stopViewCount(Code)
use for stop view, when stopview, set to count -1, when reach 1, call stopView() in MC and reset to -1.



trackingEnable
boolean trackingEnable(Code)
Flag to enable tracking, if so allowed by the trackingAvailable flag.



transparencySortingPolicy
int transparencySortingPolicy(Code)
Defines the transparency sorting policy.



universe
VirtualUniverse universe(Code)



universeCount
long universeCount(Code)



userHeadToVworldEnable
boolean userHeadToVworldEnable(Code)
This setting enables the continuous updating by Java 3D of the userHeadToVworld transform.



vDirtyMask
int vDirtyMask(Code)



viewCache
ViewCache viewCache(Code)



viewId
Integer viewId(Code)



viewIndex
int viewIndex(Code)



viewPolicy
int viewPolicy(Code)



viewer
Viewer viewer(Code)



visibilityPolicy
int visibilityPolicy(Code)
Defines the visibility policy.



windowEyepointPolicy
int windowEyepointPolicy(Code)



windowMovementPolicy
int windowMovementPolicy(Code)



windowResizePolicy
int windowResizePolicy(Code)




Constructor Detail
View
public View()(Code)
Constructs a View object with default parameters. The default values are as follows:
    view policy : SCREEN_VIEW
    projection policy : PERSPECTIVE_PROJECTION
    screen scale policy : SCALE_SCREEN_SIZE
    window resize policy : PHYSICAL_WORLD
    window movement policy : PHYSICAL_WORLD
    window eyepoint policy : RELATIVE_TO_FIELD_OF_VIEW
    monoscopic view policy : CYCLOPEAN_EYE_VIEW
    front clip policy : PHYSICAL_EYE
    back clip policy : PHYSICAL_EYE
    visibility policy : VISIBILITY_DRAW_VISIBLE
    transparency sorting policy : TRANSPARENCY_SORT_NONE
    coexistenceCentering flag : true
    compatibility mode : false
    left projection : identity
    right projection : identity
    vpc to ec transform : identity
    physical body : null
    physical environment : null
    screen scale : 1.0
    field of view : PI/4
    left manual eye in coexistence : (-0.033, 0.0, 0.4572)
    right manual eye in coexistence : (0.033, 0.0, 0.4572)
    front clip distance : 0.1
    back clip distance : 10.0
    tracking enable : false
    user head to vworld enable : false
    list of Canvas3D objects : empty
    depth buffer freeze transparent : true
    scene antialiasing : false
    local eye lighting : false
    view platform : null
    behavior scheduler running : true
    view running : true
    minimum frame cycle time : 0




Method Detail
activate
void activate(VirtualUniverse universe)(Code)
This activates all traversers and renderers associated with this view.



addCanvas3D
public void addCanvas3D(Canvas3D canvas3D)(Code)
Adds the given Canvas3D at the end of the list.
Parameters:
  canvas3D - the Canvas3D to be added
exception:
  IllegalStateException - if the specified canvas isa stereo canvas with a monoscopicEyePolicy of CYCLOPEAN_EYE_VIEW,and the viewPolicy for this view is HMD_VIEW
exception:
  IllegalSharingException - if the specified canvas isassociated with another view



assignViewId
void assignViewId()(Code)



attachViewPlatform
public void attachViewPlatform(ViewPlatform vp)(Code)
Attach viewPlatform structure to this view.
Parameters:
  vp - the viewPlatform to be attached



checkBehaviorSchedulerState
boolean checkBehaviorSchedulerState(String s1, String s2)(Code)
Check if BehaviorScheduler is in valid state to start/stop itself.
Parameters:
  s1 - Exception String if method is called from a Canvas3D
Parameters:
  s2 - Exception String if method is called from a Behavior method true if viewPlatform is live
exception:
  IllegalStateException - if this method is calledfrom a Behavior method or from any Canvas3D render callbackmethod



checkView
void checkView()(Code)
Checks view parameters for consistency



checkViewState
void checkViewState(String s1, String s2) throws IllegalStateException(Code)
This will throw IllegalStateException if not in valid state for start/stop request.



cleanupViewId
void cleanupViewId()(Code)



computeCanvasesCached
void computeCanvasesCached()(Code)



computeCycleTime
void computeCycleTime()(Code)
Return true if maximum fps impose by user reach



deactivate
void deactivate()(Code)
This deactivates all traversers and renderers associated with this view.



evaluateActive
void evaluateActive()(Code)
This routine activates or deactivates a view based on various information



getAllCanvas3Ds
public Enumeration getAllCanvas3Ds()(Code)
Gets the enumeration object of all the Canvas3Ds. the enumeration object of all the Canvas3Ds.



getBackClipDistance
public double getBackClipDistance()(Code)
Returns the view model's back clip distance. the current back clip distance



getBackClipPolicy
public int getBackClipPolicy()(Code)
Returns the view model's current back clip policy. one of:VIRTUAL_EYE, PHYSICAL_EYE, VIRTUAL_SCREEN, or PHYSICAL_SCREEN



getCanvas3D
public Canvas3D getCanvas3D(int index)(Code)
Gets the Canvas3D at the specified index position.
Parameters:
  index - the position from which to get Canvas3D object the Canvas3D at the sprcified index position



getCanvasList
Canvas3D[][] getCanvasList(boolean canCompute)(Code)



getCanvases
Canvas3D[] getCanvases()(Code)



getCoexistenceCenteringEnable
public boolean getCoexistenceCenteringEnable()(Code)
Retrieves the coexistenceCentering enable flag. the current coexistenceCentering enable flag
since:
   Java 3D 1.2



getCompatibilityModeEnable
public boolean getCompatibilityModeEnable()(Code)
Retrieves the compatibility mode enable flag. the current compatibility mode enable flag



getCurrentFrameStartTime
public long getCurrentFrameStartTime()(Code)
This method returns the time at which the most recent rendering frame started. It is defined as the number of milliseconds since January 1, 1970 00:00:00 GMT. Since multiple canvases might be attached to this View, the start of a frame is defined as the point in time just prior to clearing any canvas attached to this view. the time at which the most recent rendering frame started



getDepthBufferFreezeTransparent
public boolean getDepthBufferFreezeTransparent()(Code)
Retrieves the current value of the depth buffer freeze transparent flag for this view. a flag that indicates whether or not the depthbuffer is automatically frozen during the transparent rendering pass.



getFieldOfView
public double getFieldOfView()(Code)
Returns the current field of view. the current field of view in radians



getFirstCanvas
Canvas3D getFirstCanvas()(Code)



getFrameNumber
public long getFrameNumber()(Code)
This method returns the frame number for this view. The frame number starts at 0 and is incremented at the start of each frame--prior to clearing all the canvases attached to this view. the current frame number for this view



getFrameStartTimes
public long getFrameStartTimes(long[] times)(Code)
Copies the last k frame start time values into the user-specified array. The most recent frame start time is copied to location 0 of the array, the next most recent frame start time is copied into location 1 of the array, and so forth. If times.length is smaller than maxFrameStartTimes, then only the last times.length values are copied. If times.length is greater than maxFrameStartTimes, then all array elements after index maxFrameStartTimes-1 are set to 0. the frame number of the most recent frame in the array
See Also:   View.setMinimumFrameCycleTime



getFrontClipDistance
public double getFrontClipDistance()(Code)
Returns the view model's front clip distance. the current front clip distance



getFrontClipPolicy
public int getFrontClipPolicy()(Code)
Returns the view model's current front clip policy. one of:VIRTUAL_EYE, PHYSICAL_EYE, VIRTUAL_SCREEN, or PHYSICAL_SCREEN



getLastFrameDuration
public long getLastFrameDuration()(Code)
This method returns the duration, in milliseconds, of the most recently completed rendering frame. The time taken to render all canvases attached to this view is measured. This duration is computed as the difference between the start of the most recently completed frame and the end of that frame. Since multiple canvases might be attached to this View, the start of a frame is defined as the point in time just prior to clearing any canvas attached to this view--before preRender is called for any canvas. Similarly, the end of a frame is defined as the point in time just after swapping the buffer for all canvases--after postSwap is called for all canvases. Note that since the frame duration is measured from start to stop for this view only, the value returned is not the same as frame rate; it measures only the rendering time for this view. the duration, in milliseconds, of the most recentlycompleted rendering frame



getLeftManualEyeInCoexistence
public void getLeftManualEyeInCoexistence(Point3d position)(Code)
Retrieves the position of the user-specified, manual left eye in coexistence coordinates and copies that value into the object provided.
Parameters:
  position - the object that will receive the position
since:
   Java 3D 1.2



getLeftProjection
public void getLeftProjection(Transform3D projection)(Code)
Compatibility mode method that retrieves the current compatibility mode projection transform for the left eye and places it into the specified object.
Parameters:
  projection - the Transform3D object that will receive theprojection
exception:
  RestrictedAccessException - if compatibility mode is disabled.



getLocalEyeLightingEnable
public boolean getLocalEyeLightingEnable()(Code)
Retrieves a flag that indicates whether or not local eye lighting is enabled for this view. a flag that indicates whether local eye lighting is enabled



getLongestScreenList
int getLongestScreenList()(Code)



getMaxFrameStartTimes
public static int getMaxFrameStartTimes()(Code)
Retrieves the implementation-dependent maximum number of frames whose start times will be recorded by the system. This value is guaranteed to be at least 10 for all implementations of the Java 3D API. the maximum number of frame start times recorded



getMinimumFrameCycleTime
public long getMinimumFrameCycleTime()(Code)
Retrieves the minimum frame cycle time, in milliseconds, for this view. the minimum frame cycle time for this view.
See Also:   View.getFrameStartTimes
since:
   Java 3D 1.2



getMonoscopicViewPolicy
public int getMonoscopicViewPolicy()(Code)



getPhysicalBody
public PhysicalBody getPhysicalBody()(Code)
Returns a reference to the view model's PhysicalBody object. the view object's PhysicalBody object



getPhysicalEnvironment
public PhysicalEnvironment getPhysicalEnvironment()(Code)
Returns a reference to the view model's PhysicalEnvironment object. the view object's PhysicalEnvironment object



getProjectionPolicy
public int getProjectionPolicy()(Code)
Retrieves the current projection policy for this View. one of: PARALLEL_PROJECTION or PERSPECTIVE_PROJECTION.



getRightManualEyeInCoexistence
public void getRightManualEyeInCoexistence(Point3d position)(Code)
Retrieves the position of the user-specified, manual right eye in coexistence coordinates and copies that value into the object provided.
Parameters:
  position - the object that will receive the position
since:
   Java 3D 1.2



getRightProjection
public void getRightProjection(Transform3D projection)(Code)
Compatibility mode method that retrieves the current compatibility mode projection transform for the right eye and places it into the specified object.
Parameters:
  projection - the Transform3D object that will receive theprojection
exception:
  RestrictedAccessException - if compatibility mode is disabled.



getSceneAntialiasingEnable
public boolean getSceneAntialiasingEnable()(Code)
Returns a flag that indicates whether or not scene antialiasing is enabled for this view. a flag that indicates whether scene antialiasing is enabled



getScreenScale
public double getScreenScale()(Code)
Returns the current screen scale value the current screen scale value



getScreenScalePolicy
public int getScreenScalePolicy()(Code)
Returns the current screen scale policy, one of: SCALE_SCREEN_SIZE or SCALE_EXPLICIT. the current screen scale policy



getScreens
Screen3D[] getScreens()(Code)



getSensorHotspotInVworld
public void getSensorHotspotInVworld(Sensor sensor, Point3f position)(Code)
Retrieves the position of the specified Sensor's hotspot in virtual-world coordinates and copies that value into the position provided. This value is derived from other values and is read-only.
Parameters:
  sensor - the sensor in question
Parameters:
  position - the variable that will receive the position



getSensorHotspotInVworld
public void getSensorHotspotInVworld(Sensor sensor, Point3d position)(Code)
Retrieves the position of the specified Sensor's hotspot in virtual-world coordinates and copies that value into the position provided. This value is derived from other values and is read-only.
Parameters:
  sensor - the sensor in question
Parameters:
  position - the variable that will receive the position



getSensorToVworld
public void getSensorToVworld(Sensor sensor, Transform3D t)(Code)
Computes the sensor to virtual-world transform and copies that value into the transform provided. The computed transforms takes points in the sensor's coordinate system and produces the point's corresponding value in virtual-world coordinates.
Parameters:
  sensor - the sensor in question
Parameters:
  t - the object that will receive the transform



getTrackingEnable
public boolean getTrackingEnable()(Code)
Returns a status flag indicating whether or not head tracking is enabled. a flag telling whether head tracking is enabled



getTransparencySortingPolicy
public int getTransparencySortingPolicy()(Code)
Retrieves the current transparency sorting policy. one of:TRANSPARENCY_SORT_NONE or TRANSPARENCY_SORT_GEOMETRY.
since:
   Java 3D 1.3



getUserHeadToVworld
public void getUserHeadToVworld(Transform3D t)(Code)
Retrieves the user-head to virtual-world transform and copies that value into the transform provided.
Parameters:
  t - the Transform3D object that will receive the transform



getUserHeadToVworldEnable
public boolean getUserHeadToVworldEnable()(Code)
Returns a status flag indicating whether or not Java 3D is continuously updating the userHeadToVworldEnable transform. a flag indicating if continuously updating userHeadToVworld



getViewPlatform
public ViewPlatform getViewPlatform()(Code)
Retrieves the currently attached ViewPlatform object the currently attached ViewPlatform



getViewPolicy
public int getViewPolicy()(Code)
Retrieves the current view computation policy for this View. one of: SCREEN_VIEW or HMD_VIEW.



getVisibilityPolicy
public int getVisibilityPolicy()(Code)
Retrieves the current visibility policy. one of:VISIBILITY_DRAW_VISIBLE,VISIBILITY_DRAW_INVISIBLE, or VISIBILITY_DRAW_ALL.
since:
   Java 3D 1.2



getVpcToEc
public void getVpcToEc(Transform3D vpcToEc)(Code)
Compatibility mode method that retrieves the current ViewPlatform Coordinates (VPC) system to Eye Coordinates (EC) transform and copies it into the specified object.
Parameters:
  vpcToEc - the object that will receive the vpcToEc transform.
exception:
  RestrictedAccessException - if compatibility mode is disabled.



getWindowEyepointPolicy
public int getWindowEyepointPolicy()(Code)
Returns the current window eyepoint policy, one of: RELATIVE_TO_SCREEN, RELATIVE_TO_WINDOW, RELATIVE_TO_FIELD_OF_VIEW or RELATIVE_TO_COEXISTENCE. the current window eyepoint policy



getWindowMovementPolicy
public int getWindowMovementPolicy()(Code)
Returns the current window movement policy, one of: VIRTUAL_WORLD or PHYSICAL_WORLD. the current window movement policy



getWindowResizePolicy
public int getWindowResizePolicy()(Code)
Returns the current window resize policy, one of: VIRTUAL_WORLD or PHYSICAL_WORLD. the current window resize policy



indexOfCanvas3D
public int indexOfCanvas3D(Canvas3D canvas3D)(Code)
Retrieves the index of the specified Canvas3D in this View's list of Canvas3Ds
Parameters:
  canvas3D - the Canvas3D to be looked up. the index of the specified Canvas3D;returns -1 if the object is not in the list.
since:
   Java 3D 1.3



insertCanvas3D
public void insertCanvas3D(Canvas3D canvas3D, int index)(Code)
Inserts the Canvas3D at the given index position.
Parameters:
  canvas3D - the Canvas3D to be inserted
Parameters:
  index - the position to be inserted at
exception:
  IllegalStateException - if the specified canvas isa stereo canvas with a monoscopicEyePolicy of CYCLOPEAN_EYE_VIEW,and the viewPolicy for this view is HMD_VIEW
exception:
  IllegalSharingException - if the specified canvas isassociated with another view



isBehaviorSchedulerRunning
final public boolean isBehaviorSchedulerRunning()(Code)
Retrieves a flag that indicates whether the behavior scheduler is currently running. true if the behavior scheduler is running, false otherwise
exception:
  IllegalStateException - if this method is calledfrom a Behavior method or from any Canvas3D render callbackmethod



isViewRunning
final public boolean isViewRunning()(Code)
Retrieves a flag that indicates whether the traverser is currently running on this view. true if the traverser is running, false otherwise
exception:
  IllegalStateException - if this method is calledfrom a Behavior method or from any Canvas3D render callbackmethod



numCanvas3Ds
public int numCanvas3Ds()(Code)
Returns the number of Canvas3Ds in this View. the number of Canvas3Ds in this View
since:
   Java 3D 1.2



removeAllCanvas3Ds
public void removeAllCanvas3Ds()(Code)
Removes all Canvas3Ds from this View.
since:
   Java 3D 1.3



removeCanvas3D
public void removeCanvas3D(int index)(Code)
Removes the Canvas3D from the given index position.
Parameters:
  index - the position of Canvas3D object to be removed



removeCanvas3D
public void removeCanvas3D(Canvas3D canvas3D)(Code)
Removes the specified Canvas3D from this View's list of Canvas3Ds. If the specified object is not in the list, the list is not modified.
Parameters:
  canvas3D - the Canvas3D to be removed.



renderOnce
public void renderOnce()(Code)
Renders one frame for a stopped View. Functionally, this method is equivalent to startView() followed by stopview(), except that it is atomic, which guarantees that only one frame is rendered.
exception:
  IllegalStateException - if this method is called froma Behavior method or from any Canvas3D render callback, or ifthe view is currently running.
since:
   Java 3D 1.2



repaint
public void repaint()(Code)
Requests that this View be scheduled for rendering as soon as possible. The repaint method may return before the frame has been rendered. If the view is stopped, or if the view is continuously running (for example, due to a free-running interpolator), this method will have no effect. Most applications will not need to call this method, since any update to the scene graph or to viewing parameters will automatically cause all affected views to be rendered.
since:
   Java 3D 1.2



reset
void reset()(Code)



sendEventToSoundScheduler
void sendEventToSoundScheduler(AWTEvent evt)(Code)
This method passes window event to SoundScheduler



setBackClipDistance
public void setBackClipDistance(double distance)(Code)
Sets the view model's back clip distance. The parameter specifies the distance from the eyepoint in the direction of gaze to where objects begin disappearing. Objects farther away from the eye than the back clip distance are not drawn. The default value is 10.0 meters.

There are several considerations that need to be taken into account when choosing values for the front and back clip distances. These are enumerated in the description of setFrontClipDistance.

Note that this attribute is only used if there is no Clip node that is in scope of the view platform associated with this view.
Parameters:
  distance - the new back clip distance
See Also:   View.setFrontClipDistance
See Also:   Clip.setBackDistance




setBackClipPolicy
public void setBackClipPolicy(int policy)(Code)
Sets the view model's back clip policy, the policy Java 3D uses in computing where to place the back clip plane. The variable can contain one of:
  • VIRTUAL_EYE, to specify that the associated distance is from the eye and in units of virtual distance
  • PHYSICAL_EYE, to specify that the associated distance is from the eye and in units of physical distance (meters)
  • VIRTUAL_SCREEN, to specify that the associated distance is from the screen and in units of virtual distance
  • PHYSICAL_SCREEN, to specify that the associated distance is from the screen and in units of physical distance (meters)
The default back clip policy is PHYSICAL_EYE.
Parameters:
  policy - the new policy, one of PHYSICAL_EYE, PHYSICAL_SCREEN,VIRTUAL_EYE, or VIRTUAL_SCREEN



setCanvas3D
public void setCanvas3D(Canvas3D canvas3D, int index)(Code)
Sets given Canvas3D at the given index position.
Parameters:
  canvas3D - the given Canvas3D to be set
Parameters:
  index - the position to be set
exception:
  IllegalStateException - if the specified canvas isa stereo canvas with a monoscopicEyePolicy of CYCLOPEAN_EYE_VIEW,and the viewPolicy for this view is HMD_VIEW
exception:
  IllegalSharingException - if the specified canvas isassociated with another view



setCoexistenceCenteringEnable
public void setCoexistenceCenteringEnable(boolean flag)(Code)
Sets the coexistenceCentering enable flag to true or false. If the coexistenceCentering flag is true, the center of coexistence in image plate coordinates, as specified by the trackerBaseToImagePlate transform, is translated to the center of either the window or the screen in image plate coordinates, according to the value of windowMovementPolicy.

By default, coexistenceCentering is enabled. It should be disabled if the trackerBaseToImagePlate calibration transform is set to a value other than the identity (for example, when rendering to multiple screens or when head tracking is enabled). This flag is ignored for HMD mode, or when the coexistenceCenterInPworldPolicy is not NOMINAL_SCREEN.
Parameters:
  flag - the new coexistenceCentering enable flag
since:
   Java 3D 1.2




setCompatibilityModeEnable
public void setCompatibilityModeEnable(boolean flag)(Code)
Sets the compatibility mode enable flag to true or false. Compatibility mode is disabled by default.
Parameters:
  flag - the new compatibility mode enable flag



setDepthBufferFreezeTransparent
public void setDepthBufferFreezeTransparent(boolean flag)(Code)
Enables or disables automatic freezing of the depth buffer for objects rendered during the transparent rendering pass (i.e., objects rendered using alpha blending) for this view. If enabled, depth buffer writes will be disabled during the transparent rendering pass regardless of the value of the depth buffer write enable flag in the RenderingAttributes object for a particular node. This flag is enabled by default.
Parameters:
  flag - indicates whether automatic freezing of the depth bufferfor transparent/antialiased objects is enabled.
See Also:   RenderingAttributes.setDepthBufferWriteEnable



setFieldOfView
public void setFieldOfView(double fieldOfView)(Code)
Sets the field of view used to compute the projection transform. This is used when head tracking is disabled and when the Canvas3D's windowEyepointPolicy is RELATIVE_TO_FIELD_OF_VIEW.
Parameters:
  fieldOfView - the new field of view in radians



setFrameTimingValues
void setFrameTimingValues()(Code)
This adds a frame time to the this of frame times



setFrontClipDistance
public void setFrontClipDistance(double distance)(Code)
Sets the view model's front clip distance. This value specifies the distance away from the eyepoint in the direction of gaze where objects stop disappearing. Objects closer to the eye than the front clip distance are not drawn. The default value is 0.1 meters.

There are several considerations that need to be taken into account when choosing values for the front and back clip distances.

  • The front clip distance must be greater than 0.0 in physical eye coordinates.
  • The front clipping plane must be in front of the back clipping plane, that is, the front clip distance must be less than the back clip distance in physical eye coordinates.
  • The front and back clip distances, in physical eye coordinates, must be less than the largest positive single-precision floating point value, Float.MAX_VALUE. In practice, since these physical eye coordinate distances are in meters, the values should be much less than that.
  • The ratio of the back distance divided by the front distance, in physical eye coordinates, affects Z-buffer precision. This ratio should be less than about 3000 in order to accommodate 16-bit Z-buffers. Values of 100 to less than 1000 will produce better results.
Violating any of the above rules will result in undefined behavior. In many cases, no picture will be drawn.
Parameters:
  distance - the new front clip distance
See Also:   View.setBackClipDistance



setFrontClipPolicy
public void setFrontClipPolicy(int policy)(Code)
Sets the view model's front clip policy, the policy Java 3D uses in computing where to place the front clip plane. The variable can contain one of:
  • VIRTUAL_EYE, to specify that the associated distance is from the eye and in units of virtual distance
  • PHYSICAL_EYE, to specify that the associated distance is from the eye and in units of physical distance (meters)
  • VIRTUAL_SCREEN, to specify that the associated distance is from the screen and in units of virtual distance
  • PHYSICAL_SCREEN, to specify that the associated distance is from the screen and in units of physical distance (meters)
The default front clip policy is PHYSICAL_EYE.
Parameters:
  policy - the new policy, one of PHYSICAL_EYE, PHYSICAL_SCREEN,VIRTUAL_EYE, or VIRTUAL_SCREEN



setLeftManualEyeInCoexistence
public void setLeftManualEyeInCoexistence(Point3d position)(Code)
Sets the position of the manual left eye in coexistence coordinates. This value determines eye placement when a head tracker is not in use and the application is directly controlling the eye position in coexistence coordinates. This value is ignored when in head-tracked mode or when the windowEyePointPolicy is not RELATIVE_TO_COEXISTENCE.
Parameters:
  position - the new manual left eye position
since:
   Java 3D 1.2



setLeftProjection
public void setLeftProjection(Transform3D projection)(Code)
Compatibility mode method that specifies a viewing frustum for the left eye that transforms points in Eye Coordinates (EC) to Clipping Coordinates (CC). If compatibility mode is disabled, then this transform is not used; the actual projection is derived from other values. In monoscopic mode, only the left eye projection matrix is used.
Parameters:
  projection - the new left eye projection transform
exception:
  RestrictedAccessException - if compatibility mode is disabled.



setLocalEyeLightingEnable
public void setLocalEyeLightingEnable(boolean flag)(Code)
Sets a flag that indicates whether the local eyepoint is used in lighting calculations for perspective projections. If this flag is set to true, the view vector is calculated per-vertex based on the direction from the actual eyepoint to the vertex. If this flag is set to false, a single view vector is computed from the eyepoint to the center of the view frustum. This is called infinite eye lighting. Local eye lighting is disabled by default, and is ignored for parallel projections.
Parameters:
  flag - indicates whether local eye lighting is enabled



setMinimumFrameCycleTime
public void setMinimumFrameCycleTime(long minimumTime)(Code)
Sets the minimum frame cycle time, in milliseconds, for this view. The Java 3D renderer will ensure that the time between the start of each successive frame is at least the specified number of milliseconds. The default value is 0.
Parameters:
  minimumTime - the minimum number of milliseconds betweensuccessive frames
exception:
  IllegalArgumentException - if minimumTime < 0
See Also:   View.getFrameStartTimes
since:
   Java 3D 1.2



setMonoscopicViewPolicy
public void setMonoscopicViewPolicy(int policy)(Code)



setPhysicalBody
public void setPhysicalBody(PhysicalBody physicalBody)(Code)
Sets the view model's physical body to the PhysicalBody object provided. Java 3D uses the parameters in the PhysicalBody to ensure accurate image and sound generation when in head-tracked mode.
Parameters:
  physicalBody - the new PhysicalBody object



setPhysicalEnvironment
public void setPhysicalEnvironment(PhysicalEnvironment physicalEnvironment)(Code)
Sets the view model's physical environment to the PhysicalEnvironment object provided.
Parameters:
  physicalEnvironment - the new PhysicalEnvironment object



setProjectionPolicy
public void setProjectionPolicy(int policy)(Code)
Sets the projection policy for this View. This variable specifies the type of projection transform that will be generated. A value of PARALLEL_PROJECTION specifies that a parallel projection transform is generated. A value of PERSPECTIVE_PROJECTION specifies that a perspective projection transform is generated. The default projection policy is PERSPECTIVE.
Parameters:
  policy - the new policy, one of PARALLEL_PROJECTION orPERSPECTIVE_PROJECTION
exception:
  IllegalArgumentException - if policy is a value other thanPARALLEL_PROJECTION or PERSPECTIVE_PROJECTION



setRightManualEyeInCoexistence
public void setRightManualEyeInCoexistence(Point3d position)(Code)
Sets the position of the manual right eye in coexistence coordinates. This value determines eye placement when a head tracker is not in use and the application is directly controlling the eye position in coexistence coordinates. This value is ignored when in head-tracked mode or when the windowEyePointPolicy is not RELATIVE_TO_COEXISTENCE.
Parameters:
  position - the new manual right eye position
since:
   Java 3D 1.2



setRightProjection
public void setRightProjection(Transform3D projection)(Code)
Compatibility mode method that specifies a viewing frustum for the right eye that transforms points in Eye Coordinates (EC) to Clipping Coordinates (CC). If compatibility mode is disabled, then this transform is not used; the actual projection is derived from other values. In monoscopic mode, the right eye projection matrix is ignored.
Parameters:
  projection - the new right eye projection transform
exception:
  RestrictedAccessException - if compatibility mode is disabled.



setSceneAntialiasingEnable
public void setSceneAntialiasingEnable(boolean flag)(Code)
Enables or disables scene antialiasing for this view. If enabled, the entire scene will be antialiased on each canvas in which scene antialiasing is available. Scene antialiasing is disabled by default.

NOTE: Scene antialiasing is ignored in pure immediate mode, but is supported in mixed-immediate mode.
Parameters:
  flag - indicates whether scene antialiasing is enabled
See Also:   Canvas3D.queryProperties




setScreenScale
public void setScreenScale(double scale)(Code)
Sets the screen scale value for this view. This is used when the screen scale policy is SCALE_EXPLICIT. The default value is 1.0 (i.e., unscaled).
Parameters:
  scale - the new screen scale



setScreenScalePolicy
public void setScreenScalePolicy(int policy)(Code)
Sets the screen scale policy for this view. This policy specifies how the screen scale is derived. The value is either SCALE_SCREEN_SIZE or SCALE_EXPLICIT. A value of SCALE_SCREEN_SIZE specifies that the scale is derived from the size of the physical screen. A value of SCALE_EXPLICIT specifies that the scale is taken directly from the screenScale parameter. The default screen scale policy is SCALE_SCREEN_SIZE.
Parameters:
  policy - the new policy, one of SCALE_SCREEN_SIZE orSCALE_EXPLICIT.



setTrackingEnable
public void setTrackingEnable(boolean flag)(Code)
Turns head tracking on or off for this view.
Parameters:
  flag - specifies whether head tracking is enabled ordisabled for this view



setTransparencySortingPolicy
public void setTransparencySortingPolicy(int policy)(Code)
Sets the transparency sorting policy for this view. This attribute is one of:
  • TRANSPARENCY_SORT_NONE, to specify that no depth sorting of transparent objects is performed. Transparent objects are drawn after opaque objects, but are not sorted from back to front.
  • TRANSPARENCY_SORT_GEOMETRY, to specify that transparent objects are depth-sorted on a per-geometry basis. Each geometry object of each transparent Shape3D node is drawn from back to front. Note that this policy will not split geometry into smaller pieces, so intersecting or intertwined objects may not be sorted correctly.
The default policy is TRANSPARENCY_SORT_NONE.
Parameters:
  policy - the new policy, one of TRANSPARENCY_SORT_NONEor TRANSPARENCY_SORT_GEOMETRY.
since:
   Java 3D 1.3



setUniverse
void setUniverse(VirtualUniverse universe)(Code)



setUserHeadToVworldEnable
public void setUserHeadToVworldEnable(boolean flag)(Code)
Turns on or off the continuous updating of the userHeadToVworld transform.
Parameters:
  flag - enables or disables continuous updating



setViewPolicy
public void setViewPolicy(int policy)(Code)
Sets the policy for view computation. This variable specifies how Java 3D uses its transforms in computing new viewpoints.
  • SCREEN_VIEW specifies that Java 3D should compute a new viewpoint using the sequence of transforms appropriate to screen-based head-tracked display environments (fish-tank VR/portals/VR-desks).
  • HMD_VIEW specifies that Java 3D should compute a new viewpoint using the sequence of transforms appropriate to head mounted display environments.
The default view policy is SCREEN_VIEW.
Parameters:
  policy - the new policy, one of SCREEN_VIEW or HMD_VIEW
exception:
  IllegalArgumentException - if policy is a value other thanSCREEN_VIEW or HMD_VIEW
exception:
  IllegalStateException - if the specified policyis HMD_VIEW and if any canvas associated with this view isa stereo canvas with a monoscopicEyePolicy of CYCLOPEAN_EYE_VIEW



setVisibilityPolicy
public void setVisibilityPolicy(int policy)(Code)
Sets the visibility policy for this view. This attribute is one of:
  • VISIBILITY_DRAW_VISIBLE, to specify that only visible objects are drawn.
  • VISIBILITY_DRAW_INVISIBLE, to specify that only invisible objects are drawn.
  • VISIBILITY_DRAW_ALL, to specify that both visible and invisible objects are drawn.
The default visibility policy is VISIBILITY_DRAW_VISIBLE.
Parameters:
  policy - the new policy, one of VISIBILITY_DRAW_VISIBLE,VISIBILITY_DRAW_INVISIBLE, or VISIBILITY_DRAW_ALL.
See Also:   RenderingAttributes.setVisible
since:
   Java 3D 1.2



setVpcToEc
public void setVpcToEc(Transform3D vpcToEc)(Code)
Compatibility mode method that specifies the ViewPlatform Coordinates (VPC) to Eye Coordinates (EC) transform. If compatibility mode is disabled, then this transform is derived from other values and is read-only.
Parameters:
  vpcToEc - the new VPC to EC transform
exception:
  RestrictedAccessException - if compatibility mode is disabled.
exception:
  BadTransformException - if the transform is not affine.



setWindowEyepointPolicy
public void setWindowEyepointPolicy(int policy)(Code)
Sets the view model's window eyepoint policy. This variable specifies how Java 3D handles the predefined eye point in a non-head-tracked environment. The variable can contain one of:
  • RELATIVE_TO_SCREEN, Java 3D should interpret the given fixed-eyepoint position as relative to the screen (this implies that the view frustum shape will change whenever a user moves the location of a window on the screen).
  • RELATIVE_TO_WINDOW, Java 3D should interpret the given fixed-eyepoint position as relative to the window. In this mode, the X and Y values are taken as the center of the window and the Z value is taken from the canvas eyepoint position.
  • RELATIVE_TO_FIELD_OF_VIEW, Java 3D should modify the position of the eyepoint to match any changes in field of view (the view frustum will change whenever the application program changes the field of view).
  • RELATIVE_TO_COEXISTENCE, Java 3D should interpret the eye's position in coexistence coordinates. In this mode, the eye position is taken from the view (rather than the Canvas3D) and transformed from coexistence coordinates to image plate coordinates for each Canvas3D. The resulting eye position is relative to the screen (this implies that the view frustum shape will change whenever a user moves the location of a window on the screen).
The default window eyepoint policy is RELATIVE_TO_FIELD_OF_VIEW.
Parameters:
  policy - the new policy, one of RELATIVE_TO_SCREEN,RELATIVE_TO_WINDOW, RELATIVE_TO_FIELD_OF_VIEW, orRELATIVE_TO_COEXISTENCE



setWindowMovementPolicy
public void setWindowMovementPolicy(int policy)(Code)
Sets the window movement policy. This variable specifies what part of the virtual world Java 3D draws as a function of window placement on the screen. The variable can contain one of VIRTUAL_WORLD or PHYSICAL_WORLD. A value of VIRTUAL_WORLD implies that the image seen in the window changes as the position of the window shifts on the screen. (This mode acts as if the window were a window into the virtual world.) A value of PHYSICAL_WORLD implies that the image seen in the window remains the same no matter where the user positions the window on the screen. The default window movement policy is PHYSICAL_WORLD.
Parameters:
  policy - the new policy, one of VIRTUAL_WORLD or PHYSICAL_WORLD



setWindowResizePolicy
public void setWindowResizePolicy(int policy)(Code)
Sets the window resize policy. This variable specifies how Java 3D modifies the view when users resize windows. The variable can contain one of VIRTUAL_WORLD or PHYSICAL_WORLD. A value of VIRTUAL_WORLD implies that the original image remains the same size on the screen but the user sees more or less of the virtual world depending on whether the window grew or shrank in size. A value of PHYSICAL_WORLD implies that the original image continues to fill the window in the same way using more or less pixels depending on whether the window grew or shrank in size. The default window resize policy is PHYSICAL_WORLD.
Parameters:
  policy - the new policy, one of VIRTUAL_WORLD or PHYSICAL_WORLD



startBehaviorScheduler
final public void startBehaviorScheduler()(Code)
Starts the behavior scheduler running after it has been stopped.
exception:
  IllegalStateException - if this method is calledfrom a Behavior method or from any Canvas3D render callbackmethod



startView
final public void startView()(Code)
Starts traversing this view, and starts the renderers associated with all canvases attached to this view.
exception:
  IllegalStateException - if this method is calledfrom a Behavior method or from any Canvas3D render callbackmethod



stopBehaviorScheduler
final public long[] stopBehaviorScheduler()(Code)
Stops the behavior scheduler after all currently scheduled behaviors are executed. Any frame-based behaviors scheduled to wake up on the next frame will be executed at least once before the behavior scheduler is stopped.

NOTE: This is a heavy-weight method intended for verification and image capture (recording); it is not intended to be used for flow control. a pair of integers that specify the beginning and endingtime (in milliseconds since January 1, 1970 00:00:00 GMT)of the behavior scheduler's last pass
exception:
  IllegalStateException - if this method is calledfrom a Behavior method or from any Canvas3D render callbackmethod




stopView
final public void stopView()(Code)
Stops traversing the scene graph for this view after the current state of the scene graph is reflected on all canvases attached to this view. The renderers associated with these canvases are also stopped.

NOTE: This is a heavy-weight method intended for verification and image capture (recording); it is not intended to be used for flow control.
exception:
  IllegalStateException - if this method is calledfrom a Behavior method or from any Canvas3D render callbackmethod




updateViewCache
final void updateViewCache()(Code)
Update the view cache associated with this view. Also, shapshot the per-screen parameters associated with all screens attached to this view.



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.