Tried to make wxGLCanvas work again. WIP.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3929 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robert Roebling
1999-10-11 15:24:49 +00:00
parent 4c61bdabd6
commit 147bc49159
11 changed files with 139 additions and 58 deletions

View File

@@ -27,6 +27,7 @@
#include "penguin.h"
#include <GL/glu.h>
#include "wx/gtk/win_gtk.h"
#define VIEW_ASPECT 1.3
@@ -105,6 +106,14 @@ void TestGLCanvas::OnPaint( wxPaintEvent& event )
if (!GetContext()) return;
#endif
printf( "on refresh.\n" );
int x,y;
GtkMyFixed *fixed = GTK_MYFIXED(m_wxwindow);
gdk_window_get_size( m_wxwindow->window, &x, &y );
printf( "-> window %d %d.\n", x, y );
gdk_window_get_size( fixed->bin_window, &x, &y );
printf( "-> bin_window %d %d.\n", x, y );
SetCurrent();
/* initialize OpenGL */
@@ -146,6 +155,8 @@ void TestGLCanvas::OnSize(wxSizeEvent& event)
int width, height;
GetClientSize(& width, & height);
printf( "onsize %d %d.\n", width, height );
#ifndef __WXMOTIF__
if (GetContext())
#endif