From 85b715e115e8190ca0570943c8649ff43a263577 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Thu, 24 Jan 2013 20:35:22 +0100 Subject: [PATCH] Trade: added forward declaration header. --- doc/compilation-speedup.dox | 1 + src/Trade/AbstractImporter.h | 20 ++------------ src/Trade/CMakeLists.txt | 3 ++- src/Trade/Trade.h | 51 ++++++++++++++++++++++++++++++++++++ 4 files changed, 56 insertions(+), 19 deletions(-) create mode 100644 src/Trade/Trade.h diff --git a/doc/compilation-speedup.dox b/doc/compilation-speedup.dox index 23313c4be..99abac95e 100644 --- a/doc/compilation-speedup.dox +++ b/doc/compilation-speedup.dox @@ -26,6 +26,7 @@ available, each namespace has its own: - SceneGraph/SceneGraph.h - Shaders/Shaders.h - Text/Text.h + - Trade/Trade.h @section compilation-speedup-templates Templates diff --git a/src/Trade/AbstractImporter.h b/src/Trade/AbstractImporter.h index 764fe5bed..f31d18dbd 100644 --- a/src/Trade/AbstractImporter.h +++ b/src/Trade/AbstractImporter.h @@ -22,28 +22,12 @@ #include #include +#include "Trade/Trade.h" + #include "magnumVisibility.h" namespace Magnum { namespace Trade { -/** @todoc Remove `ifndef` when Doxygen is sane again */ -#ifndef DOXYGEN_GENERATING_OUTPUT -class AbstractMaterialData; -class CameraData; -template class ImageData; -class LightData; -class MeshData2D; -class MeshData3D; -class ObjectData2D; -class ObjectData3D; -class SceneData; -class TextureData; -#endif - -typedef ImageData<1> ImageData1D; -typedef ImageData<2> ImageData2D; -typedef ImageData<3> ImageData3D; - /** @brief Base for importer plugins diff --git a/src/Trade/CMakeLists.txt b/src/Trade/CMakeLists.txt index 11d7bac8f..52cb96bb3 100644 --- a/src/Trade/CMakeLists.txt +++ b/src/Trade/CMakeLists.txt @@ -12,7 +12,8 @@ set(MagnumTrade_HEADERS ObjectData3D.h PhongMaterialData.h SceneData.h - TextureData.h) + TextureData.h + Trade.h) install(FILES ${MagnumTrade_HEADERS} DESTINATION ${MAGNUM_INCLUDE_INSTALL_DIR}/Trade) if(BUILD_TESTS) diff --git a/src/Trade/Trade.h b/src/Trade/Trade.h new file mode 100644 index 000000000..b629b96d8 --- /dev/null +++ b/src/Trade/Trade.h @@ -0,0 +1,51 @@ +#ifndef Magnum_Trade_Trade_h +#define Magnum_Trade_Trade_h +/* + Copyright © 2010, 2011, 2012 Vladimír Vondruš + + This file is part of Magnum. + + Magnum is free software: you can redistribute it and/or modify + it under the terms of the GNU Lesser General Public License version 3 + only, as published by the Free Software Foundation. + + Magnum is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU Lesser General Public License version 3 for more details. +*/ + +/** @file + * @brief Forward declarations for Magnum::Trade namespace + */ + +#include + +namespace Magnum { namespace Trade { + +/** @todoc Remove `ifndef` when Doxygen is sane again */ +#ifndef DOXYGEN_GENERATING_OUTPUT +class AbstractImporter; +class AbstractMaterialData; +class CameraData; + +template class ImageData; +typedef ImageData<1> ImageData1D; +typedef ImageData<2> ImageData2D; +typedef ImageData<3> ImageData3D; + +class LightData; +class MeshData2D; +class MeshData3D; +class MeshObjectData2D; +class MeshObjectData3D; +class ObjectData2D; +class ObjectData3D; +class PhongMaterialData; +class SceneData; +class TextureData; +#endif + +}} + +#endif