I don't think java3d support composite bounds (a collection of bounds
attached to a single Node) so the technique described below would require an
implementation of bounds that managed a list of sub-bounds. A linear search
through the sub-bounds would still be faster than searching through the
geometry.  Alternatively, you could create a bunch of non-renderable Nodes,
each having being bounded with one of the sub-bounds, and register a bounds
with the real shape3d which was an implementation which guarenteed it had no
dimensions.  The fake-nodes and their bounds would still be pickable and
collidible, and there would be a link back to the main object... so this
would turn over the management of the bounds to java3d's spatial tree and
would be more efficient than an implementation of Bounds which used a linear
search through the sub-bounds.

Make sense?  So the question is how well Java3d would handle the
proliferation of bounds this technique would use.

Dave Yazel

----- Original Message -----
From: David Yazel <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Saturday, June 02, 2001 1:52 PM
Subject: [JAVA3D] Self-calculating bounds idea


Hello everyone...

I had a thought today.  I was working on some code which turns our complex
structures into a series of bounding boxes.  The bounding boxes define
solids from non-solids.  So while a house might have many geometry arrays
and shapes which make up a single room, in its simplest form 6 boxes can be
used to define the solid areas.  If we use java3d's automatic bounds, and
you have a single shape which forms a convex surface, like 4 walls of a
room, the bounds will encompass the entire room, thus making it pretty
useless for collision detection and avoidance, forcing us (as we do now) to
drop to the geometry level.  The code I was working on is for the server to
have an adequate representation of geometry, without having to actually
reference and use the geometry.

But it got me thinking... what if I turned off automatic bounds and instead
registered the collection of bounds which I compute.  The computation I am
currently working on is quite complex since it uses ray casting to map out
the models, and is only good as an offline pre-process step, but the bounds
could be stored with with object.

Question to Sun, and to everyone here, is what the impact would be in
replacing the single bounding sphere with 10,20 or even 100 bounding boxes?
In fact when we move to the next step of our geometry engine and start using
curved surfaces we were planning on using BoundingPolytops.  Would picking
slow down or would it actually remain very speedy and infact eliminate the
need to go to the geometry level to find collidable serfaces?  I believe I
read that Sun uses a very advanced spatial tree to store and search their
bounds, so my thinking is this would acheive excellent results.

Thoughts?

Dave Yazel
www.cosm-game.com

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