Florin, Thanks for these numbers! They will be very useful.
Ian On Thu, 27 Feb 2003, Florin Herinean wrote: > One last thing to consider: moving to GL4Java is like using pure immediate > mode in j3d. You have at that point (almost) total liberty of what you're > doing. You can optimize for memory, but at the expense of performance. If > performance is not a concern to you, then here are some figures: > > Approach 1: 27000 TG, scenegraph rendering: 140 MB, 0.221 FPS > Approach 1: 27000 TG, pure immediate mode rendering: 48 MB memory, 0.149 FPS > > Approach 2: 900 TG, scenegraph rendering: 16 MB, 0.241 FPS > Approach 2: 900 TG, pure immediate mode rendering: 8 MB memory, 0.189 FPS > > My most complex model, scenegraph rendering: 250 MB memory, 1.5 FPS !!! > My most complex model, pure immediate mode rendering: 84 MB memory, 0.2 FPS > > The pure immediate mode renderer is "brute force", no optimizations, no > scenegraph, no groups, transform groups or shape3d's. The only reused things > from j3d were the vecmath package, the Appearance class with associated > classes, and the Geometry classes. I think that with some effort, I could > have improved the performance, but I don't have any figures now. > > Cheers, > > Florin > > > -----Urspr�ngliche Nachricht----- > Von: Florin Herinean [mailto:[EMAIL PROTECTED] > Gesendet: Mittwoch, 26. Februar 2003 17:17 > An: [EMAIL PROTECTED] > Betreff: [JAVA3D] AW: [JAVA3D] AW: [JAVA3D] AW: [JAVA3D] Java 3D or > GL4Java (also s olution to la rge number of geometry problem) > > > Let's get some more numbers: > > SceneGraph displays 27000 spheres. > > Approach 1: > > 27000 TG + 27000 Shapes + 1 Appearance + 1 Geometry, uses aprox 140 MB. That > means roughly 5k per TG+Shape combination, and a grand total of 54000 > objects to be eventually garbage collected > > Approach 2: > > 900 TG + 900 Shapes + 1 Appearance + 30 geometries, uses aprox 15 MB, and > makes a grand total of 1830 objects. > > In both cases, one Sphere uses aprox. 400 vertices and normals (no texture) > - 9.6 kb > > We have made an economy of (26100 tg+shapes) * 5k = 130MB and only used for > the extra 30 geometry 288 kb > > With a quick calculus, it's easy to observe that <b>for that specific > problem, i.e. 27000 spheres</b>, the optimum memory usage is obtained with > 250 TG+S and 108 geometries per shape, leading to a total memory usage of > aprox 2.5 MB with only 610 objects !!! > > So, in a scenegraph containing only homogeneous spheres, the optimum is : TG > = sqrt(2 * n-spheres), Geom-per-shape = n-spheres/TG > > Cheers, > > Florin > > -----Urspr�ngliche Nachricht----- > Von: N. Vaidya [mailto:[EMAIL PROTECTED] > Gesendet: Mittwoch, 26. Februar 2003 16:20 > An: [EMAIL PROTECTED] > Betreff: Re: [JAVA3D] AW: [JAVA3D] AW: [JAVA3D] Java 3D or GL4Java (also > solution to la rge number of geometry problem) > > > Hi Ian and Florin, > > This problem of when and when not to use TGs was examined > by Chien and and to some extent by me sometime last > year IIRC. I think it is a compromise and mostly app. specific. > Chien gave the useful stat. that TG + Shape3D takes ~3.6K > (off the top of my head). > > http://swjscmail1.java.sun.com/cgi-bin/wa?A2=ind0204&L=java3d-interest&P=R76 > 84&D=1&O=D&m=29246 > > > http://swjscmail1.java.sun.com/cgi-bin/wa?A2=ind0204&L=java3d-interest&P=R15 > 076&D=1&H=0&O=D&T=1&m=29246 > > Rgds > > Raj Vaidya > > ==========================================================================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".
