I dont know how it is with other peoples systems but mine always jumped when travelling to an object which the texture hasnt been loaded for yet.
I added this method to render.cpp
void Renderer::loadAllTextures(SolarSystem* system)
it recursivly goes through a solarsystem loading the textures for each body with void Renderer::loadTextures(Body* body)
I execute this once when celestia starts up and everytime the observer travels to a new system.
Advantages:
Once loaded travelling around a solarsystem remains smooth. Except when approaching an object with a large *.3ds model (apollo). Any chance of a preloadMesh method Chris?
Disadvantages :
Initial memory usage goes from 16M to 60M.
There is a larger noticable pause when starting and when travelling to a new system with lots of new textures. (the 18 Sco addon for example.)
these changes are in the mostlyharmless cvs tree.
chris,
Ive also created a getMass method for stars. its very similar to your getTemp method and is based of various internet data I found. It is reasonablly accurate for the main sequence stars and severly fudged for the other sequence stars.
Preloading textures for entire solarsystem
-
- Posts: 986
- Joined: 16.08.2002
- With us: 22 years 3 months
- Location: USA, East Coast
Preloading textures for entire solarsystem
marc wrote:Ive also created a getMass method for stars. its very similar to your getTemp method and is based of various internet data I found. It is reasonablly accurate for the main sequence stars and severly fudged for the other sequence stars.
This sounds interesting, what is it?
Mike M.
-
Topic authormarc
- Posts: 426
- Joined: 13.03.2002
- With us: 22 years 8 months
- Location: Outback Australia
That method is now used to complete the gravity effects which is part of my MH hack.
The gravity model is complete for the randomly generated systems but still may need some entries filled out for the sol system in the ssc file. Although the missing entries arent noticeable as the values are relativly small.
The gravity model is complete for the randomly generated systems but still may need some entries filled out for the sol system in the ssc file. Although the missing entries arent noticeable as the values are relativly small.
Marc Griffith http://mostlyharmless.sf.net