From fea6b56eab1a7fa44efd33b02c8ba136f1149155 Mon Sep 17 00:00:00 2001 From: Jack Andersen Date: Sat, 18 Apr 2015 11:45:34 -1000 Subject: [PATCH] initial CGL stubs; directory layout --- IContext.cpp | 12 ------------ include/CCGLContext.hpp | 11 +++++++++++ IContext.hpp => include/IContext.hpp | 0 include/boo.hpp | 16 ++++++++++++++++ libBoo.pri | 8 ++++++++ libBoo.pro | 7 ++----- src/CCGLContext.cpp | 0 test/test.pri | 2 ++ 8 files changed, 39 insertions(+), 17 deletions(-) delete mode 100644 IContext.cpp create mode 100644 include/CCGLContext.hpp rename IContext.hpp => include/IContext.hpp (100%) create mode 100644 include/boo.hpp create mode 100644 libBoo.pri create mode 100644 src/CCGLContext.cpp create mode 100644 test/test.pri diff --git a/IContext.cpp b/IContext.cpp deleted file mode 100644 index ac6820a..0000000 --- a/IContext.cpp +++ /dev/null @@ -1,12 +0,0 @@ -#include "CContext.hpp" - -CContext::CContext() -{ - -} - -CContext::~CContext() -{ - -} - diff --git a/include/CCGLContext.hpp b/include/CCGLContext.hpp new file mode 100644 index 0000000..0f17ef2 --- /dev/null +++ b/include/CCGLContext.hpp @@ -0,0 +1,11 @@ +#ifndef CCGLCONTEXT_HPP +#define CCGLCONTEXT_HPP + +#include "IContext.hpp" + +class CCGLContext final : public IContext +{ + +}; + +#endif // CCGLCONTEXT_HPP diff --git a/IContext.hpp b/include/IContext.hpp similarity index 100% rename from IContext.hpp rename to include/IContext.hpp diff --git a/include/boo.hpp b/include/boo.hpp new file mode 100644 index 0000000..10aa15a --- /dev/null +++ b/include/boo.hpp @@ -0,0 +1,16 @@ +#ifndef BOO_HPP +#define BOO_HPP + +#include "IContext.hpp" + +#if defined(_WIN32) +#error "No support for WGL" +#elif defined(__APPLE__) +#include "CCGLContext.hpp" +typedef CCGLContext CContext; +#elif __linux__ +#include "CGLXContext.hpp" +typedef CGLXContext CContext; +#endif + +#endif // BOO_HPP diff --git a/libBoo.pri b/libBoo.pri new file mode 100644 index 0000000..8e7a84f --- /dev/null +++ b/libBoo.pri @@ -0,0 +1,8 @@ +HEADERS += \ + $$PWD/include/boo.hpp \ + $$PWD/include/IContext.hpp + +SOURCES += \ + $$PWD/src/CCGLContext.cpp + +INCLUDEPATH += $$PWD/include diff --git a/libBoo.pro b/libBoo.pro index 81532a4..38d8f69 100644 --- a/libBoo.pro +++ b/libBoo.pro @@ -1,5 +1,2 @@ -HEADERS += \ - IContext.hpp - -SOURCES += \ - IContext.cpp +include(libBoo.pri) +include(test/test.pri) \ No newline at end of file diff --git a/src/CCGLContext.cpp b/src/CCGLContext.cpp new file mode 100644 index 0000000..e69de29 diff --git a/test/test.pri b/test/test.pri new file mode 100644 index 0000000..bf76c86 --- /dev/null +++ b/test/test.pri @@ -0,0 +1,2 @@ +SOURCES += \ + $$PWD/main.cpp \ No newline at end of file