> Date:         Mon, 24 Feb 2003 12:35:33 -0800
> From: Sean Sylvis <[EMAIL PROTECTED]>
>
> But if you want to update the coordinates after setting the =
> TriangleStripArray's reference, you must go through the GeometryUpdater =
> interface.
> =20
> Using the GeometryUpdater, you can update the geometry coordinates =
> directly (through updateData()) without having to modify the structure =
> of the Java3D scene graph (detaching and reattaching BranchGroups).
>
> From: Michael Saunders [mailto:[EMAIL PROTECTED]
> Sent: Monday, February 24, 2003 12:29 PM
> Subject: Re: [JAVA3D] GeometryUpdater
>
> Mark,
>
> Is this really true? I have created TriangleStripArray's using =
> COORDINATES | BY_REFERENCE | USE_NIO_BUFFER as my mask and I simply =
> delivered the strip coordinates via a call to the =
> setCoordRefBuffer(J3DBuffer coords). I didn't have to implement the =
> GeometryUpdater interface at all. It all seems to work fine. What am I =
> missing.

Sean is correct.  You should use GeometryUpdater whenever you're using
BY_REFERENCE geometry and you're updating it while it's in a live scene
graph or a compiled branch group.  When you create the geometry array
it's not live so you don't need to go through the interface.

If you have a live or compiled by-reference node and you don't use this
interface, then things may work fine, but it's timing dependent.  You
run the risk of say, updating your geometry while it's being set up for
transmission to the graphics hardware, or corrupting the internal scene
graph representation as it's being built.

With concurrent modification of data it's impossible to predict what
will happen; the results are undefined.  One thing for sure: bugs
resulting from concurrent modification are *very* difficult to track
down, as their effects tend to be delayed and have very little apparent
correlation with the cause.

-- Mark Hood

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