Where is the default field of view of 25 something degrees set? I looked in start.cel, celestiacore.cpp, observer.cpp, simulation.cpp and render.cpp and only found numbers for a 45 degree fov.
I'll use this to set up '|' to reset the fov to the default value so I won't need to take a long time to zoom out from close to the minimum fov. The '|' key is also the '\' key so the key would both reset time to the default rate and reset the fov to the default value.
Default fov
- t00fri
- Developer
- Posts: 8772
- Joined: 29.03.2002
- Age: 22
- With us: 22 years 7 months
- Location: Hamburg, Germany
Code: Select all
void CelestiaCore::setFOVFromZoom()
{
for (std::vector<View*>::iterator i = views.begin(); i < views.end(); i++)
if ((*i)->type == View::ViewWindow)
{
double fov = 2 * atan(height * (*i)->height / (screenDpi / 25.4) / 2. / distanceToScreen) / (*i)->zoom;
(*i)->observer->setFOV((float) fov);
}
}
FOV is certainly a variable that is computed from the active window height assuming a standard distance from the monitor screen. This became particularly relevant in connection with introducing /multiviews/ a long time ago. The default value may be reset from celestia.cfg.
I had originally introduced the FoV toggle operation for the middle mouse button between the actual zoom position and the standard value. But I assume everybody is aware of that functionality. Christophe generalized the stuff to multiviews.
Bye Fridger
- t00fri
- Developer
- Posts: 8772
- Joined: 29.03.2002
- Age: 22
- With us: 22 years 7 months
- Location: Hamburg, Germany
hank wrote:t00fri wrote:I had originally introduced the FoV toggle operation for the middle mouse button between the actual zoom position and the standard value. But I assume everybody is aware of that functionality.
Not everyone has three buttons on their mouse.
- Hank
Is there really still anyone around without a /wheel/ mouse? If so --> buy a new one for 10$. If people don't have a 3d card, Celestia also does'nt work
Pushing on the wheel is what toogles the fov from zoom to normal and back.
But I think mouse drivers can always emulate the middle button. At least my Logitech driver does.
Bye Fridger
-
- Developer
- Posts: 3776
- Joined: 04.02.2005
- With us: 19 years 9 months