Restored the REGISTER_WINDOWINGSYSTEMINTERFACE macro to the include/osg/GraphicsContext header and removed the OSGVIEWER_EXPORT as this was causing compatibility issues with osgQt.
In GraphicsWindowWin32 replaced REGISTER_WINDOWINGSYSTEMINTERFACE usage with locally implemented equivilant with the required OSGVIEWER_EXPORT.
This commit is contained in:
@@ -597,6 +597,10 @@ struct WindowingSystemInterfaceProxy
|
||||
osg::ref_ptr<T> _wsi;
|
||||
};
|
||||
|
||||
#define REGISTER_WINDOWINGSYSTEMINTERFACE(ext, classname) \
|
||||
extern "C" void graphicswindow_##ext(void) {} \
|
||||
static osg::WindowingSystemInterfaceProxy<classname> s_proxy_##classname(#ext);
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -274,10 +274,6 @@ class GraphicsWindowEmbedded : public GraphicsWindow
|
||||
};
|
||||
|
||||
|
||||
#define REGISTER_WINDOWINGSYSTEMINTERFACE(ext, classname) \
|
||||
extern "C" OSGVIEWER_EXPORT void graphicswindow_##ext(void) {} \
|
||||
static osg::WindowingSystemInterfaceProxy<classname> s_proxy_##classname(#ext);
|
||||
|
||||
struct GraphicsWindowFunctionProxy
|
||||
{
|
||||
GraphicsWindowFunctionProxy(CGraphicsWindowFunction function) { (function)(); }
|
||||
|
||||
@@ -3147,15 +3147,9 @@ static RegisterWindowingSystemInterfaceProxy createWindowingSystemInterfaceProxy
|
||||
|
||||
} // namespace OsgViewer
|
||||
|
||||
#if 1
|
||||
REGISTER_WINDOWINGSYSTEMINTERFACE(Win32, Win32WindowingSystem)
|
||||
#else
|
||||
// declare C entry point for static compilation.
|
||||
extern "C" void OSGVIEWER_EXPORT graphicswindow_Win32(void)
|
||||
{
|
||||
osg::GraphicsContext::setWindowingSystemInterface(osgViewer::Win32WindowingSystem::getInterface());
|
||||
}
|
||||
#endif
|
||||
|
||||
extern "C" OSGVIEWER_EXPORT void graphicswindow_Win32(void) {}
|
||||
static osg::WindowingSystemInterfaceProxy<Win32WindowingSystem> s_proxy_Win32WindowingSystem("Win32");
|
||||
|
||||
void GraphicsWindowWin32::raiseWindow()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user