Initialize OpenGL 2.0 after OpenGL context is created (otherwise initialization fails under mswin)
git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@1275 7f0cb862-5218-0410-a997-914c9d46530a
This commit is contained in:
parent
104a238a57
commit
0629737fa2
@ -28,7 +28,6 @@
|
|||||||
#define FREEGLUT_BUILDING_LIB
|
#define FREEGLUT_BUILDING_LIB
|
||||||
#include <GL/freeglut.h>
|
#include <GL/freeglut.h>
|
||||||
#include "fg_internal.h"
|
#include "fg_internal.h"
|
||||||
#include "fg_gl2.h"
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* TODO BEFORE THE STABLE RELEASE:
|
* TODO BEFORE THE STABLE RELEASE:
|
||||||
@ -381,8 +380,6 @@ void FGAPIENTRY glutInit( int* pargc, char** argv )
|
|||||||
if( (mask & (XValue|YValue)) == (XValue|YValue) )
|
if( (mask & (XValue|YValue)) == (XValue|YValue) )
|
||||||
fgState.Position.Use = GL_TRUE;
|
fgState.Position.Use = GL_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
fgInitGL2();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -28,6 +28,7 @@
|
|||||||
#define FREEGLUT_BUILDING_LIB
|
#define FREEGLUT_BUILDING_LIB
|
||||||
#include <GL/freeglut.h>
|
#include <GL/freeglut.h>
|
||||||
#include "fg_internal.h"
|
#include "fg_internal.h"
|
||||||
|
#include "fg_gl2.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* TODO BEFORE THE STABLE RELEASE:
|
* TODO BEFORE THE STABLE RELEASE:
|
||||||
@ -147,6 +148,8 @@ void fgOpenWindow( SFG_Window* window, const char* title,
|
|||||||
#endif
|
#endif
|
||||||
window->Window.attribute_v_coord = -1;
|
window->Window.attribute_v_coord = -1;
|
||||||
window->Window.attribute_v_normal = -1;
|
window->Window.attribute_v_normal = -1;
|
||||||
|
|
||||||
|
fgInitGL2();
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Reference in New Issue
Block a user