--- /dev/null
+.deps
+Makefile
+Makefile.in
+fgpanel
# include <config.h>
#endif
-using namespace std;
+#include "FGGLApplication.hxx"
+#ifdef HAVE_WINDOWS_H
+#include <windows.h>
+#endif
+
+
#include <map>
#include <algorithm>
#include "ApplicationProperties.hxx"
struct FGFontCache::fnt *
FGFontCache::getfnt(const char *name, float size, float slant)
{
- string fontName(name);
+ std::string fontName(name);
FntParams fntParams(fontName, size, slant);
PuFontMap::iterator i = _puFonts.find(fntParams);
if (i != _puFonts.end())
bool FGFontCache::initializeFonts()
{
- static string fontext("txf");
+ static std::string fontext("txf");
init();
ulDir* fontdir = ulOpenDir(_path.c_str());
if (!fontdir)
if (path.extension() == fontext) {
fntTexFont* f = new fntTexFont;
if (f->load((char *)path.c_str()))
- _texFonts[string(dirEntry->d_name)] = f;
+ _texFonts[std::string(dirEntry->d_name)] = f;
else
delete f;
}
//
#ifndef __FGFONTCACHE_HXX
#define __FGFONTCACHE_HXX
+#include <simgear/math/SGMath.hxx>
#include <simgear/misc/sg_path.hxx>
#include <simgear/props/props.hxx>
#include <plib/pu.h>
// Path to the font directory
SGPath _path;
- typedef map<const string, fntTexFont*> TexFontMap;
- typedef map<const FntParams, fnt*, FntParamsLess> PuFontMap;
+ typedef std::map<const std::string, fntTexFont*> TexFontMap;
+ typedef std::map<const FntParams, fnt*, FntParamsLess> PuFontMap;
TexFontMap _texFonts;
PuFontMap _puFonts;
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
//
+
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
#include "FGGLApplication.hxx"
-#include "GL/gl.h"
-#include "GL/glut.h"
+#ifdef HAVE_WINDOWS_H
+#include <windows.h>
+#define snprintf sprintf_s\r
+#endif
+#include <GL/gl.h>
+#include <GL/glut.h>
#include <iostream>
#include <exception>
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
//
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#ifdef HAVE_WINDOWS_H
+#include <windows.h>
+#endif
#include "FGPNGTextureLoader.hxx"
#include <GL/glu.h>
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
//
+
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#ifdef HAVE_WINDOWS_H
+#include <windows.h>
+#endif
+
+#include "FGGLApplication.hxx"
#include "FGPanelApplication.hxx"
#include <GL/gl.h>
#include <GL/glut.h>
{
glAlphaFunc(GL_GREATER, 0.1);
glutSetCursor( GLUT_CURSOR_NONE );
- ApplicationProperties::fontCache.initializeFonts();
+ ApplicationProperties::fontCache.initializeFonts();
}
void FGPanelApplication::Reshape( int width, int height )
{
switch( key ) {
case 0x1b:
- if( gameMode ) glutLeaveGameMode();
- else glutDestroyWindow( windowId );
+ exit(0);
break;
}
}
double elapsed_us = (current_time_stamp - last_time_stamp).toUSecs();
if ( elapsed_us < frame_us ) {
double requested_us = frame_us - elapsed_us;
+#ifdef _WIN32
+ ::Sleep ((int)(requested_us / 1000.0)) ;
+#else
usleep ( (useconds_t)(requested_us ) ) ;
+#endif
}
// busy wait timing loop.
//
#include "FGGLApplication.hxx"
#include "FGPanelProtocol.hxx"
+#include <simgear/math/SGMath.hxx>
#include <simgear/structure/subsystem_mgr.hxx>
#include <simgear/props/props.hxx>
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
//
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#ifdef HAVE_WINDOWS_H
+#include <windows.h>
+#endif
+
+#ifdef WIN32
+#define strtof strtod
+#endif
+
#include "FGPanelProtocol.hxx"
#include "ApplicationProperties.hxx"
#include <simgear/io/sg_socket.hxx>
//
#ifndef __FGPANELPROTOCOL_HXX
#define __FGPANELPROTOCOL_HXX
+#include <simgear/math/SGMath.hxx>
#include <simgear/structure/subsystem_mgr.hxx>
#include <simgear/props/props.hxx>
#include <simgear/io/iochannel.hxx>
// Reader for sgi's .rgb format.
// specification can be found at http://local.wasp.uwa.edu.au/~pbourke/dataformats/sgirgb/sgiversion.html
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#ifdef HAVE_WINDOWS_H
+#include <windows.h>
+#endif
+
#include "FGRGBTextureLoader.hxx"
#include <GL/gl.h>
#include <GL/glu.h>
#include <plib/fnt.h>
#include <simgear/debug/logstream.hxx>
+#include <simgear/math/SGMath.hxx>
#include <simgear/misc/sg_path.hxx>
#include "panel.hxx"
#include <string.h> // for strcmp()
#include <simgear/compiler.h>
+#include <simgear/math/SGMath.hxx>
#include <simgear/structure/exception.hxx>
#include <simgear/debug/logstream.hxx>
#include <simgear/misc/sg_path.hxx>