Better initialization of gtkglext so it doesn't works
only for depth >= 24bpp
This commit is contained in:
parent
b82970ad10
commit
2bef4e40b8
|
@ -154,11 +154,11 @@ initialise_gdk_3d( void) {
|
|||
}
|
||||
|
||||
int
|
||||
init_opengl_gdk_3Demu( void) {
|
||||
init_opengl_gdk_3Demu( GdkDrawable * drawable) {
|
||||
GdkGLConfig *glconfig;
|
||||
|
||||
/* create the off screen pixmap */
|
||||
target_pixmap = gdk_pixmap_new ( NULL, 256, 192, 24);
|
||||
target_pixmap = gdk_pixmap_new ( drawable, 256, 192, -1);
|
||||
|
||||
if ( target_pixmap == NULL) {
|
||||
g_print (_("*** Failed to create pixmap.\n"));
|
||||
|
|
|
@ -27,6 +27,6 @@
|
|||
*/
|
||||
|
||||
int
|
||||
init_opengl_gdk_3Demu( void);
|
||||
init_opengl_gdk_3Demu( GdkDrawable * drawable);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -497,7 +497,7 @@ common_gtk_glade_main( struct configured_features *my_config) {
|
|||
#ifdef GTKGLEXT_AVAILABLE
|
||||
if ( !use_null_3d) {
|
||||
/* setup the gdk 3D emulation */
|
||||
if ( init_opengl_gdk_3Demu()) {
|
||||
if ( init_opengl_gdk_3Demu(GDK_DRAWABLE(pWindow->window))) {
|
||||
NDS_3D_SetDriver(1);
|
||||
|
||||
if (!gpu3D->NDS_3D_Init()) {
|
||||
|
|
|
@ -151,11 +151,11 @@ _oglrender_init( void) {
|
|||
}
|
||||
|
||||
int
|
||||
init_opengl_gdk_3Demu( void) {
|
||||
init_opengl_gdk_3Demu( GdkDrawable * drawable) {
|
||||
GdkGLConfig *glconfig;
|
||||
|
||||
/* create the off screen pixmap */
|
||||
target_pixmap = gdk_pixmap_new ( NULL, 256, 192, 24);
|
||||
target_pixmap = gdk_pixmap_new ( drawable, 256, 192, -1);
|
||||
|
||||
if ( target_pixmap == NULL) {
|
||||
g_print ("*** Failed to create pixmap.\n");
|
||||
|
|
|
@ -27,6 +27,6 @@
|
|||
*/
|
||||
|
||||
int
|
||||
init_opengl_gdk_3Demu( void);
|
||||
init_opengl_gdk_3Demu( GdkDrawable * drawable);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -1925,7 +1925,7 @@ common_gtk_main( struct configured_features *my_config)
|
|||
if ( !use_null_3d) {
|
||||
/* setup the gdk 3D emulation */
|
||||
#ifdef GTKGLEXT_AVAILABLE
|
||||
if ( init_opengl_gdk_3Demu()) {
|
||||
if ( init_opengl_gdk_3Demu(GDK_DRAWABLE(pWindow->window))) {
|
||||
#else
|
||||
if ( init_osmesa_3Demu()) {
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue