"Theron, Jannie" wrote:
>
> I'll wait and have a look at it.
>
> What are the ad/disadvantages of AWT events vs behaviors for user
> interaction,
> especially movement ?

The j3d Behaviours are limited by the behaviour mechanism of Java3D.
This, as you have noticed, and with other annecdotal evidence, seems to
suffer for degrading performance over a long use (for example dragging a
mouse to move through a scene for a number of seconds). The main issue
really is dealing with j3d's behaviour scheduling system. The more
behaviours that go into a scene the more it will slow down the frame
rate. Each one requires processing and the renderer thread must block
until the behaviour thread has finished executing. You also end up with
a 1 frame delay in the movements from the mouse/kbd to the rendered
result.

By going with an AWT solution, this presents events and updates the J3d
scenegraph structure outside of the normal renderer thread. Therefore
updates are constantly provided without needing to hnave the renderer
thread wait. The event is delivered and placed into the frame ahead of
time (the current implementation basically does a partial dead-reckon
for a half frame timelapse ahead based on the elapsed time of the
previous frame). You end up with a much smoother mechanism as there is
much less object creation. By going through the j3d system it must
create objects to hold the sent state, put them into lists etc. By
staying with raw AWT, you are loosing one step of processing and object
creation.

--
Justin Couch                         http://www.vlc.com.au/~justin/
Freelance Java Consultant                  http://www.yumetech.com/
Author, Java 3D FAQ Maintainer                  http://www.j3d.org/
-------------------------------------------------------------------
"Humanism is dead. Animals think, feel; so do machines now.
Neither man nor woman is the measure of all things. Every organism
processes data according to its domain, its environment; you, with
all your brains, would be useless in a mouse's universe..."
                                              - Greg Bear, Slant
-------------------------------------------------------------------

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