Page 1 of 1

Where to make optimizations in Celestia

Posted: 10.01.2005, 22:29
by Brendan
Cham wrote:I have the impression that Celestia is the most heavily demanding piece of software ever wrote.

maxim wrote:It's simply not very optimized. I think the initial design didn't cover the current usage load.


What optimizations could be made and where? :? The easiest place for me to help out may be loading addons.

Brendan

Re: Where to make optimizations in Celestia

Posted: 10.01.2005, 23:32
by t00fri
Brendan wrote:
Cham wrote:I have the impression that Celestia is the most heavily demanding piece of software ever wrote.

maxim wrote:It's simply not very optimized. I think the initial design didn't cover the current usage load.

What optimizations could be made and where? :? The easiest place for me to help out may be loading addons.

Brendan


Well /culling/ of objects is the main issue.

Quite some time ago I spent weeks scanning through the code of render.cpp. Since there are so many objects to render, culling is crucial. For certain configurations I managed to get speed-ups by a factor of 30!

The frustration is due to the fact that any objects outside the field of view need not be rendered. Yet, in order to find out whether an object (e.g. an asteroid) is outside the FOV, one needs to solve Kepler's equation first. That takes time...
I devised all sorts of approximations thereof. Yet due to our /exponential/ zooming, those have a tendency to break down easily...

This is really tedious and most delicate matters. So,
at some point, I gave up, well aware that there is still much room for further work...

Bye Fridger

Posted: 10.01.2005, 23:55
by Cham
My only complains about Celestia performances is when I show nebulae. I then have all the galaxies rendered with all the nebulae billboards. If I have the bad luck of turning my FOV in direction of the Milky Way, Celestia slow down to a crawl ! 8O and it gets reaaaaally painfull !

There should be two commands here : one for the galaxies alone, and another for the nebulae (billboards) alone. PLEASE ?

Posted: 11.01.2005, 01:26
by dirkpitt
Cham wrote:My only complains about Celestia performances is when I show nebulae. I then have all the galaxies rendered with all the nebulae billboards. If I have the bad luck of turning my FOV in direction of the Milky Way, Celestia slow down to a crawl ! 8O and it gets reaaaaally painfull !


That, and the 1+ second disk read whenever the textures for a freshly visible object need to be loaded (got a particularly slow notebook hard disk, unfortunately :-(. Perhaps this could be solved by threaded texture loading. Also I'm not entirely familiar with the engine code so I may very well be wrong but it feels like textures aren't cached in an LRU but in an unlimited list because after I zoom into a mega hires virtual textured sun that exceeds my physical memory, my disk is still thrashing when I'm 50,000 light years away because of previously-loaded textures that are no longer visible. There could be room for improvement here.

Posted: 11.01.2005, 10:07
by Harry
dirkpitt wrote:That, and the 1+ second disk read whenever the textures for a freshly visible object need to be loaded (got a particularly slow notebook hard disk, unfortunately :-(

In my experience this is not so much the time needed to load a texture, but the time to decode JPG/PNG images. Converting all textures to DDS improved things for me, and it reduces the amount of memory needed too. However you should check first if your notebook actually displays DDS textures, and you may get smaller improvements if you got a very fast CPU and a really slow HD.

Harald

Posted: 11.01.2005, 12:22
by dirkpitt
Harry wrote:
dirkpitt wrote:That, and the 1+ second disk read whenever the textures for a freshly visible object need to be loaded (got a particularly slow notebook hard disk, unfortunately :-(
In my experience this is not so much the time needed to load a texture, but the time to decode JPG/PNG images. Converting all textures to DDS improved things for me, and it reduces the amount of memory needed too. However you should check first if your notebook actually displays DDS textures, and you may get smaller improvements if you got a very fast CPU and a really slow HD.

Harald


That's good to know. DDS indeed works for me but I've never benchmarked it. I'll have to try that, thanks.

re

Posted: 19.01.2005, 10:51
by John Van Vliet
also if you use .png's like i do try resaving them with a compresion of 1 and not 7 or 9 like my dl's are

i have found that using a comp. of 1 will speed it up -aprox. 25 to 50 %