Hi Lily,
>MIME-Version: 1.0
>Content-Transfer-Encoding: 7bit
>Date: Fri, 24 Mar 2000 18:00:30 -0500
>From: Lily Lee <[EMAIL PROTECTED]>
>Subject: [JAVA3D] WakeupOnElapsedFrames
>To: [EMAIL PROTECTED]
>
>Does any one know precisely when WakeupOnElapsedFrames(0) becomes
>true? Looking at the API, a process should wakeup every time a new
>frame is displayed. However, the definition of a "new frame" is not
>clear to me. Logically, it should be whenever anything in a scene has
>changed and a new rendering is done. However, it appears that
>regardless of what happens in a scene, a process wakes up whenever
>there is a wakeupOn(newFrame), regardless of whether the scene has
>changed.
It depends of whether WakeupOnElapsedFrames is initialize as
passive or non-passive (default).
* @param passive flag indicating whether this behavior is
* passive; a non-passive behavior will cause the rendering system
* to run continuously, while a passive behavior will only run
* when some other event causes a frame to be run.
Whever the rendering system run and do a swap frame,
WakeupOnElapsedFrames will invoke.
>
>What I really want to do is have a loop that generates a scene,
>render, get back the image, process the image, and then depending on
>the output of the image process, generate another scene. What this
>means is that I cannot put my code in the rendering loop because a new
>scene needs to be rendered before the previous render is done, and I
>am having trouble with using the WakeupOnElapsedFrames criterion
>because of the following steps:
>
>When a canvas3D is appears, it first generates a blank frame, then my
>initial scene. I want to skip the blank frame. If I skip it by just
>calling wakeupOn(newFrame) after getting the blank frame, then the
>frame with the initial scene is displayed twice, so I am one step
>behind from then on. If I don't call wakeupOn(newFrame), then the
>process won't wakeup.
>
>
>Does anyone have a way to solve this problem?
>
>
This should be fixed in v1.2 beta1, the first frame should not blank.
However there is a bug in wakeupOnElapseFrames in beta1 which may cause
it to skip or call 2 times between doSwap(). The upcoming v1.2beta2
has fixed this problem.
Please try again when v1.2beta2 release. If the problem still exists,
please send us a test program.
Thanks.
- Kelvin
---------------
Java 3D Team
Sun Microsystems Inc.
===========================================================================
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".