diff --git a/src/editing/dialogexplorer.cpp b/src/editing/dialogexplorer.cpp index 0e825f6..f049751 100644 --- a/src/editing/dialogexplorer.cpp +++ b/src/editing/dialogexplorer.cpp @@ -4,6 +4,9 @@ #include #include #include +#include "WidgetExplorer.h" +#include "rendering/camera.h" +#include "rendering/renderer.h" DialogExplorer::DialogExplorer(QWidget* parent, CameraDefinition* camera, bool camera_validable, Renderer* renderer) : QDialog(parent) { diff --git a/src/editing/dialogexplorer.h b/src/editing/dialogexplorer.h index 7ad3836..d042fdf 100644 --- a/src/editing/dialogexplorer.h +++ b/src/editing/dialogexplorer.h @@ -1,9 +1,17 @@ #ifndef _PAYSAGES_QT_DIALOGEXPLORER_H_ #define _PAYSAGES_QT_DIALOGEXPLORER_H_ +#include "editing_global.h" #include -#include "widgetexplorer.h" -#include "rendering/camera.h" + +class CameraDefinition; +class Renderer; + +namespace paysages { +namespace opengl { +class WidgetExplorer; +} +} class DialogExplorer : public QDialog { diff --git a/src/editing/editing.pro b/src/editing/editing.pro index 8591afd..10f3ca9 100644 --- a/src/editing/editing.pro +++ b/src/editing/editing.pro @@ -13,7 +13,6 @@ INCLUDEPATH += $$PWD/.. HEADERS += \ terrain/widgetheightmap.h \ - widgetexplorer.h \ widgetcurveeditor.h \ tools.h \ previewosd.h \ @@ -35,8 +34,6 @@ HEADERS += \ formrender.h \ formclouds.h \ formatmosphere.h \ - explorerchunkterrain.h \ - explorerchunksky.h \ dialogrender.h \ dialognoise.h \ dialoglayers.h \ @@ -47,7 +44,6 @@ HEADERS += \ baseinput.h \ baseformlayer.h \ baseform.h \ - baseexplorerchunk.h \ terrain/dialogterrainpainting.h \ common/widgetglobalformbuttons.h \ terrain/paintingbrush.h \ @@ -73,7 +69,6 @@ HEADERS += \ SOURCES += \ terrain/widgetheightmap.cpp \ - widgetexplorer.cpp \ widgetcurveeditor.cpp \ tools.cpp \ previewosd.cpp \ @@ -95,8 +90,6 @@ SOURCES += \ formrender.cpp \ formclouds.cpp \ formatmosphere.cpp \ - explorerchunkterrain.cpp \ - explorerchunksky.cpp \ dialogrender.cpp \ dialognoise.cpp \ dialoglayers.cpp \ @@ -107,7 +100,6 @@ SOURCES += \ baseinput.cpp \ baseformlayer.cpp \ baseform.cpp \ - baseexplorerchunk.cpp \ terrain/dialogterrainpainting.cpp \ common/widgetglobalformbuttons.cpp \ terrain/paintingbrush.cpp \ @@ -157,12 +149,6 @@ else:unix: LIBS += -L$$OUT_PWD/../basics/ -lpaysages_basics INCLUDEPATH += $$PWD/../basics DEPENDPATH += $$PWD/../basics -win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../exploring/release/ -lpaysages_exploring -else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../exploring/debug/ -lpaysages_exploring -else:unix: LIBS += -L$$OUT_PWD/../exploring/ -lpaysages_exploring -INCLUDEPATH += $$PWD/../exploring -DEPENDPATH += $$PWD/../exploring - win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../rendering/release/ -lpaysages_rendering else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../rendering/debug/ -lpaysages_rendering else:unix: LIBS += -L$$OUT_PWD/../rendering/ -lpaysages_rendering @@ -174,3 +160,9 @@ else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../definition/debug else:unix: LIBS += -L$$OUT_PWD/../definition/ -lpaysages_definition INCLUDEPATH += $$PWD/../definition DEPENDPATH += $$PWD/../definition + +win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../render/opengl/release/ -lpaysages_render_opengl +else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../render/opengl/debug/ -lpaysages_render_opengl +else:unix: LIBS += -L$$OUT_PWD/../render/opengl/ -lpaysages_render_opengl +INCLUDEPATH += $$PWD/../render/opengl +DEPENDPATH += $$PWD/../render/opengl diff --git a/src/editing/editing_global.h b/src/editing/editing_global.h index da8f66e..c2a39ad 100644 --- a/src/editing/editing_global.h +++ b/src/editing/editing_global.h @@ -6,9 +6,11 @@ namespace paysages namespace system {} namespace basics {} namespace definition {} + namespace opengl {} } using namespace paysages::system; using namespace paysages::basics; using namespace paysages::definition; +using namespace paysages::opengl; #endif // EDITING_GLOBAL_H diff --git a/src/exploring/exploring.pro b/src/exploring/exploring.pro deleted file mode 100644 index 416075d..0000000 --- a/src/exploring/exploring.pro +++ /dev/null @@ -1,48 +0,0 @@ -QT += opengl - -TEMPLATE = lib -TARGET = paysages_exploring - -DEFINES += EXPLORING_LIBRARY -CONFIG(release, debug|release): DEFINES += NDEBUG - -INCLUDEPATH += $$PWD/.. - -SOURCES += \ - main.cpp - -HEADERS += main.h \ - exploring_global.h - -unix:!symbian { - maemo5 { - target.path = /opt/usr/lib - } else { - target.path = /usr/lib - } - INSTALLS += target -} - -win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../rendering/release/ -lpaysages_rendering -else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../rendering/debug/ -lpaysages_rendering -else:unix: LIBS += -L$$OUT_PWD/../rendering/ -lpaysages_rendering -INCLUDEPATH += $$PWD/../rendering -DEPENDPATH += $$PWD/../rendering - -win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../system/release/ -lpaysages_system -else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../system/debug/ -lpaysages_system -else:unix: LIBS += -L$$OUT_PWD/../system/ -lpaysages_system -INCLUDEPATH += $$PWD/../system -DEPENDPATH += $$PWD/../system - -win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../definition/release/ -lpaysages_definition -else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../definition/debug/ -lpaysages_definition -else:unix: LIBS += -L$$OUT_PWD/../definition/ -lpaysages_definition -INCLUDEPATH += $$PWD/../definition -DEPENDPATH += $$PWD/../definition - -win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../basics/release/ -lpaysages_basics -else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../basics/debug/ -lpaysages_basics -else:unix: LIBS += -L$$OUT_PWD/../basics/ -lpaysages_basics -INCLUDEPATH += $$PWD/../basics -DEPENDPATH += $$PWD/../basics diff --git a/src/exploring/exploring_global.h b/src/exploring/exploring_global.h deleted file mode 100644 index f37b575..0000000 --- a/src/exploring/exploring_global.h +++ /dev/null @@ -1,26 +0,0 @@ -#ifndef EXPLORING_GLOBAL_H -#define EXPLORING_GLOBAL_H - -/* Shared object helpers */ -#ifdef __cplusplus -# include -#else -# if defined(WIN32) || defined(_WIN32) || defined(__WIN32__) || defined(__NT__) -# define Q_DECL_EXPORT __declspec(dllexport) -# define Q_DECL_IMPORT __declspec(dllimport) -# else -# define Q_DECL_EXPORT -# define Q_DECL_IMPORT -# endif -#endif -#if defined(EXPLORING_LIBRARY) -# define EXPLORINGSHARED_EXPORT Q_DECL_EXPORT -#else -# define EXPLORINGSHARED_EXPORT Q_DECL_IMPORT -#endif - -/* Namespace using */ - -/* Global import */ - -#endif // EXPLORING_GLOBAL_H diff --git a/src/exploring/main.h b/src/exploring/main.h deleted file mode 100644 index 7c4ae3e..0000000 --- a/src/exploring/main.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef _PAYSAGES_EXPLORING_MAIN_H_ -#define _PAYSAGES_EXPLORING_MAIN_H_ - -#include "exploring_global.h" - -#include "rendering/renderer.h" -#include "rendering/camera.h" - -#ifdef __cplusplus -extern "C" { -#endif - -EXPLORINGSHARED_EXPORT void exploringInit(); -EXPLORINGSHARED_EXPORT void exploringSetViewPort(int width, int height, CameraDefinition* camera); -EXPLORINGSHARED_EXPORT void exploringRenderFrame(Renderer* renderer); - -EXPLORINGSHARED_EXPORT void exploringStartStandAlone(); -EXPLORINGSHARED_EXPORT void exploringInterruptStandAlone(); - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/src/paysages.pro b/src/paysages.pro index 0ef370b..706ec48 100644 --- a/src/paysages.pro +++ b/src/paysages.pro @@ -6,17 +6,8 @@ SUBDIRS = \ basics \ definition \ rendering \ - exploring \ + render/opengl \ editing \ controlling #unix:SUBDIRS += testing tests - -basics.depends = system -definition.depends = basics -rendering.depends = definition -exploring.depends = rendering -editing.depends = exploring rendering -controlling.depends = rendering -#unix:testing.depends = rendering -unix:tests.depends = rendering diff --git a/src/editing/baseexplorerchunk.cpp b/src/render/opengl/BaseExplorerChunk.cpp similarity index 98% rename from src/editing/baseexplorerchunk.cpp rename to src/render/opengl/BaseExplorerChunk.cpp index 7aae96a..cfd8a16 100644 --- a/src/editing/baseexplorerchunk.cpp +++ b/src/render/opengl/BaseExplorerChunk.cpp @@ -1,4 +1,7 @@ -#include "baseexplorerchunk.h" +#include "BaseExplorerChunk.h" + +#include +#include #ifndef GL_CLAMP_TO_EDGE #define GL_CLAMP_TO_EDGE 0x812F diff --git a/src/editing/baseexplorerchunk.h b/src/render/opengl/BaseExplorerChunk.h similarity index 74% rename from src/editing/baseexplorerchunk.h rename to src/render/opengl/BaseExplorerChunk.h index 9dbbeaa..d3fb944 100644 --- a/src/editing/baseexplorerchunk.h +++ b/src/render/opengl/BaseExplorerChunk.h @@ -1,10 +1,18 @@ -#ifndef _PAYSAGES_QT_BASEEXPLORERCHUNK_H_ -#define _PAYSAGES_QT_BASEEXPLORERCHUNK_H_ +#ifndef BASEEXPLORERCHUNK_H +#define BASEEXPLORERCHUNK_H +#include "opengl_global.h" #include -#include -#include -#include "rendering/renderer.h" +#include "rendering/tools/color.h" + +class QImage; +class QGLWidget; +class Renderer; +class ColorProfile; +class CameraDefinition; + +namespace paysages { +namespace opengl { class BaseExplorerChunk { @@ -40,10 +48,13 @@ private: bool _reset_needed; QImage* _texture; - GLuint _texture_id; + unsigned int _texture_id; bool _texture_changed; int _texture_current_size; int _texture_max_size; }; -#endif +} +} + +#endif // BASEEXPLORERCHUNK_H diff --git a/src/editing/explorerchunksky.cpp b/src/render/opengl/ExplorerChunkSky.cpp similarity index 97% rename from src/editing/explorerchunksky.cpp rename to src/render/opengl/ExplorerChunkSky.cpp index dc0e1c1..b85e277 100644 --- a/src/editing/explorerchunksky.cpp +++ b/src/render/opengl/ExplorerChunkSky.cpp @@ -1,8 +1,9 @@ -#include "explorerchunksky.h" +#include "ExplorerChunkSky.h" -#include -#include "baseexplorerchunk.h" +#include +#include "rendering/renderer.h" #include "rendering/camera.h" +#include ExplorerChunkSky::ExplorerChunkSky(Renderer* renderer, double size, SkyboxOrientation orientation) : BaseExplorerChunk(renderer) { diff --git a/src/editing/explorerchunksky.h b/src/render/opengl/ExplorerChunkSky.h similarity index 76% rename from src/editing/explorerchunksky.h rename to src/render/opengl/ExplorerChunkSky.h index ca33bae..90390dd 100644 --- a/src/editing/explorerchunksky.h +++ b/src/render/opengl/ExplorerChunkSky.h @@ -1,10 +1,13 @@ -#ifndef _PAYSAGES_QT_EXPLORERCHUNKSKY_H_ -#define _PAYSAGES_QT_EXPLORERCHUNKSKY_H_ +#ifndef EXPLORERCHUNKSKY_H +#define EXPLORERCHUNKSKY_H -#include "baseexplorerchunk.h" -#include "rendering/renderer.h" +#include "opengl_global.h" +#include "BaseExplorerChunk.h" #include "rendering/tools/euclid.h" +namespace paysages { +namespace opengl { + enum SkyboxOrientation { SKYBOX_NORTH, @@ -31,4 +34,7 @@ private: Vector3 _center; }; -#endif +} +} + +#endif // EXPLORERCHUNKSKY_H diff --git a/src/editing/explorerchunkterrain.cpp b/src/render/opengl/ExplorerChunkTerrain.cpp similarity index 98% rename from src/editing/explorerchunkterrain.cpp rename to src/render/opengl/ExplorerChunkTerrain.cpp index bd57699..14ee94a 100644 --- a/src/editing/explorerchunkterrain.cpp +++ b/src/render/opengl/ExplorerChunkTerrain.cpp @@ -1,8 +1,9 @@ -#include "explorerchunkterrain.h" +#include "ExplorerChunkTerrain.h" -#include -#include "baseexplorerchunk.h" +#include +#include #include "rendering/camera.h" +#include "rendering/renderer.h" ExplorerChunkTerrain::ExplorerChunkTerrain(Renderer* renderer, double x, double z, double size, int nbchunks, double water_height) : BaseExplorerChunk(renderer) { diff --git a/src/editing/explorerchunkterrain.h b/src/render/opengl/ExplorerChunkTerrain.h similarity index 82% rename from src/editing/explorerchunkterrain.h rename to src/render/opengl/ExplorerChunkTerrain.h index 9dff03a..86bd23e 100644 --- a/src/editing/explorerchunkterrain.h +++ b/src/render/opengl/ExplorerChunkTerrain.h @@ -1,10 +1,12 @@ -#ifndef _PAYSAGES_QT_EXPLORERCHUNKTERRAIN_H_ -#define _PAYSAGES_QT_EXPLORERCHUNKTERRAIN_H_ +#ifndef EXPLORERCHUNKTERRAIN_H +#define EXPLORERCHUNKTERRAIN_H -#include "baseexplorerchunk.h" -#include "rendering/renderer.h" +#include "BaseExplorerChunk.h" #include "rendering/tools/euclid.h" +namespace paysages { +namespace opengl { + class ExplorerChunkTerrain:public BaseExplorerChunk { public: @@ -37,4 +39,7 @@ private: }; -#endif +} +} + +#endif // EXPLORERCHUNKTERRAIN_H diff --git a/src/exploring/main.cpp b/src/render/opengl/OpenGLRenderer.cpp similarity index 53% rename from src/exploring/main.cpp rename to src/render/opengl/OpenGLRenderer.cpp index e270c12..8bfdfe9 100644 --- a/src/exploring/main.cpp +++ b/src/render/opengl/OpenGLRenderer.cpp @@ -1,10 +1,31 @@ -#include "main.h" +#include "OpenGLRenderer.h" -#include -#include "GL/gl.h" -#include "GL/glu.h" +#include +#include +#include +#include "Scenery.h" +#include "renderer.h" -void exploringInit() +OpenGLRenderer::OpenGLRenderer(Scenery* scenery): + scenery(scenery) +{ + if (scenery) + { + renderer = rendererCreate(); + // TODO Bind scenery to renderer + } + else + { + renderer = sceneryCreateStandardRenderer(); + } +} + +OpenGLRenderer::~OpenGLRenderer() +{ + rendererDelete(renderer); +} + +void OpenGLRenderer::initialize() { glClearColor(0.0, 0.0, 0.0, 0.0); @@ -27,7 +48,7 @@ void exploringInit() glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); } -void exploringSetViewPort(int width, int height, CameraDefinition* camera) +void OpenGLRenderer::resize(int width, int height) { CameraPerspective perspective; @@ -35,20 +56,13 @@ void exploringSetViewPort(int width, int height, CameraDefinition* camera) glMatrixMode(GL_PROJECTION); glLoadIdentity(); - perspective = cameraGetPerspective(camera); + perspective = cameraGetPerspective(renderer->render_camera); gluPerspective(perspective.yfov * 180.0 / M_PI, perspective.xratio, perspective.znear, perspective.zfar); glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); } -void exploringRenderFrame(Renderer* renderer) +void OpenGLRenderer::paint() { -} -void exploringStartStandAlone() -{ -} - -void exploringInterruptStandAlone() -{ } diff --git a/src/render/opengl/OpenGLRenderer.h b/src/render/opengl/OpenGLRenderer.h new file mode 100644 index 0000000..8b6b94a --- /dev/null +++ b/src/render/opengl/OpenGLRenderer.h @@ -0,0 +1,33 @@ +#ifndef OPENGLRENDERER_H +#define OPENGLRENDERER_H + +#include "opengl_global.h" + +class Scenery; +class Renderer; + +namespace paysages { +namespace opengl { + +/*! + * \brief Scenery renderer in an OpenGL context. + */ +class OPENGLSHARED_EXPORT OpenGLRenderer +{ +public: + OpenGLRenderer(Scenery* scenery=0); + ~OpenGLRenderer(); + + void initialize(); + void resize(int width, int height); + void paint(); + +private: + Scenery* scenery; + Renderer* renderer; +}; + +} +} + +#endif // OPENGLRENDERER_H diff --git a/src/editing/widgetexplorer.cpp b/src/render/opengl/WidgetExplorer.cpp similarity index 96% rename from src/editing/widgetexplorer.cpp rename to src/render/opengl/WidgetExplorer.cpp index 6c8f8ce..138d2d0 100644 --- a/src/editing/widgetexplorer.cpp +++ b/src/render/opengl/WidgetExplorer.cpp @@ -1,4 +1,4 @@ -#include "widgetexplorer.h" +#include "WidgetExplorer.h" #include #include @@ -7,11 +7,10 @@ #include #include #include "Scenery.h" +#include "OpenGLRenderer.h" #include "rendering/tools/euclid.h" -#include "../exploring/main.h" -#include "explorerchunkterrain.h" -#include "explorerchunksky.h" -#include "tools.h" +#include "ExplorerChunkSky.h" +#include "ExplorerChunkTerrain.h" class ChunkMaintenanceThread : public QThread { @@ -86,6 +85,7 @@ QGLWidget(parent) _renderer = sceneryCreateStandardRenderer(); _renderer_created = true; } + _opengl_renderer = new OpenGLRenderer(NULL); _renderer->render_quality = 3; _renderer->customData[2] = _base_camera; _renderer->getCameraLocation = _getCameraLocation; @@ -117,6 +117,7 @@ WidgetExplorer::~WidgetExplorer() { rendererDelete(_renderer); } + delete _opengl_renderer; } void WidgetExplorer::startRendering() @@ -379,13 +380,13 @@ void WidgetExplorer::timerEvent(QTimerEvent*) void WidgetExplorer::initializeGL() { - exploringInit(); + _opengl_renderer->initialize(); } void WidgetExplorer::resizeGL(int w, int h) { cameraSetRenderSize(_current_camera, w, h); - exploringSetViewPort(w, h, _current_camera); + _opengl_renderer->resize(w, h); } void WidgetExplorer::paintGL() @@ -455,6 +456,6 @@ void WidgetExplorer::paintGL() while ((error_code = glGetError()) != GL_NO_ERROR) { - logDebug(QString("[OpenGL] ERROR : ") + (const char*) gluErrorString(error_code)); + qDebug("[OpenGL] ERROR : %s", (const char*)gluErrorString(error_code)); } } diff --git a/src/editing/widgetexplorer.h b/src/render/opengl/WidgetExplorer.h similarity index 78% rename from src/editing/widgetexplorer.h rename to src/render/opengl/WidgetExplorer.h index 2238932..0f0c22b 100644 --- a/src/editing/widgetexplorer.h +++ b/src/render/opengl/WidgetExplorer.h @@ -1,10 +1,18 @@ -#ifndef _PAYSAGES_QT_WIDGETEXPLORER_H_ -#define _PAYSAGES_QT_WIDGETEXPLORER_H_ +#ifndef WIDGETEXPLORER_H +#define WIDGETEXPLORER_H +#include "opengl_global.h" #include -#include "baseexplorerchunk.h" -#include "rendering/camera.h" -#include "rendering/renderer.h" +#include + +class CameraDefinition; +class Renderer; + +namespace paysages { +namespace opengl { + +class OpenGLRenderer; +class BaseExplorerChunk; class WidgetExplorer : public QGLWidget { @@ -37,6 +45,7 @@ private: CameraDefinition* _current_camera; CameraDefinition* _base_camera; + OpenGLRenderer* _opengl_renderer; Renderer* _renderer; bool _renderer_created; bool _inited; @@ -54,4 +63,7 @@ private: int _last_mouse_y; }; -#endif +} +} + +#endif // WIDGETEXPLORER_H diff --git a/src/render/opengl/opengl.pro b/src/render/opengl/opengl.pro new file mode 100644 index 0000000..5557b2d --- /dev/null +++ b/src/render/opengl/opengl.pro @@ -0,0 +1,63 @@ +#------------------------------------------------- +# +# Project created by QtCreator 2013-11-04T11:54:27 +# +#------------------------------------------------- + +QT += opengl + +TARGET = paysages_render_opengl +TEMPLATE = lib + +DEFINES += OPENGL_LIBRARY + +SOURCES += \ + OpenGLRenderer.cpp \ + BaseExplorerChunk.cpp \ + ExplorerChunkSky.cpp \ + ExplorerChunkTerrain.cpp \ + WidgetExplorer.cpp + +HEADERS +=\ + opengl_global.h \ + OpenGLRenderer.h \ + BaseExplorerChunk.h \ + ExplorerChunkSky.h \ + ExplorerChunkTerrain.h \ + WidgetExplorer.h + +unix:!symbian { + maemo5 { + target.path = /opt/usr/lib + } else { + target.path = /usr/lib + } + INSTALLS += target +} + +# TEMP +INCLUDEPATH += $$PWD/../.. + +win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../../system/release/ -lpaysages_system +else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../../system/debug/ -lpaysages_system +else:unix: LIBS += -L$$OUT_PWD/../../system/ -lpaysages_system +INCLUDEPATH += $$PWD/../../system +DEPENDPATH += $$PWD/../../system + +win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../../basics/release/ -lpaysages_basics +else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../../basics/debug/ -lpaysages_basics +else:unix: LIBS += -L$$OUT_PWD/../../basics/ -lpaysages_basics +INCLUDEPATH += $$PWD/../../basics +DEPENDPATH += $$PWD/../../basics + +win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../../definition/release/ -lpaysages_definition +else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../../definition/debug/ -lpaysages_definition +else:unix: LIBS += -L$$OUT_PWD/../../definition/ -lpaysages_definition +INCLUDEPATH += $$PWD/../../definition +DEPENDPATH += $$PWD/../../definition + +win32:CONFIG(release, debug|release): LIBS += -L$$OUT_PWD/../../rendering/release/ -lpaysages_rendering +else:win32:CONFIG(debug, debug|release): LIBS += -L$$OUT_PWD/../../rendering/debug/ -lpaysages_rendering +else:unix: LIBS += -L$$OUT_PWD/../../rendering/ -lpaysages_rendering +INCLUDEPATH += $$PWD/../../rendering +DEPENDPATH += $$PWD/../../rendering diff --git a/src/render/opengl/opengl_global.h b/src/render/opengl/opengl_global.h new file mode 100644 index 0000000..69116ca --- /dev/null +++ b/src/render/opengl/opengl_global.h @@ -0,0 +1,17 @@ +#ifndef OPENGL_GLOBAL_H +#define OPENGL_GLOBAL_H + +#include + +#if defined(OPENGL_LIBRARY) +# define OPENGLSHARED_EXPORT Q_DECL_EXPORT +#else +# define OPENGLSHARED_EXPORT Q_DECL_IMPORT +#endif + +namespace paysages { +namespace opengl {} +} +using namespace paysages::opengl; + +#endif // OPENGL_GLOBAL_H