[Bf-blender-cvs] [ac7d45cc196] blenloader-api: try different naming convention

Jacques Lucke noreply at git.blender.org
Sat Mar 7 19:09:26 CET 2020


Commit: ac7d45cc19667f161445ee5788a836c9c2672e7d
Author: Jacques Lucke
Date:   Sat Mar 7 16:30:33 2020 +0100
Branches: blenloader-api
https://developer.blender.org/rBac7d45cc19667f161445ee5788a836c9c2672e7d

try different naming convention

===================================================================

M	source/blender/blenkernel/BKE_colortools.h
M	source/blender/blenkernel/BKE_curveprofile.h
M	source/blender/blenkernel/BKE_pointcache.h
M	source/blender/blenkernel/intern/colortools.c
M	source/blender/blenkernel/intern/curveprofile.c
M	source/blender/blenkernel/intern/pointcache.c
M	source/blender/blenloader/intern/writefile.c

===================================================================

diff --git a/source/blender/blenkernel/BKE_colortools.h b/source/blender/blenkernel/BKE_colortools.h
index 5152612040e..def5eedd43b 100644
--- a/source/blender/blenkernel/BKE_colortools.h
+++ b/source/blender/blenkernel/BKE_colortools.h
@@ -53,8 +53,8 @@ void BKE_curvemapping_set_black_white_ex(const float black[3],
 void BKE_curvemapping_set_black_white(struct CurveMapping *cumap,
                                       const float black[3],
                                       const float white[3]);
-void BKE_curvemapping_write_file(struct BloWriter *writer, struct CurveMapping *cumap);
-void BKE_curvemapping_curves_write_file(struct BloWriter *writer, struct CurveMapping *cumap);
+void BKE_curvemapping_blo_write_ptr(struct BloWriter *writer, struct CurveMapping *cumap);
+void BKE_curvemapping_blo_write_struct(struct BloWriter *writer, struct CurveMapping *cumap);
 void BKE_curvemapping_read_file(struct BloReader *reader, struct CurveMapping *cumap);
 
 enum {
diff --git a/source/blender/blenkernel/BKE_curveprofile.h b/source/blender/blenkernel/BKE_curveprofile.h
index 9d0a17a527a..13c18e78aba 100644
--- a/source/blender/blenkernel/BKE_curveprofile.h
+++ b/source/blender/blenkernel/BKE_curveprofile.h
@@ -80,7 +80,7 @@ void BKE_curveprofile_evaluate_length_portion(const struct CurveProfile *profile
                                               float *x_out,
                                               float *y_out);
 
-void BKE_curveprofile_write_file(struct BloWriter *writer, const struct CurveProfile *profile);
+void BKE_curveprofile_blo_write_ptr(struct BloWriter *writer, const struct CurveProfile *profile);
 void BKE_curveprofile_read_file(struct BloReader *reader, struct CurveProfile *profile);
 
 #ifdef __cplusplus
diff --git a/source/blender/blenkernel/BKE_pointcache.h b/source/blender/blenkernel/BKE_pointcache.h
index aa68de4684c..0e3801fe35d 100644
--- a/source/blender/blenkernel/BKE_pointcache.h
+++ b/source/blender/blenkernel/BKE_pointcache.h
@@ -342,7 +342,7 @@ int BKE_ptcache_read(PTCacheID *pid, float cfra, bool no_extrapolate_old);
 /* Main cache writing call. */
 int BKE_ptcache_write(PTCacheID *pid, unsigned int cfra);
 
-void BKE_ptcache_file_write(struct BloWriter *writer, struct ListBase *ptcaches);
+void BKE_ptcache_blo_write_list(struct BloWriter *writer, struct ListBase *ptcaches);
 void BKE_ptcache_file_read(struct BloReader *reader,
                            struct ListBase *ptcaches,
                            struct PointCache **ocache,
diff --git a/source/blender/blenkernel/intern/colortools.c b/source/blender/blenkernel/intern/colortools.c
index 2725bcb7a2c..53fbdf84827 100644
--- a/source/blender/blenkernel/intern/colortools.c
+++ b/source/blender/blenkernel/intern/colortools.c
@@ -180,13 +180,13 @@ void BKE_curvemapping_set_black_white(CurveMapping *cumap,
   cumap->changed_timestamp++;
 }
 
-void BKE_curvemapping_write_file(BloWriter *writer, CurveMapping *cumap)
+void BKE_curvemapping_blo_write_ptr(BloWriter *writer, CurveMapping *cumap)
 {
   BLO_write_struct(writer, CurveMapping, cumap);
-  BKE_curvemapping_curves_write_file(writer, cumap);
+  BKE_curvemapping_blo_write_struct(writer, cumap);
 }
 
-void BKE_curvemapping_curves_write_file(BloWriter *writer, CurveMapping *cumap)
+void BKE_curvemapping_blo_write_struct(BloWriter *writer, CurveMapping *cumap)
 {
   for (int i = 0; i < CM_TOT; i++) {
     BLO_write_struct_array(writer, CurveMapPoint, cumap->cm[i].totpoint, cumap->cm[i].curve);
diff --git a/source/blender/blenkernel/intern/curveprofile.c b/source/blender/blenkernel/intern/curveprofile.c
index 443c7d5508d..1f1ce5cbda9 100644
--- a/source/blender/blenkernel/intern/curveprofile.c
+++ b/source/blender/blenkernel/intern/curveprofile.c
@@ -1073,7 +1073,7 @@ void BKE_curveprofile_evaluate_length_portion(const CurveProfile *profile,
   *y_out = interpf(profile->table[i].y, profile->table[i + 1].y, lerp_factor);
 }
 
-void BKE_curveprofile_write_file(BloWriter *writer, const CurveProfile *profile)
+void BKE_curveprofile_blo_write_ptr(BloWriter *writer, const CurveProfile *profile)
 {
   BLO_write_struct(writer, CurveProfile, profile);
   BLO_write_struct_array(writer, CurveProfilePoint, profile->path_len, profile->path);
diff --git a/source/blender/blenkernel/intern/pointcache.c b/source/blender/blenkernel/intern/pointcache.c
index 1d33aeee5c6..1fe2df48b9a 100644
--- a/source/blender/blenkernel/intern/pointcache.c
+++ b/source/blender/blenkernel/intern/pointcache.c
@@ -3363,7 +3363,7 @@ static const char *ptcache_extra_struct[] = {
     "ParticleSpring",
 };
 
-void BKE_ptcache_file_write(BloWriter *writer, ListBase *ptcaches)
+void BKE_ptcache_blo_write_list(BloWriter *writer, ListBase *ptcaches)
 {
   PointCache *cache = ptcaches->first;
   int i;
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c
index 95e258f709f..be8a0b29f7c 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -1041,7 +1041,7 @@ static void write_nodetree_nolib(WriteData *wd, bNodeTree *ntree)
       /* could be handlerized at some point, now only 1 exception still */
       if ((ntree->type == NTREE_SHADER) &&
           ELEM(node->type, SH_NODE_CURVE_VEC, SH_NODE_CURVE_RGB)) {
-        BKE_curvemapping_write_file(wrap_writer(wd), node->storage);
+        BKE_curvemapping_blo_write_ptr(wrap_writer(wd), node->storage);
       }
       else if (ntree->type == NTREE_SHADER && (node->type == SH_NODE_SCRIPT)) {
         NodeShaderScript *nss = (NodeShaderScript *)node->storage;
@@ -1055,11 +1055,11 @@ static void write_nodetree_nolib(WriteData *wd, bNodeTree *ntree)
                                                        CMP_NODE_CURVE_VEC,
                                                        CMP_NODE_CURVE_RGB,
                                                        CMP_NODE_HUECORRECT)) {
-        BKE_curvemapping_write_file(wrap_writer(wd), node->storage);
+        BKE_curvemapping_blo_write_ptr(wrap_writer(wd), node->storage);
       }
       else if ((ntree->type == NTREE_TEXTURE) &&
                (node->type == TEX_NODE_CURVE_RGB || node->type == TEX_NODE_CURVE_TIME)) {
-        BKE_curvemapping_write_file(wrap_writer(wd), node->storage);
+        BKE_curvemapping_blo_write_ptr(wrap_writer(wd), node->storage);
       }
       else if ((ntree->type == NTREE_COMPOSIT) && (node->type == CMP_NODE_MOVIEDISTORTION)) {
         /* pass */
@@ -1332,13 +1332,13 @@ static void write_particlesettings(WriteData *wd, ParticleSettings *part)
     writestruct(wd, DATA, EffectorWeights, 1, part->effector_weights);
 
     if (part->clumpcurve) {
-      BKE_curvemapping_write_file(wrap_writer(wd), part->clumpcurve);
+      BKE_curvemapping_blo_write_ptr(wrap_writer(wd), part->clumpcurve);
     }
     if (part->roughcurve) {
-      BKE_curvemapping_write_file(wrap_writer(wd), part->roughcurve);
+      BKE_curvemapping_blo_write_ptr(wrap_writer(wd), part->roughcurve);
     }
     if (part->twistcurve) {
-      BKE_curvemapping_write_file(wrap_writer(wd), part->twistcurve);
+      BKE_curvemapping_blo_write_ptr(wrap_writer(wd), part->twistcurve);
     }
 
     for (ParticleDupliWeight *dw = part->instance_weights.first; dw; dw = dw->next) {
@@ -1421,7 +1421,7 @@ static void write_particlesystems(WriteData *wd, ListBase *particles)
       writestruct(wd, DATA, ClothCollSettings, 1, psys->clmd->coll_parms);
     }
 
-    BKE_ptcache_file_write(wrap_writer(wd), &psys->ptcaches);
+    BKE_ptcache_blo_write_list(wrap_writer(wd), &psys->ptcaches);
   }
 }
 
@@ -1578,7 +1578,7 @@ static void write_modifiers(WriteData *wd, ListBase *modbase)
       HookModifierData *hmd = (HookModifierData *)md;
 
       if (hmd->curfalloff) {
-        BKE_curvemapping_write_file(wrap_writer(wd), hmd->curfalloff);
+        BKE_curvemapping_blo_write_ptr(wrap_writer(wd), hmd->curfalloff);
       }
 
       writedata(wd, DATA, sizeof(int) * hmd->totindex, hmd->indexar);
@@ -1589,7 +1589,7 @@ static void write_modifiers(WriteData *wd, ListBase *modbase)
       writestruct(wd, DATA, ClothSimSettings, 1, clmd->sim_parms);
       writestruct(wd, DATA, ClothCollSettings, 1, clmd->coll_parms);
       writestruct(wd, DATA, EffectorWeights, 1, clmd->sim_parms->effector_weights);
-      BKE_ptcache_file_write(wrap_writer(wd), &clmd->ptcaches);
+      BKE_ptcache_blo_write_list(wrap_writer(wd), &clmd->ptcaches);
     }
     else if (md->type == eModifierType_Fluid) {
       FluidModifierData *mmd = (FluidModifierData *)md;
@@ -1598,14 +1598,14 @@ static void write_modifiers(WriteData *wd, ListBase *modbase)
         writestruct(wd, DATA, FluidDomainSettings, 1, mmd->domain);
 
         if (mmd->domain) {
-          BKE_ptcache_file_write(wrap_writer(wd), &(mmd->domain->ptcaches[0]));
+          BKE_ptcache_blo_write_list(wrap_writer(wd), &(mmd->domain->ptcaches[0]));
 
           /* create fake pointcache so that old blender versions can read it */
           mmd->domain->point_cache[1] = BKE_ptcache_add(&mmd->domain->ptcaches[1]);
           mmd->domain->point_cache[1]->flag |= PTCACHE_DISK_CACHE | PTCACHE_FAKE_SMOKE;
           mmd->domain->point_cache[1]->step = 1;
 
-          BKE_ptcache_file_write(wrap_writer(wd), &(mmd->domain->ptcaches[1]));
+          BKE_ptcache_blo_write_list(wrap_writer(wd), &(mmd->domain->ptcaches[1]));
 
           if (mmd->domain->coba) {
             writestruct(wd, DATA, ColorBand, 1, mmd->domain->coba);
@@ -1643,7 +1643,7 @@ static void write_modifiers(WriteData *wd, ListBase *modbase)
         }
         /* write caches and effector weights */
         for (surface = pmd->canvas->surfaces.first; surface; surface = surface->next) {
-          BKE_ptcache_file_write(wrap_writer(wd), &(surface->ptcaches));
+          BKE_ptcache_blo_write_list(wrap_writer(wd), &(surface->ptcaches));
 
           writestruct(wd, DATA, EffectorWeights, 1, surface->effector_weights);
         }
@@ -1679,14 +1679,14 @@ static void write_modifiers(WriteData *wd, ListBase *modbase)
     else if (md->type == eModifierType_Warp) {
       WarpModifierData *tmd = (WarpModifierData *)md;
       if (tmd->curfalloff) {
-        BKE_curvemapping_write_file(wrap_writ

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list