ogre_gazebo.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2012 Open Source Robotics Foundation
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 *
16*/
17#ifndef GAZEBO_OGRE_H_
18#define GAZEBO_OGRE_H_
19
20// This disables warning messages for OGRE
21#pragma GCC system_header
22
23// This prevents some deprecation #warning messages on OSX 10.9
24#pragma clang diagnostic ignored "-W#warnings"
25
26#include <OGRE/Ogre.h>
27#include <OGRE/OgreBillboard.h>
28#include <OGRE/OgreImageCodec.h>
29#include <OGRE/OgreMovableObject.h>
30#include <OGRE/OgreRenderable.h>
31#include <OGRE/OgrePlugin.h>
32#include <OGRE/OgreDataStream.h>
33#include <OGRE/OgreLogManager.h>
34#include <OGRE/OgreSceneQuery.h>
35#include <OGRE/OgreRoot.h>
36#include <OGRE/OgreSceneManager.h>
37#include <OGRE/OgreSceneNode.h>
38#include <OGRE/OgreVector3.h>
39#include <OGRE/OgreMatrix4.h>
40#include <OGRE/OgreManualObject.h>
41#include <OGRE/OgreMaterialManager.h>
42#include <OGRE/OgreColourValue.h>
43#include <OGRE/OgreQuaternion.h>
44#include <OGRE/OgreMesh.h>
45#include <OGRE/OgreHardwareBufferManager.h>
46#include <OGRE/OgreCamera.h>
47#include <OGRE/OgreNode.h>
48#include <OGRE/OgreSimpleRenderable.h>
49#include <OGRE/OgreFrameListener.h>
50#include <OGRE/OgreTexture.h>
51#include <OGRE/OgreRenderObjectListener.h>
52#include <OGRE/OgreTechnique.h>
53#include <OGRE/OgrePass.h>
54#include <OGRE/OgreTextureUnitState.h>
55#include <OGRE/OgreGpuProgramManager.h>
56#include <OGRE/OgreHighLevelGpuProgramManager.h>
57#include <OGRE/OgreHardwarePixelBuffer.h>
58#include <OGRE/OgreShadowCameraSetupPSSM.h>
59#include <OGRE/Paging/OgrePageManager.h>
60#include <OGRE/Paging/OgrePagedWorld.h>
61#include <OGRE/Terrain/OgreTerrainPaging.h>
62#include <OGRE/Terrain/OgreTerrainMaterialGeneratorA.h>
63#include <OGRE/Terrain/OgreTerrain.h>
64#include <OGRE/Terrain/OgreTerrainGroup.h>
65
66#if OGRE_VERSION_MAJOR > 1 || OGRE_VERSION_MINOR >= 7
67#include <OGRE/RTShaderSystem/OgreRTShaderSystem.h>
68#include <OGRE/RTShaderSystem/OgreShaderProgramSet.h>
69#include <OGRE/RTShaderSystem/OgreShaderGLSLProgramWriter.h>
70#include <OGRE/RTShaderSystem/OgreShaderProgramWriterManager.h>
71#include <OGRE/RTShaderSystem/OgreShaderFunction.h>
72#include <OGRE/RTShaderSystem/OgreShaderProgram.h>
73#endif
74
75#if OGRE_VERSION_MAJOR > 1 || OGRE_VERSION_MINOR >= 9
76#include <OGRE/Overlay/OgreOverlayManager.h>
77#include <OGRE/Overlay/OgreOverlayElement.h>
78#include <OGRE/Overlay/OgreOverlayContainer.h>
79#include <OGRE/Overlay/OgreFontManager.h>
80#include <OGRE/Overlay/OgreOverlaySystem.h>
81#else
82#include <OGRE/OgreFontManager.h>
83#endif
84
85#if OGRE_VERSION_MAJOR == 1 && OGRE_VERSION_MINOR < 11
86// The <OGRE/OgreWindowEventUtilities.h> header has always been included in
87// public headers for Gazebo <= 10, but was moved to the Bites component in
88// Ogre 1.11 (see https://github.com/OGRECave/ogre/pull/647). As it is not
89// used at all in Gazebo, we can just include it for Ogre <= 1.10 to avoid
90// breaking transitive includes in downstream projects.
91// In Gazebo 11, this can be removed.
92#include <OGRE/OgreWindowEventUtilities.h>
93#endif
94
95#if OGRE_VERSION_MAJOR == 1 && OGRE_VERSION_MINOR >= 11
96#define GZ_OGRE_SET_MATERIAL_BY_NAME(ptr, name) \
97 (ptr)->setMaterial(Ogre::MaterialManager::getSingleton().getByName(name))
98#else
99#define GZ_OGRE_SET_MATERIAL_BY_NAME(ptr, name) \
100 (ptr)->setMaterial(name)
101#endif
102
103#endif