mod_sim_main.cc File Reference

main(). main() is compiled separately to avoid the problem of multiple definitions of main() when linking tests. More...

#include "base.hh"
#include "base_file.hh"
#include "gfx.hh"
#include "eng.hh"
#include "mod_base.hh"
#include "mod_sim.hh"

Defines

#define MOD_SIM_MAIN_CC   1

Functions

int main (int argc, char **argv)


Detailed Description

main(). main() is compiled separately to avoid the problem of multiple definitions of main() when linking tests.

Id
LastChangedDate

Author:
Jim E. Brooks http://www.palomino3d.org

Define Documentation

#define MOD_SIM_MAIN_CC   1


Function Documentation

int main ( int  argc,
char **  argv 
)

main.

Multiple C++ exception handlers: A minor problem with Palomino being C++ and GLUT being C is that call-stack frames can become a mixture of C and C++. That happens at the point were glutMainLoop() is called: GLUT generates C stack frames. C++ cannot unwind frames generated by C code, so the C++ run-time will resort to calling std::terminate(). In that case, effectively, C++ exceptions cannot be caught. But a workaround is to put new "try" blocks inside GLUT callbacks, since further frames after "try" will be generated by C++ which can be unwound.

Palomino 3D Engine documents generated by doxygen 1.5.3 on Fri Nov 23 11:26:16 2007