Discussion:
OpenGL compilation problem
(too old to reply)
John
2010-03-30 15:41:39 UTC
Permalink
Hi,

I'm trying to write an application based on wxWidgets OpenGL classes

So I have downloaded wxWidgets 2.9.0 for windows and compiled it
( latest mingw ) with the required switches :

In config.gcc USE_OPENGL = 1
In setup.h #define wxUSE_GLCANVAS 1

Compilation was smooth and I can run all application UNLESS they use
wxWidgets opengl classes.... !

For example with the following class :

#include <wx/wx.h>
#include <wx/glcanvas.h>

class MyCanvasOpenGL : public wxGLCanvas
{
public:

..... };


Compiler says :
`MyCanvasOpenGL' does not have any field named `wxGLCanvas'

I've checked that all headers are there ( in wxWidgets/include
and mingw/iclude/gl ), Have also checked libraries : it seems to be
OK.


Does anybody have an idea ?

Thanx

John
Vadim Zeitlin
2010-03-31 15:23:01 UTC
Permalink
Post by John
Compilation was smooth and I can run all application UNLESS they use
wxWidgets opengl classes.... !
Have you tried building the (OpenGL) samples? E.g. samples/opengl/cube?
Post by John
#include <wx/wx.h>
#include <wx/glcanvas.h>
class MyCanvasOpenGL : public wxGLCanvas
{
..... };
`MyCanvasOpenGL' does not have any field named `wxGLCanvas'
This looks like a syntax error in some code that you don't show. There is
nothing that could provoke this error message in the snippet shown above.

Regards,
VZ
--
TT-Solutions: wxWidgets consultancy and technical support
http://www.tt-solutions.com/
Continue reading on narkive:
Loading...