Hello Keyan,
On 05/10/2011 10:36 AM, Keyan wrote:
> I tried to compile with Qt4 support, but ended up with the following
> compiler-errors:
>
> [ 82%] Building CXX object
> Build/OSGWindowQT4/CMakeFiles/OSGWindowQT4.dir/OSGQT4Window.cpp.o
> In file included
> from<path>/opensg/Source/WindowSystem/Cocoa/OSGCocoaWindowBase.h:68,
>
> from<path>/opensg/Source/WindowSystem/Cocoa/OSGCocoaWindow.h:47,
>
> from<path>/opensg/Source/WindowSystem/Cocoa/OSGNativeWindow.h:45,
>
> from<path>/opensg/Source/WindowSystem/QT4/OSGQT4WindowBase.h:66,
> from<path>/opensg/Source/WindowSystem/QT4/OSGQT4Window.h:47,
>
> from<path>/opensg/Source/WindowSystem/QT4/OSGQT4Window.cpp:50:
> <path>/opensg/Source/WindowSystem/Cocoa/OSGCocoaWindowDataFields.h: In static
> member function ‘static char* OSG::FieldTraits<NSOpenGLContext*,
> 0>::getSName()’:
> <path>/opensg/Source/WindowSystem/Cocoa/OSGCocoaWindowDataFields.h:87:
> warning: deprecated conversion from string constant to ‘char*’
> <path>/opensg/Source/WindowSystem/Cocoa/OSGCocoaWindowDataFields.h: In static
> member function ‘static char* OSG::FieldTraits<NSOpenGLContext*,
> 0>::getMName()’:
> <path>/opensg/Source/WindowSystem/Cocoa/OSGCocoaWindowDataFields.h:88:
> warning: deprecated conversion from string constant to ‘char*’
> <path>/opensg/Source/WindowSystem/QT4/OSGQT4Window.cpp: In member function
> ‘virtual void OSG::QT4Window::init(boost::function<void ()()>)’:
> <path>/opensg/Source/WindowSystem/QT4/OSGQT4Window.cpp:144: error:
> ‘setDisplay’ was not declared in this scope
> <path>/opensg/Source/WindowSystem/QT4/OSGQT4Window.cpp:145: error:
> ‘setWindow’ was not declared in this scope
> <path>/opensg/Source/WindowSystem/QT4/OSGQT4Window.cpp:153: error:
> ‘getDisplay’ was not declared in this scope
> make[2]: ***
> [Build/OSGWindowQT4/CMakeFiles/OSGWindowQT4.dir/OSGQT4Window.cpp.o] Error 1
> make[1]: *** [Build/OSGWindowQT4/CMakeFiles/OSGWindowQT4.dir/all] Error 2
hmm, looking at the file it seems it is missing an implementation for OS
X [1].
To get you started you probably don't even need OSGQT4Window, so you can
just put #if 0/#endif pair around the body of QT4Window::init(). Take a
look at Source/WindowSystem/QT4/testPassiveQT4.cpp on how to use
OpenSG's PassiveWindow with Qt4.
Cheers,
Carsten
[1] I don't quite understand why the Qt4 window uses platform specific
code to create an OpenGL context instead of the QGLContext class. This
may be a leftover from older (Qt 3 based) code, I'll try to change it,
but it may take a couple of days before I get to it.
------------------------------------------------------------------------------
Achieve unprecedented app performance and reliability
What every C/C++ and Fortran developer should know.
Learn how Intel has extended the reach of its next-generation tools
to help boost performance applications - inlcuding clusters.
http://p.sf.net/sfu/intel-dev2devmay
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users