The way I do particles is much like how Shawn Kendall described he did
particles a while back. In fact, I copied his idea. :) All the graphics I
use are on a constant z coordinate; only the x and y coords change. The
TriangleArray just is a bunch of quads (two tris) with a bullet texture on
them. The camera is a few z value "above" a spaceship that fires the
bullets. The camera moves along with the spaceship (When I move the ship,
I translate the camera along with it, but not the z coord to keep it above
the ship). I move the particles simply by using the updateData method and
manually change the TriangleArray coords for only the particles that are
"active" (I use the setValidVertexCount to render those).

It seems the particles have a limit bound around the (0, 0) coord. When
move the ship far enough away from the origin, whatever bullets I fire
just disappear. I tried setBounds, but I guess it's used strictly for
collisions and not from frustum culling (or whatever java3d is using to
culling out the TriangleArray).

Oh yeah, I set the Z-values for all the graphics at 0.0.

David Ko
JHU

On Thu, 14 Dec 2000, John Wright wrote:

> David,
>
> Is your particle system a behavior? Is it possible that you are moving
> the view outside of the scheduling bounds for that behavior?
>
> Other possible ideas... are you moving your view so far back that your
> particles are beyond the back clipping distance?
>
> - John Wright
> Starfire Research
>
> David Ko wrote:
> >
> > I've asked this question before, but I guess I'll ask it again. How do you
> > set Shape3D (or possibly the BranchGroup that contains it) so that it
> > renders no matter where the View is. I've tried setBounds with a huge
> > boundingsphere, but it doesn't seem to work. The reason I'm doing this is
> > that I'm using a TriangleArray to render particles. However, when I change
> > the camera position (using the View's transform matrix), and I go out from
> > a certain range, all the particles disappear. Imagine top-down game of a
> > spaceship and the camera is always hovering over the ship, moving with it.
> >
> > Thank you,
> > David Ko
> > JHU
> >
> > ===========================================================================
> > 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