Hi Michael,
You may need to switch the display mode to 640x480 for
some graphics card to make it work. Also, some cards
have to explicityly enable opengl to use stereo in
their driver property panel. Using
java -Dj3d.stereo=REQUIRED
should work without modifying HelloUniverse,
some graphics card may also need
-Dj3d.sharedstereozbuffer=true
Thanks.
- Kelvin
--------------
Java 3D Team
Sun Microsystems Inc.
>MIME-Version: 1.0
>Content-Transfer-Encoding: 7bit
>Date: Fri, 15 Dec 2000 17:12:15 +1100
>From: Michael Barlow <[EMAIL PROTECTED]>
>Subject: [JAVA3D] Basic Stereo: Doing Something Wrong?
>To: [EMAIL PROTECTED]
>
>Hi. I wonder if someone can help me and explain what I might be
>doing wrong. I suspect I might be missing something obvious.
>
>I want to perform stereoscopy and have started off small by
>modifying the HelloUniverse demonstration to that end. However
>I'm unable to achieve that: it appears that I'm unable to
>obtain a GraphicsConfiguration that supports stereo. This is
>despite running the program in an environment where I can
>achieve stereo directly in openGL.
>
>Here's the particulars:
>
>Platforms: Windows98+Voodoo3 (with latest drivers)
> NT+twin Wildcat4000 cards
>Java 3D version: 1.2.1 Beta (OpenGL).
>JDK: 1.3
>Command Line: java -Dj3d.stereo=REQUIRED -Dj3d.sharedstereozbuffer=true
> OR java -Dj3d.stereo=REQUIRED
> OR java -Dj3d.sharedstereozbuffer=true
>Code Changes:
> I altered the init() method to explicitly create a GraphicsConfiguration
> object that would support stereo. This was done by first creating a
> GraphicsConfigTemplate3D, setting the appropriate attribute, and
> then using the GraphicsEnvironment -> ScreenDevice ->
> GraphicsConfiguration route. The altered piece of code follows.
>
>
> public void init() {
> setLayout(new BorderLayout());
>
> GraphicsConfigTemplate3D gct3d = new GraphicsConfigTemplate3D();
> gct3d.setStereo(GraphicsConfigTemplate3D.REQUIRED);
> GraphicsConfiguration config =
>
GraphicsEnvironment.getLocalGraphicsEnvironment().getDefaultScreenDevice().getBestConfigura
tion(gct3d);
>
> Canvas3D c = new Canvas3D(config);
>
> System.out.println("Stereo availability is: " + c.getStereoAvailable());
> c.setStereoEnable(true);
> System.out.println("Stereo enabled is: " + c.getStereoEnable());
> add("Center", c);
>
>
>No matter what platform, resolution, or colour depth I run this in
>I always receive a null GraphicsConfiguration (config) back from
>the getBestConfiguration() call. Hence the Canvas3D is constructed
>with a null argument and hence is a default Canvas3D without stereo.
>Thats shown by the first trace statement which always prints that stereo
>is not available.
>
>I'm sure I must be missing something obvious (and hence will be
>suitably contrite once its been pointed out), but for the life of me
>I can't currently see what it is. Help would be greatly appreciated.
>
>
>Cheers,
>Spike
>Dr. Michael Barlow
>School of Computer Science
>ADFA
>
>===========================================================================
>To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
>of the message "signoff JAVA3D-INTEREST". For general help, send email to
>[EMAIL PROTECTED] and include in the body of the message "help".
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".