[Kstars-devel] SatLIb verification

James Bowlin bowlin at mindspring.com
Sat Jun 7 21:48:11 CEST 2008


On Sat June 7 2008, Bernard GODARD wrote:
> On another note is it normal that almost everything is commented out
> in SkyMapComposite::update?

This is okay.  I did it.  One of the biggest changes in 4.x was the 
addition of a spatial index.  It speeds things up by only drawing 
objects that are on screen (or nearly on screen).  Before the index
we would go through a list of 125,000 stars even though only a tiny
portion of the sky was on screen.

As part of this effort, I also moved the updates of indexed objects into 
the draw loop so that only objects that are possibly on screen get 
updated.  This also saves time because we are now no longer updating 
objects that we know will never be displayed.  I call this Just in Time
Updating (JiT updating) and it is analogous to Just in Time compiling
in languages such as Java.

But since this was rather new, I left the old update code in place and 
just commented out the calls that were no longer required.  That way if
there was something I hadn't thought about that would require that all
XXX objects get updated, it would be easy to restore the old behavior.

-- 
Peace, James


More information about the Kstars-devel mailing list