Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2019-09-07 16:17:40 +0300
committerYimingWu <xp8110@outlook.com>2019-09-12 04:13:02 +0300
commitf5d493dd48d807b10436172e7b4a3ba1b3d218f5 (patch)
tree873f6ca866757adcce60fac7360fd2ea919411ec
parent4afacf55f60447fc5b85a66d18fb5f14daba5e3c (diff)
Cleanup: includes in headers
Forward declare structs where possible.
-rw-r--r--source/blender/blenkernel/BKE_camera.h2
-rw-r--r--source/blender/blenkernel/BKE_gpencil_modifier.h2
-rw-r--r--source/blender/blenkernel/BKE_mesh.h3
-rw-r--r--source/blender/blenkernel/BKE_node.h18
-rw-r--r--source/blender/blenkernel/BKE_pbvh.h1
-rw-r--r--source/blender/blenkernel/BKE_studiolight.h15
-rw-r--r--source/blender/blenkernel/intern/image.c2
-rw-r--r--source/blender/blenkernel/intern/scene.c1
-rw-r--r--source/blender/blenloader/intern/versioning_260.c2
-rw-r--r--source/blender/blenloader/intern/versioning_270.c1
-rw-r--r--source/blender/blenloader/intern/versioning_280.c1
-rw-r--r--source/blender/blenloader/intern/versioning_defaults.c1
-rw-r--r--source/blender/draw/engines/workbench/workbench_render.c2
13 files changed, 25 insertions, 26 deletions
diff --git a/source/blender/blenkernel/BKE_camera.h b/source/blender/blenkernel/BKE_camera.h
index da80b3d5032..d1c133c79b5 100644
--- a/source/blender/blenkernel/BKE_camera.h
+++ b/source/blender/blenkernel/BKE_camera.h
@@ -28,8 +28,6 @@
extern "C" {
#endif
-#include "DNA_vec_types.h"
-
struct Camera;
struct Depsgraph;
struct Main;
diff --git a/source/blender/blenkernel/BKE_gpencil_modifier.h b/source/blender/blenkernel/BKE_gpencil_modifier.h
index 36f38996c36..ba2e1e85d23 100644
--- a/source/blender/blenkernel/BKE_gpencil_modifier.h
+++ b/source/blender/blenkernel/BKE_gpencil_modifier.h
@@ -21,8 +21,6 @@
*/
#include "DNA_gpencil_modifier_types.h" /* needed for all enum typdefs */
-#include "BLI_compiler_attrs.h"
-#include "BKE_customdata.h"
struct Depsgraph;
struct GpencilModifierData;
diff --git a/source/blender/blenkernel/BKE_mesh.h b/source/blender/blenkernel/BKE_mesh.h
index 12978e46327..a260621ac2c 100644
--- a/source/blender/blenkernel/BKE_mesh.h
+++ b/source/blender/blenkernel/BKE_mesh.h
@@ -26,9 +26,6 @@
/* defines BLI_INLINE */
#include "BLI_compiler_compat.h"
-/* defines CustomDataMask */
-//#include "BKE_customdata.h"
-
struct BLI_Stack;
struct BMEditMesh;
struct BMesh;
diff --git a/source/blender/blenkernel/BKE_node.h b/source/blender/blenkernel/BKE_node.h
index cbfc8ffc7d0..98710394079 100644
--- a/source/blender/blenkernel/BKE_node.h
+++ b/source/blender/blenkernel/BKE_node.h
@@ -30,13 +30,7 @@
#include "DNA_listBase.h"
/* for FOREACH_NODETREE_BEGIN */
-#include "DNA_light_types.h"
-#include "DNA_material_types.h"
#include "DNA_node_types.h"
-#include "DNA_scene_types.h"
-#include "DNA_texture_types.h"
-#include "DNA_world_types.h"
-#include "DNA_linestyle_types.h"
#include "RNA_types.h"
@@ -46,19 +40,23 @@
struct ARegion;
struct ColorManagedDisplaySettings;
struct ColorManagedViewSettings;
+struct FreestyleLineStyle;
struct GPUMaterial;
struct GPUNodeStack;
struct ID;
struct ImBuf;
struct ImageFormatData;
+struct Light;
struct ListBase;
struct MTex;
struct Main;
+struct Material;
struct PointerRNA;
struct RenderData;
struct Scene;
struct SpaceNode;
struct Tex;
+struct World;
struct bContext;
struct bNode;
struct bNodeExecContext;
@@ -832,11 +830,11 @@ void BKE_node_tree_unlink_id(ID *id, struct bNodeTree *ntree);
struct NodeTreeIterStore {
bNodeTree *ngroup;
Scene *scene;
- Material *mat;
+ struct Material *mat;
Tex *tex;
- Light *light;
- World *world;
- FreestyleLineStyle *linestyle;
+ struct Light *light;
+ struct World *world;
+ struct FreestyleLineStyle *linestyle;
};
void BKE_node_tree_iter_init(struct NodeTreeIterStore *ntreeiter, struct Main *bmain);
diff --git a/source/blender/blenkernel/BKE_pbvh.h b/source/blender/blenkernel/BKE_pbvh.h
index f02d41d3c65..899dddf31e8 100644
--- a/source/blender/blenkernel/BKE_pbvh.h
+++ b/source/blender/blenkernel/BKE_pbvh.h
@@ -24,7 +24,6 @@
#include "BLI_bitmap.h"
#include "BLI_ghash.h"
-#include "BLI_utildefines.h"
struct BMLog;
struct BMesh;
diff --git a/source/blender/blenkernel/BKE_studiolight.h b/source/blender/blenkernel/BKE_studiolight.h
index 108e93d9caa..c6d1e61fb47 100644
--- a/source/blender/blenkernel/BKE_studiolight.h
+++ b/source/blender/blenkernel/BKE_studiolight.h
@@ -26,14 +26,13 @@
* Studio lighting for the 3dview
*/
-#include "BKE_context.h"
-
#include "BLI_sys_types.h"
-#include "DNA_space_types.h"
+#include "BLI_path_util.h"
+
#include "DNA_userdef_types.h"
-#include "IMB_imbuf_types.h"
+struct ImBuf;
/*
* These defines are the indexes in the StudioLight.diffuse_light
@@ -103,7 +102,7 @@ enum StudioLightFlag {
typedef void StudioLightFreeFunction(struct StudioLight *, void *data);
typedef struct StudioLightImage {
- ImBuf *ibuf;
+ struct ImBuf *ibuf;
struct GPUTexture *gputexture;
} StudioLightImage;
@@ -124,9 +123,9 @@ typedef struct StudioLight {
float light_direction[3];
StudioLightImage matcap_diffuse;
StudioLightImage matcap_specular;
- ImBuf *equirect_radiance_buffer;
- ImBuf *equirect_irradiance_buffer;
- ImBuf *radiance_cubemap_buffers[6];
+ struct ImBuf *equirect_radiance_buffer;
+ struct ImBuf *equirect_irradiance_buffer;
+ struct ImBuf *radiance_cubemap_buffers[6];
struct GPUTexture *equirect_radiance_gputexture;
struct GPUTexture *equirect_irradiance_gputexture;
SolidLight light[STUDIOLIGHT_MAX_LIGHT];
diff --git a/source/blender/blenkernel/intern/image.c b/source/blender/blenkernel/intern/image.c
index a99407b9bf9..523c0199daa 100644
--- a/source/blender/blenkernel/intern/image.c
+++ b/source/blender/blenkernel/intern/image.c
@@ -55,6 +55,8 @@
#include "DNA_brush_types.h"
#include "DNA_mesh_types.h"
#include "DNA_meshdata_types.h"
+#include "DNA_light_types.h"
+#include "DNA_world_types.h"
#include "BLI_blenlib.h"
#include "BLI_math_vector.h"
diff --git a/source/blender/blenkernel/intern/scene.c b/source/blender/blenkernel/intern/scene.c
index cf2b6454a2c..aac16e31b87 100644
--- a/source/blender/blenkernel/intern/scene.c
+++ b/source/blender/blenkernel/intern/scene.c
@@ -43,6 +43,7 @@
#include "DNA_windowmanager_types.h"
#include "DNA_workspace_types.h"
#include "DNA_gpencil_types.h"
+#include "DNA_world_types.h"
#include "BLI_math.h"
#include "BLI_blenlib.h"
diff --git a/source/blender/blenloader/intern/versioning_260.c b/source/blender/blenloader/intern/versioning_260.c
index 6f5c37d716e..31f6f93e856 100644
--- a/source/blender/blenloader/intern/versioning_260.c
+++ b/source/blender/blenloader/intern/versioning_260.c
@@ -41,6 +41,8 @@
#include "DNA_sdna_types.h"
#include "DNA_smoke_types.h"
#include "DNA_space_types.h"
+#include "DNA_world_types.h"
+#include "DNA_light_types.h"
#include "MEM_guardedalloc.h"
diff --git a/source/blender/blenloader/intern/versioning_270.c b/source/blender/blenloader/intern/versioning_270.c
index 5010cc8071d..3d55891bb0a 100644
--- a/source/blender/blenloader/intern/versioning_270.c
+++ b/source/blender/blenloader/intern/versioning_270.c
@@ -48,6 +48,7 @@
#include "DNA_view3d_types.h"
#include "DNA_smoke_types.h"
#include "DNA_rigidbody_types.h"
+#include "DNA_light_types.h"
#include "DNA_genfile.h"
diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c
index 6f3c309cd55..b1a6bcecd00 100644
--- a/source/blender/blenloader/intern/versioning_280.c
+++ b/source/blender/blenloader/intern/versioning_280.c
@@ -55,6 +55,7 @@
#include "DNA_curve_types.h"
#include "DNA_armature_types.h"
#include "DNA_text_types.h"
+#include "DNA_world_types.h"
#include "BKE_action.h"
#include "BKE_animsys.h"
diff --git a/source/blender/blenloader/intern/versioning_defaults.c b/source/blender/blenloader/intern/versioning_defaults.c
index 657e79f718a..1c91871694f 100644
--- a/source/blender/blenloader/intern/versioning_defaults.c
+++ b/source/blender/blenloader/intern/versioning_defaults.c
@@ -38,6 +38,7 @@
#include "DNA_workspace_types.h"
#include "DNA_mesh_types.h"
#include "DNA_meshdata_types.h"
+#include "DNA_light_types.h"
#include "BKE_appdir.h"
#include "BKE_colortools.h"
diff --git a/source/blender/draw/engines/workbench/workbench_render.c b/source/blender/draw/engines/workbench/workbench_render.c
index b4e5e98c92b..899fbdc9b71 100644
--- a/source/blender/draw/engines/workbench/workbench_render.c
+++ b/source/blender/draw/engines/workbench/workbench_render.c
@@ -24,6 +24,8 @@
#include "BLI_rect.h"
+#include "DNA_node_types.h"
+
#include "BKE_report.h"
#include "DRW_render.h"