Tim Bray wrote:
>
> I'm modeling an (effectively) infinitely large surface by cleverly
> stitching things into the scene graph ahead of them and whipping them
> out behind as the user moves around.  Works OK, except the memory
> usage seems to grow monotonically until after a couple minutes java
> barfs on out-of-memory.

This has been a well documented bug with Java3D in its shape nodes.
Basically what seems to be happening is that the Shape3D objects and/or
their geometry (nobody seems to have really worked out exaclty what is
leaking AFAIK) are not being GCd internally. I can't remember the exact
reason off the top of my head but I seem to recall that it is something
on the native side of the code not releasing their memory.

Unfortunately, there is no real solution to this. One of the other
posters has suggested re-using the geometry, which is about the only
thing that you can do.

> Hmm... I do tend to place things by stacking up several transforms
> rather than combining them, are transforms brutally expensive in memory?

The transforms aren't, maybe doing the underlying operations may be CPU
wise to start with but memory intensive - no. These can make a
difference to performance based on how you've structured the scenegraph
(use of branchgroups etc), but shouldn't make much difference otherwise.
--
Justin Couch                                   Author, Java Hacker
Snr Software Engineer                     [EMAIL PROTECTED]
ADI Ltd, Systems Group              http://www.vlc.com.au/~justin/
Java3D FAQ:       http://tintoy.ncsa.uiuc.edu/~srp/java3d/faq.html
-------------------------------------------------------------------
"Look through the lens, and the light breaks down into many lights.
 Turn it or move it, and a new set of arrangements appears... is it
 a single light or many lights, lights that one must know how to
 distinguish, recognise and appreciate? Is it one light with many
 frames or one frame for many lights?"      -Subcomandante Marcos
-------------------------------------------------------------------

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