Title: Message
I suspect the problem is that you are doing the update from your own thread. The whole point of the behavior setup is that it lets Java3D execute code in the right order and at the right time to make everything work nicely. Also - setting up a behavior to execute every frame via a WakeupOnElapsedFrames(0) will allow you to change transforms for each frame. There is no point in modifying them any more frequently than this, as the screen will only be updated on each frame anyway!
 
 
-----Original Message-----
From: Discussion list for Java 3D API [mailto:[EMAIL PROTECTED] On Behalf Of Doug Twilleager
Sent: 28 August 2003 16:31
To: [EMAIL PROTECTED]
Subject: Re: [JAVA3D] flickering Shape3D object when moving both ViewPlatform and Shape3D-Object

Is it flicker or stuttering?  What's your framerate.  I am assuming that it is higher than your update
rate (25fps).  A better approach is to update ever frame, and use the amount of time passed
between frames to drive your physics.  You will need to use the hi-res timer utility to get a good
measure of the time between frames.

Doug.

Johannes Neubauer wrote:

Hello,

 

Take a look here, please: http://flash-tools.de/j3d/test.zip             (179KB)

 

 

I still try to make a 3d-Game in J3D. I have loaded an Objectfile for my Spaceship and one for my Terrain. There is only one Ambientlight and no textures, so it isn’t beautiful, but good for testing. I don’t want to use the utils classes from Sun, so I used a Thread (GameTimer) instead. In a while(true) loop the Thread starts every 40ms (25times per second) a method which process the Keyevents and changes the Transform of my ship and my ViewPlatform. So I have two moving Objects:

 

-The Spaceship moves, when a Key is pressed.

-The ViewPlatform follows the Ship.

 

The Terrain is painted correctly when the ViewPlatform moves, but the Ship is flickering horrible! How can I change this???

 

I will thank you for every answer ;)!

 

Greetings,

Johannes Neubauer

=========================================================================== 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".
=========================================================================== 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".

Reply via email to