Cleanup: move variable declarations to headers
authorCampbell Barton <ideasman42@gmail.com>
Sat, 23 Feb 2019 01:58:39 +0000 (12:58 +1100)
committerCampbell Barton <ideasman42@gmail.com>
Sat, 23 Feb 2019 01:59:13 +0000 (12:59 +1100)
Quiet undeclared variable warning.

source/blender/blenkernel/BKE_curve.h
source/blender/blenkernel/BKE_gpencil.h
source/blender/blenkernel/BKE_lattice.h
source/blender/blenkernel/BKE_mball.h
source/blender/blenkernel/BKE_mesh.h
source/blender/blenkernel/BKE_particle.h
source/blender/draw/intern/draw_manager.c

index b5a4b0f..f6ceea0 100644 (file)
@@ -236,4 +236,7 @@ void BKE_curve_decimate_nurb(
         struct Nurb *nu, const unsigned int resolu,
         const float error_sq_max, const unsigned int error_target_len);
 
+extern void (*BKE_curve_batch_cache_dirty_tag_cb)(struct Curve *cu, int mode);
+extern void (*BKE_curve_batch_cache_free_cb)(struct Curve *cu);
+
 #endif  /* __BKE_CURVE_H__ */
index f1201ba..a33f172 100644 (file)
@@ -178,4 +178,7 @@ bool BKE_gpencil_smooth_stroke_uv(struct bGPDstroke *gps, int point_index, float
 void BKE_gpencil_get_range_selected(struct bGPDlayer *gpl, int *r_initframe, int *r_endframe);
 float BKE_gpencil_multiframe_falloff_calc(struct bGPDframe *gpf, int actnum, int f_init, int f_end, struct CurveMapping *cur_falloff);
 
+extern void (*BKE_gpencil_batch_cache_dirty_tag_cb)(struct bGPdata *gpd);
+extern void (*BKE_gpencil_batch_cache_free_cb)(struct bGPdata *gpd);
+
 #endif /*  __BKE_GPENCIL_H__ */
index 233b272..d7597d6 100644 (file)
@@ -109,4 +109,7 @@ enum {
 void BKE_lattice_batch_cache_dirty_tag(struct Lattice *lt, int mode);
 void BKE_lattice_batch_cache_free(struct Lattice *lt);
 
+extern void (*BKE_lattice_batch_cache_dirty_tag_cb)(struct Lattice *lt, int mode);
+extern void (*BKE_lattice_batch_cache_free_cb)(struct Lattice *lt);
+
 #endif  /* __BKE_LATTICE_H__ */
index 0b0ee6f..fc06527 100644 (file)
@@ -83,4 +83,8 @@ enum {
 void BKE_mball_batch_cache_dirty_tag(struct MetaBall *mb, int mode);
 void BKE_mball_batch_cache_free(struct MetaBall *mb);
 
+extern void (*BKE_mball_batch_cache_dirty_tag_cb)(struct MetaBall *mb, int mode);
+extern void (*BKE_mball_batch_cache_free_cb)(struct MetaBall *mb);
+
+
 #endif
index 90afaaf..d6b9f0a 100644 (file)
@@ -516,6 +516,9 @@ enum {
 void BKE_mesh_batch_cache_dirty_tag(struct Mesh *me, int mode);
 void BKE_mesh_batch_cache_free(struct Mesh *me);
 
+extern void (*BKE_mesh_batch_cache_dirty_tag_cb)(struct Mesh *me, int mode);
+extern void (*BKE_mesh_batch_cache_free_cb)(struct Mesh *me);
+
 
 /* Inlines */
 
index 3f7c39a..129bd1a 100644 (file)
@@ -486,4 +486,7 @@ enum {
 void BKE_particle_batch_cache_dirty_tag(struct ParticleSystem *psys, int mode);
 void BKE_particle_batch_cache_free(struct ParticleSystem *psys);
 
+extern void (*BKE_particle_batch_cache_dirty_tag_cb)(struct ParticleSystem *psys, int mode);
+extern void (*BKE_particle_batch_cache_free_cb)(struct ParticleSystem *psys);
+
 #endif  /* __BKE_PARTICLE_H__ */
index e8a7d36..166b499 100644 (file)
 #include "BLF_api.h"
 
 #include "BKE_colortools.h"
+#include "BKE_curve.h"
 #include "BKE_global.h"
+#include "BKE_gpencil.h"
+#include "BKE_lattice.h"
+#include "BKE_mball.h"
+#include "BKE_mesh.h"
 #include "BKE_object.h"
 #include "BKE_particle.h"
 #include "BKE_pointcache.h"
@@ -2547,25 +2552,6 @@ void DRW_engines_register(void)
 
        /* setup callbacks */
        {
-               /* BKE: mball.c */
-               extern void *BKE_mball_batch_cache_dirty_tag_cb;
-               extern void *BKE_mball_batch_cache_free_cb;
-               /* BKE: curve.c */
-               extern void *BKE_curve_batch_cache_dirty_tag_cb;
-               extern void *BKE_curve_batch_cache_free_cb;
-               /* BKE: mesh.c */
-               extern void *BKE_mesh_batch_cache_dirty_tag_cb;
-               extern void *BKE_mesh_batch_cache_free_cb;
-               /* BKE: lattice.c */
-               extern void *BKE_lattice_batch_cache_dirty_tag_cb;
-               extern void *BKE_lattice_batch_cache_free_cb;
-               /* BKE: particle.c */
-               extern void *BKE_particle_batch_cache_dirty_tag_cb;
-               extern void *BKE_particle_batch_cache_free_cb;
-               /* BKE: gpencil.c */
-               extern void *BKE_gpencil_batch_cache_dirty_tag_cb;
-               extern void *BKE_gpencil_batch_cache_free_cb;
-
                BKE_mball_batch_cache_dirty_tag_cb = DRW_mball_batch_cache_dirty_tag;
                BKE_mball_batch_cache_free_cb = DRW_mball_batch_cache_free;