diff --git a/source/graphics/CinemaManager.cpp b/source/graphics/CinemaManager.cpp index 04b0c9c2c9..ce26359bbb 100644 --- a/source/graphics/CinemaManager.cpp +++ b/source/graphics/CinemaManager.cpp @@ -23,6 +23,7 @@ #include "graphics/CinemaManager.h" #include "graphics/Camera.h" +#include "graphics/Color.h" #include "graphics/GameView.h" #include "lib/ogl.h" #include "maths/MathUtil.h" @@ -41,6 +42,7 @@ #include "simulation2/components/ICmpRangeManager.h" #include "simulation2/components/ICmpSelectable.h" #include "simulation2/components/ICmpTerritoryManager.h" +#include "simulation2/helpers/CinemaPath.h" #include "simulation2/MessageTypes.h" #include "simulation2/system/ComponentManager.h" #include "simulation2/Simulation2.h" diff --git a/source/graphics/CinemaManager.h b/source/graphics/CinemaManager.h index 0835538dab..73812e98ce 100644 --- a/source/graphics/CinemaManager.h +++ b/source/graphics/CinemaManager.h @@ -18,11 +18,9 @@ #ifndef INCLUDED_CINEMAMANAGER #define INCLUDED_CINEMAMANAGER -#include "lib/input.h" // InReaction - can't forward-declare enum -#include "graphics/Color.h" -#include "ps/CStr.h" -#include "simulation2/helpers/CinemaPath.h" +class RNSpline; +struct CColor; /** * Class for in game playing of cinematics. Should only be instantiated in CGameView. diff --git a/source/graphics/Decal.h b/source/graphics/Decal.h index 28411019c6..e82da4a4a0 100644 --- a/source/graphics/Decal.h +++ b/source/graphics/Decal.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2013 Wildfire Games. +/* Copyright (C) 2021 Wildfire Games. * This file is part of 0 A.D. * * 0 A.D. is free software: you can redistribute it and/or modify @@ -20,7 +20,6 @@ #include "graphics/Material.h" #include "graphics/ModelAbstract.h" -#include "graphics/Texture.h" class CTerrain; diff --git a/source/graphics/LOSTexture.h b/source/graphics/LOSTexture.h index 16d65d3b9d..149739d5bc 100644 --- a/source/graphics/LOSTexture.h +++ b/source/graphics/LOSTexture.h @@ -17,10 +17,8 @@ #include "lib/ogl.h" -#include "maths/Matrix3D.h" - -#include "graphics/ShaderManager.h" #include "graphics/ShaderTechniquePtr.h" +#include "maths/Matrix3D.h" class CLosQuerier; class CSimulation2; diff --git a/source/graphics/MapGenerator.h b/source/graphics/MapGenerator.h index c0cb5bf4fe..b3c9f9c5c3 100644 --- a/source/graphics/MapGenerator.h +++ b/source/graphics/MapGenerator.h @@ -18,13 +18,11 @@ #ifndef INCLUDED_MAPGENERATOR #define INCLUDED_MAPGENERATOR -#include "lib/posix/posix_pthread.h" #include "ps/FileIo.h" #include "ps/TemplateLoader.h" #include "scriptinterface/StructuredClone.h" #include - #include #include #include diff --git a/source/graphics/Model.h b/source/graphics/Model.h index cc21fdff05..560ff0fafe 100644 --- a/source/graphics/Model.h +++ b/source/graphics/Model.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2020 Wildfire Games. +/* Copyright (C) 2021 Wildfire Games. * This file is part of 0 A.D. * * 0 A.D. is free software: you can redistribute it and/or modify @@ -22,13 +22,12 @@ #ifndef INCLUDED_MODEL #define INCLUDED_MODEL -#include - -#include "graphics/Texture.h" #include "graphics/Material.h" #include "graphics/MeshManager.h" #include "graphics/ModelAbstract.h" +#include + struct SPropPoint; class CObjectEntry; class CSkeletonAnim; diff --git a/source/graphics/ModelDef.h b/source/graphics/ModelDef.h index 8ddfeeda4f..1144c0c7a6 100644 --- a/source/graphics/ModelDef.h +++ b/source/graphics/ModelDef.h @@ -22,13 +22,12 @@ #ifndef INCLUDED_MODELDEF #define INCLUDED_MODELDEF -#include "ps/CStr.h" #include "maths/BoundingBoxAligned.h" #include "maths/Matrix3D.h" -#include "maths/Vector2D.h" -#include "maths/Vector3D.h" #include "maths/Quaternion.h" +#include "maths/Vector3D.h" #include "lib/file/vfs/vfs_path.h" +#include "ps/CStr.h" #include "renderer/VertexArray.h" #include diff --git a/source/graphics/Overlay.h b/source/graphics/Overlay.h index 73d294122e..7b25ff9dea 100644 --- a/source/graphics/Overlay.h +++ b/source/graphics/Overlay.h @@ -22,7 +22,6 @@ #include "graphics/Texture.h" #include "maths/Vector2D.h" #include "maths/Vector3D.h" -#include "maths/FixedVector3D.h" #include "ps/CStrIntern.h" #include diff --git a/source/graphics/ParticleEmitter.h b/source/graphics/ParticleEmitter.h index 918aab89b2..76b0bd0498 100644 --- a/source/graphics/ParticleEmitter.h +++ b/source/graphics/ParticleEmitter.h @@ -20,7 +20,6 @@ #include "graphics/ModelAbstract.h" #include "graphics/ParticleEmitterType.h" -#include "graphics/Texture.h" #include "maths/Quaternion.h" #include "renderer/VertexArray.h" diff --git a/source/graphics/ShaderManager.cpp b/source/graphics/ShaderManager.cpp index bd823ffc7b..1b50721671 100644 --- a/source/graphics/ShaderManager.cpp +++ b/source/graphics/ShaderManager.cpp @@ -29,13 +29,16 @@ #include "ps/CStrIntern.h" #include "ps/Filesystem.h" #include "ps/Profile.h" -#if USE_SHADER_XML_VALIDATION -# include "ps/XML/RelaxNG.h" -#endif #include "ps/XML/Xeromyces.h" #include "ps/XML/XMLWriter.h" #include "renderer/Renderer.h" +#define USE_SHADER_XML_VALIDATION 1 + +#if USE_SHADER_XML_VALIDATION +# include "ps/XML/RelaxNG.h" +#endif + TIMER_ADD_CLIENT(tc_ShaderValidation); CShaderManager::CShaderManager() diff --git a/source/graphics/ShaderManager.h b/source/graphics/ShaderManager.h index 409a007936..22fc4ea72b 100644 --- a/source/graphics/ShaderManager.h +++ b/source/graphics/ShaderManager.h @@ -18,19 +18,13 @@ #ifndef INCLUDED_SHADERMANAGER #define INCLUDED_SHADERMANAGER -#define USE_SHADER_XML_VALIDATION 1 - #include "graphics/ShaderDefines.h" #include "graphics/ShaderProgram.h" #include "graphics/ShaderTechnique.h" -#if USE_SHADER_XML_VALIDATION -# include "ps/XML/RelaxNG.h" -#endif - -#include #include #include +#include /** * Shader manager: loads and caches shader programs. diff --git a/source/gui/CGUI.cpp b/source/gui/CGUI.cpp index 7c98b64723..94fdfbf794 100644 --- a/source/gui/CGUI.cpp +++ b/source/gui/CGUI.cpp @@ -33,6 +33,7 @@ #include "lib/sysdep/sysdep.h" #include "lib/timer.h" #include "lib/utf8.h" +#include "maths/Size2D.h" #include "ps/CLogger.h" #include "ps/Filesystem.h" #include "ps/GameSetup/Config.h" diff --git a/source/gui/CGUI.h b/source/gui/CGUI.h index 79e573e334..a478b7a8b5 100644 --- a/source/gui/CGUI.h +++ b/source/gui/CGUI.h @@ -29,7 +29,6 @@ #include "gui/SGUIStyle.h" #include "lib/input.h" #include "maths/Rect.h" -#include "maths/Size2D.h" #include "maths/Vector2D.h" #include "ps/XML/Xeromyces.h" #include "scriptinterface/ScriptForward.h" diff --git a/source/gui/ObjectTypes/CMiniMap.cpp b/source/gui/ObjectTypes/CMiniMap.cpp index c246b1ceea..3191d42943 100644 --- a/source/gui/ObjectTypes/CMiniMap.cpp +++ b/source/gui/ObjectTypes/CMiniMap.cpp @@ -22,6 +22,7 @@ #include "graphics/GameView.h" #include "graphics/LOSTexture.h" #include "graphics/MiniPatch.h" +#include "graphics/ShaderManager.h" #include "graphics/Terrain.h" #include "graphics/TerrainTextureEntry.h" #include "graphics/TerrainTextureManager.h" diff --git a/source/ps/CLogger.cpp b/source/ps/CLogger.cpp index f7e6129c99..31bc8be5c1 100644 --- a/source/ps/CLogger.cpp +++ b/source/ps/CLogger.cpp @@ -22,6 +22,7 @@ #include "graphics/FontMetrics.h" #include "graphics/ShaderManager.h" #include "graphics/TextRenderer.h" +#include "lib/os_path.h" #include "lib/timer.h" #include "lib/utf8.h" #include "ps/CConsole.h" diff --git a/source/ps/Game.h b/source/ps/Game.h index 8316d9a41c..e850d6ecc6 100644 --- a/source/ps/Game.h +++ b/source/ps/Game.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2020 Wildfire Games. +/* Copyright (C) 2021 Wildfire Games. * This file is part of 0 A.D. * * 0 A.D. is free software: you can redistribute it and/or modify @@ -18,20 +18,20 @@ #ifndef INCLUDED_GAME #define INCLUDED_GAME -#include - +#include "graphics/Color.h" #include "ps/CStr.h" #include "ps/Errors.h" -#include "ps/Filesystem.h" +#include "lib/os_path.h" #include "scriptinterface/ScriptTypes.h" #include "simulation2/helpers/Player.h" -class CWorld; -class CSimulation2; +#include + class CGameView; +class CSimulation2; class CTurnManager; +class CWorld; class IReplayLogger; -struct CColor; /** * The container that holds the rules, resources and attributes of the game. diff --git a/source/ps/scripting/JSInterface_Game.cpp b/source/ps/scripting/JSInterface_Game.cpp index f2494fd9c1..48266d7878 100644 --- a/source/ps/scripting/JSInterface_Game.cpp +++ b/source/ps/scripting/JSInterface_Game.cpp @@ -23,6 +23,7 @@ #include "network/NetClient.h" #include "network/NetServer.h" #include "ps/CLogger.h" +#include "ps/Filesystem.h" #include "ps/Game.h" #include "ps/GameSetup/GameSetup.h" #include "ps/Replay.h" diff --git a/source/renderer/DecalRData.h b/source/renderer/DecalRData.h index 97608152d0..bdcb21241b 100644 --- a/source/renderer/DecalRData.h +++ b/source/renderer/DecalRData.h @@ -19,7 +19,6 @@ #define INCLUDED_DECALRDATA #include "graphics/RenderableObject.h" -#include "graphics/ShaderProgramPtr.h" #include "maths/Vector2D.h" #include "maths/Vector3D.h" #include "renderer/VertexBufferManager.h" diff --git a/source/renderer/OverlayRenderer.cpp b/source/renderer/OverlayRenderer.cpp index 13924c30ad..cee047a9ba 100644 --- a/source/renderer/OverlayRenderer.cpp +++ b/source/renderer/OverlayRenderer.cpp @@ -22,6 +22,7 @@ #include "graphics/Camera.h" #include "graphics/LOSTexture.h" #include "graphics/Overlay.h" +#include "graphics/ShaderManager.h" #include "graphics/Terrain.h" #include "graphics/TextureManager.h" #include "lib/hash.h" diff --git a/source/renderer/OverlayRenderer.h b/source/renderer/OverlayRenderer.h index 4327caf2b9..126287e9b4 100644 --- a/source/renderer/OverlayRenderer.h +++ b/source/renderer/OverlayRenderer.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2013 Wildfire Games. +/* Copyright (C) 2021 Wildfire Games. * This file is part of 0 A.D. * * 0 A.D. is free software: you can redistribute it and/or modify @@ -18,7 +18,7 @@ #ifndef INCLUDED_OVERLAYRENDERER #define INCLUDED_OVERLAYRENDERER -#include "graphics/ShaderManager.h" +#include "graphics/ShaderProgramPtr.h" struct SOverlayLine; struct SOverlayTexturedLine; diff --git a/source/renderer/PatchRData.h b/source/renderer/PatchRData.h index e6c26ea547..42c5e9738a 100644 --- a/source/renderer/PatchRData.h +++ b/source/renderer/PatchRData.h @@ -20,7 +20,6 @@ #include "graphics/Patch.h" #include "graphics/RenderableObject.h" -#include "graphics/SColor.h" #include "graphics/ShaderProgramPtr.h" #include "maths/Vector2D.h" #include "maths/Vector3D.h" diff --git a/source/renderer/TexturedLineRData.cpp b/source/renderer/TexturedLineRData.cpp index 96592e5166..c64cb57088 100644 --- a/source/renderer/TexturedLineRData.cpp +++ b/source/renderer/TexturedLineRData.cpp @@ -19,6 +19,7 @@ #include "TexturedLineRData.h" +#include "graphics/ShaderProgram.h" #include "graphics/Terrain.h" #include "maths/Frustum.h" #include "maths/MathUtil.h" diff --git a/source/simulation2/components/CCmpRallyPointRenderer.cpp b/source/simulation2/components/CCmpRallyPointRenderer.cpp index 275ada1d96..08c449f7b9 100644 --- a/source/simulation2/components/CCmpRallyPointRenderer.cpp +++ b/source/simulation2/components/CCmpRallyPointRenderer.cpp @@ -18,6 +18,7 @@ #include "precompiled.h" #include "CCmpRallyPointRenderer.h" +#include "ps/Profile.h" #include "simulation2/components/ICmpRangeManager.h" #include "simulation2/helpers/Los.h" diff --git a/source/simulation2/components/CCmpRallyPointRenderer.h b/source/simulation2/components/CCmpRallyPointRenderer.h index 73c7b757ac..238568557c 100644 --- a/source/simulation2/components/CCmpRallyPointRenderer.h +++ b/source/simulation2/components/CCmpRallyPointRenderer.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2019 Wildfire Games. +/* Copyright (C) 2021 Wildfire Games. * This file is part of 0 A.D. * * 0 A.D. is free software: you can redistribute it and/or modify @@ -19,8 +19,11 @@ #define INCLUDED_CCMPRALLYPOINTRENDERER #include "ICmpRallyPointRenderer.h" + #include "graphics/Overlay.h" #include "graphics/TextureManager.h" +#include "ps/CLogger.h" +#include "renderer/Renderer.h" #include "simulation2/MessageTypes.h" #include "simulation2/components/ICmpFootprint.h" #include "simulation2/components/ICmpObstructionManager.h" @@ -36,10 +39,6 @@ #include "simulation2/helpers/Geometry.h" #include "simulation2/system/Component.h" -#include "ps/CLogger.h" -#include "ps/Profile.h" -#include "renderer/Renderer.h" - struct SVisibilitySegment { bool m_Visible; diff --git a/source/simulation2/components/ICmpPathfinder.h b/source/simulation2/components/ICmpPathfinder.h index f6a5cd0b9e..ea406f39b7 100644 --- a/source/simulation2/components/ICmpPathfinder.h +++ b/source/simulation2/components/ICmpPathfinder.h @@ -23,8 +23,6 @@ #include "simulation2/components/ICmpObstruction.h" #include "simulation2/helpers/Pathfinding.h" -#include "maths/FixedVector2D.h" - #include class IObstructionTestFilter; diff --git a/source/tools/atlas/GameInterface/Handlers/GraphicsSetupHandlers.cpp b/source/tools/atlas/GameInterface/Handlers/GraphicsSetupHandlers.cpp index d4a0170249..79aa03ae3f 100644 --- a/source/tools/atlas/GameInterface/Handlers/GraphicsSetupHandlers.cpp +++ b/source/tools/atlas/GameInterface/Handlers/GraphicsSetupHandlers.cpp @@ -1,4 +1,4 @@ -/* Copyright (C) 2019 Wildfire Games. +/* Copyright (C) 2021 Wildfire Games. * This file is part of 0 A.D. * * 0 A.D. is free software: you can redistribute it and/or modify @@ -32,6 +32,7 @@ #include "lib/timer.h" #include "maths/MathUtil.h" #include "ps/CConsole.h" +#include "ps/Filesystem.h" #include "ps/Profile.h" #include "ps/Profiler2.h" #include "ps/Game.h"