I've tried something similar before. I managed to get it working for an object at the equator. I have no idea for other longitudes and latitudes, and i doubt its possible.
I had a 3DS model of some buildings orbiting the earth with its SemiMajorAxis equal to the radius of the earth.
Code: Select all
"Building" "Sol/Earth"
{
Mesh "building.3ds"
Radius 2 #kilometers
CustomOrbit "building"
EllipticalOrbit {
Period 1
SemiMajorAxis 6378 #radius of the earth
}
}
There are two things that will cause trouble.
1. Celestia re-calculates the center of each mesh when it is loaded. This will cause your building to be rendered with half of it underground. I modified the celestia code to disable this. You can get around this by mirroring your entire 3ds model, (the mirror will be underground).
2. Celestia is not designed to handle drawing any objects that are close to each other or are overlapping, it doesnt need too. The soloution has something to do with sharing depthbuckets (openGl stuff). Because of this your models will dissapear when too close to the earth at all but a few viewing angles.
The second point is the one that kills your idea. The code responsible has been commented by Chris (render.cpp I think) you'll have to ask someone with some OpenGL nouse to modify it.