Revision 701764

Go back to digest for 26th August 2007

Features in Educational

James Bowlin committed changes in /trunk/KDE/kdeedu/kstars/kstars:

Am now giving reasonable (but not always perfect) progress percentages when reading and re-reading stars.dat. The percentages should now end near 100% even if we are not reading in the entire stars.dat file.

The new data file starlnum.idx has the line numbers of roughly 90 different star magnitudes which enables the more reasonable percentages. If the stars.dat file changes then starlnum.idx should be regenerated via:

$ ./ stars.dat > starlnum.idx

Have stopped the one draw cycle delay before re-reading star data because the skymap is getting erased anyway.

Tracked down a several second delay after reading the star data to a faulty implementation of QTextStream::pos(). This function can take 7 or 8 seconds to complete! I have a feeling they go back and re-read the entire file. I implemented a trivial work-around by simply keeping track of the file position myself inside our read loop:

m_lastFilePos += line.length() + 1;

Also did some minor code clean up in StarComponent and KSFileReader.

File Changes

Added 2 files
  • /trunk/KDE/kdeedu/kstars/kstars/data
  •   /
  •   /starlnum.idx
Modified 7 files
  • /trunk/KDE/kdeedu/kstars/kstars
  •   /ksfilereader.cpp
  •   /ksfilereader.h
  •   /data/CMakeLists.txt
  •   /skycomponents/constellationboundarylines.cpp
  •   /skycomponents/deepskycomponent.cpp
  •   /skycomponents/starcomponent.cpp
  •   /skycomponents/starcomponent.h
9 files changed in total