Canvas3D image drawn with an offset in Mac OS X

View: New views
3 Messages — Rating Filter:   Alert me  

Canvas3D image drawn with an offset in Mac OS X

by java3d-interest :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I finished developing the new version 3.1 of my Graphing Calculator 3D yesterday which works smoothly in Windows. Then I went ahead to test it on my Mac machine. I was expecting it to work smoothly there as well since I didn't make any Mac related changes in this version, but the Canvas3D which worked fine in Mac in previous version is now acting weird. It always draws the rendered scene about 2 inches to right. so depending on the size of the window I only see a portion of my graphs on the right side of canvas, even though it's supposed to be centered in the middle.

Why in the world it would work fine in Windows and not in Mac. Specially since I didn't have this in previous versions?

I'm printing out the Canvans3D.getSize() to make sure it is same as its containing JPanel, and it is. I tried so many different arrangements and I just doesn't get fixed.

Any ideas would be greatly appreciated. And fast please since I promised my customers that the new version for Mac would be ready by yesterday and it still isn't!

Saeid
http://calculator.runiter.com/graphing-calculator/
[Message sent by forum member 'runiter' (runiter)]

http://forums.java.net/jive/thread.jspa?messageID=354688

---------------------------------------------------------------------
To unsubscribe, e-mail: interest-unsubscribe@...
For additional commands, e-mail: interest-help@...


Re: Canvas3D image drawn with an offset in Mac OS X

by java3d-interest :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Here is an screenshot of the problem:

http://www.runiter.com/images/etc/Canvas3D-Problem.jpg

The grey sphere you see in the scene is directly added to scene using SimpleUniverse.addBranchGraph() so it's supposed to be in the middle of the Canvas3D but as you can see it isn't!
[Message sent by forum member 'runiter' (runiter)]

http://forums.java.net/jive/thread.jspa?messageID=354699

---------------------------------------------------------------------
To unsubscribe, e-mail: interest-unsubscribe@...
For additional commands, e-mail: interest-help@...


Re: Canvas3D image drawn with an offset in Mac OS X

by java3d-interest :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I found out what the problem was. I was request an Stereo enabled Canvas3D using the following:

GraphicsConfigTemplate3D template = new GraphicsConfigTemplate3D();
template.setStereo(GraphicsConfigTemplate.PREFERRED);
Canvas3D canvas = new Canvas3D(config);

I commented out the 2nd line and my graph is now centered. I guess in Mac OS, even though it had no stereo capability it still tried to draw one eye image but left out the other eye.
[Message sent by forum member 'runiter' (runiter)]

http://forums.java.net/jive/thread.jspa?messageID=354701

---------------------------------------------------------------------
To unsubscribe, e-mail: interest-unsubscribe@...
For additional commands, e-mail: interest-help@...