News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

wxGLCanvas confusion, can't find out how to use it

Started by rucs_hack, August 05, 2010, 05:56:24 PM

Previous topic - Next topic

rucs_hack

I'm using wxWidgets to create an opengl viewer for a project of mine (porting an existing app to wxWidgets). I've built the gui and put the wxGLCanvas widget on the main window inside a BoxSizer,where it shares the main wndow with some sliders for basic rotations. It all compiles fine but I can't for the life of me find out how I'm supposed to actually draw with it.

Specifically, the wxGLCanvas widget is declared private, and I can't find out how I'm meant to access its Render/refresh/resize events. All the examples I've found have people inheriting from wxGLCanvas and using that, and that doesn't seem to apply, since I used the wxGLCanvas from the 'Advanced' tab. The most I can get is:

void handleDisplay(wxGLCanvas * canvas) {

}

from double clicking on the wxGLCanvas itself. I can't find any documentation about that either :(

Pretty much going round in circles here, any nudges in the right direction would be vastly appreciated.