]> git.mxchange.org Git - simgear.git/commitdiff
Initialize glut before using it.
authorehofman <ehofman>
Sun, 27 Nov 2005 09:46:58 +0000 (09:46 +0000)
committerehofman <ehofman>
Sun, 27 Nov 2005 09:46:58 +0000 (09:46 +0000)
simgear/screen/RenderTexture.cpp
simgear/screen/TestRenderTexture.cpp

index f27813f9ad84452e700b7abd59d82a3a5a76bbde..f45234c7360f371d9038bb8632f99b08d422b6ae 100644 (file)
@@ -1,4 +1,4 @@
-//---------------------------------------------------------------------------
+reateContext//
 // File : RenderTexture.cpp
 //---------------------------------------------------------------------------
 // Copyright (c) 2002-2004 Mark J. Harris
@@ -494,7 +494,7 @@ bool RenderTexture::Initialize(int width, int height,
 
                 _hGLContext = glXCreateContextPtr(_pDisplay, visInfo,
                                                _bShareObjects ? context : NULL,
-                                               GL_TRUE);
+                                               True);
                 if (!_hGLContext)
                 {
                     return false;
index 8b018cb8240fafc46859b5538507ed9120939240..2f2d1cf918728bbc03d1a4d2d11bd177d5641fc9 100644 (file)
@@ -305,8 +305,10 @@ void _Display()
 // Function            : main
 // Description     : 
 //---------------------------------------------------------------------------
-int main()
+int main(int argc, char *argv[])
 {
+    int argn = argc;
+    glutInit(&argn, argv);
     glutInitDisplayMode(GLUT_RGB | GLUT_DEPTH | GLUT_DOUBLE);
     glutInitWindowPosition(50, 50);
     glutInitWindowSize(512, 512);