Hi Ma'n,
Java3D only consumes CPU cycles when there is rendering to be done or if
a behavior wants to run (either WakupOnElapsedFrames, Time etc). This
satisfies requirements 3 & 4 in your list.
The exact architecture of your system will depend on how the 3D system needs
to process the stimulus from the embedded system and how regularly these
events occur. You need to decide if every stimulus should cause the
3D scene to be redrawn or if the stimulus can be batched, this will probably
depend on how often stimulus are generated. Also does a stimulus cause a single
or multiple changes to the scenegraph ?
If every stimulus should immediately be reflected in the 3D scene, then the
stimulus needs to simply change the SceneGraph object to represent the
change (ie change colour, transparency or transform ). Java3D will then
redraw the scene to reflect the changes.
If stimuli can be batched, or a stimulus requires many changes to the
scenegraph then a better approach is to use a Java3D behavior that
wakes up on WakeupOnBehaviorPost. The behavior would 'cache' the stimulus
and then make all the changes to the scenegraph in the Behavior processStimulus
method when postID is called. The call to postID can either be made every
time a stimulus is received or after a certain batch size is achieved.
Rgds
Pau
----------------------------------------------------------
Paul Byrne Email : [EMAIL PROTECTED]
Sun Microsystems Phone : (650) 786 9926
Visualization Software Group Fax : (650) 786 5852
----------------------------------------------------------
>MIME-Version: 1.0
>Date: Fri, 26 Jan 2001 11:29:06 -0600
>From: Altaher Man-QA5778 <Ma'[EMAIL PROTECTED]>
>Subject: [JAVA3D] Using J3D with embedded systems
>To: [EMAIL PROTECTED]
>
>I'm trying to implement a J3D gui which gets its stimulus from an embeded
>system rather from the Mouse or the Keyboard. In other words the stimulus is
>coming from the embeded system. Which wakeup criterion I should be using?
>Also, I'm not sure which rendering mode I should be using. I do not want J3D
>rendering to control the the CPU cycle all the time. I want to do the
>following:
>
> 1. Embeded system posts a stimulus
> 2. J3D takes control of CPU
> 3. J3D gui process stimulus
> 4. J3D release control of CPU to embeded system (I'm expecting the
>image to remain on the screen after this step)
>
>Thx,
>
>Ma'n.
>
===========================================================================
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".