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>2020-10-10 10:19:55 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-10-10 14:04:51 +0300
commit2abfcebb0eb7989e3d1e7d03f37ecf5c088210af (patch)
treee7a1ad5912b4661d4ece743f4f7fd86e6bf4d3c4 /source/blender/blenloader/intern
parentc735aca42e9f5961fec7e5d5fc196b5bd6b85f56 (diff)
Cleanup: use C comments for descriptive text
Follow our code style guide by using C-comments for text descriptions.
Diffstat (limited to 'source/blender/blenloader/intern')
-rw-r--r--source/blender/blenloader/intern/blend_validate.c2
-rw-r--r--source/blender/blenloader/intern/readfile.c83
-rw-r--r--source/blender/blenloader/intern/versioning_250.c6
-rw-r--r--source/blender/blenloader/intern/versioning_260.c12
-rw-r--r--source/blender/blenloader/intern/versioning_280.c8
-rw-r--r--source/blender/blenloader/intern/versioning_legacy.c10
-rw-r--r--source/blender/blenloader/intern/writefile.c4
7 files changed, 63 insertions, 62 deletions
diff --git a/source/blender/blenloader/intern/blend_validate.c b/source/blender/blenloader/intern/blend_validate.c
index 0a5d8d332aa..2848aac2c77 100644
--- a/source/blender/blenloader/intern/blend_validate.c
+++ b/source/blender/blenloader/intern/blend_validate.c
@@ -23,7 +23,7 @@
* \note Does not *fix* anything, only reports found errors.
*/
-#include <string.h> // for strrchr strncmp strstr
+#include <string.h> /* for strrchr strncmp strstr */
#include "BLI_utildefines.h"
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 9465819a2d8..ccf4e08b5b7 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -33,11 +33,11 @@
#include "BLI_utildefines.h"
#ifndef WIN32
-# include <unistd.h> // for read close
+# include <unistd.h> /* for read close */
#else
# include "BLI_winstuff.h"
# include "winsock2.h"
-# include <io.h> // for open close read
+# include <io.h> /* for open close read */
#endif
/* allow readfile to use deprecated functionality */
@@ -126,7 +126,7 @@
#include "BKE_fcurve.h"
#include "BKE_fcurve_driver.h"
#include "BKE_fluid.h"
-#include "BKE_global.h" // for G
+#include "BKE_global.h" /* for G */
#include "BKE_gpencil.h"
#include "BKE_gpencil_modifier.h"
#include "BKE_hair.h"
@@ -138,15 +138,15 @@
#include "BKE_lib_id.h"
#include "BKE_lib_override.h"
#include "BKE_lib_query.h"
-#include "BKE_main.h" // for Main
+#include "BKE_main.h" /* for Main */
#include "BKE_main_idmap.h"
#include "BKE_material.h"
-#include "BKE_mesh.h" // for ME_ defines (patching)
+#include "BKE_mesh.h" /* for ME_ defines (patching) */
#include "BKE_mesh_runtime.h"
#include "BKE_modifier.h"
#include "BKE_multires.h"
#include "BKE_nla.h"
-#include "BKE_node.h" // for tree type defines
+#include "BKE_node.h" /* for tree type defines */
#include "BKE_object.h"
#include "BKE_packedFile.h"
#include "BKE_paint.h"
@@ -1490,7 +1490,7 @@ static ssize_t fd_read_gzip_from_memory(FileData *filedata,
filedata->strm.next_out = (Bytef *)buffer;
filedata->strm.avail_out = (uint)size;
- // Inflate another chunk.
+ /* Inflate another chunk. */
err = inflate(&filedata->strm, Z_SYNC_FLUSH);
if (err == Z_STREAM_END) {
@@ -2490,7 +2490,7 @@ static void direct_link_id_common(
/** \name Read Animation (legacy for version patching)
* \{ */
-// XXX deprecated - old animation system
+/* XXX deprecated - old animation system */
static void lib_link_ipo(BlendLibReader *reader, Ipo *ipo)
{
LISTBASE_FOREACH (IpoCurve *, icu, &ipo->curve) {
@@ -2500,7 +2500,7 @@ static void lib_link_ipo(BlendLibReader *reader, Ipo *ipo)
}
}
-// XXX deprecated - old animation system
+/* XXX deprecated - old animation system */
static void direct_link_ipo(BlendDataReader *reader, Ipo *ipo)
{
BLO_read_list(reader, &(ipo->curve));
@@ -2538,7 +2538,7 @@ static void direct_link_ipo(BlendDataReader *reader, Ipo *ipo)
}
}
-// XXX deprecated - old animation system
+/* XXX deprecated - old animation system */
static void lib_link_nlastrips(BlendLibReader *reader, ID *id, ListBase *striplist)
{
LISTBASE_FOREACH (bActionStrip *, strip, striplist) {
@@ -2551,7 +2551,7 @@ static void lib_link_nlastrips(BlendLibReader *reader, ID *id, ListBase *stripli
}
}
-// XXX deprecated - old animation system
+/* XXX deprecated - old animation system */
static void direct_link_nlastrips(BlendDataReader *reader, ListBase *strips)
{
BLO_read_list(reader, strips);
@@ -2561,7 +2561,7 @@ static void direct_link_nlastrips(BlendDataReader *reader, ListBase *strips)
}
}
-// XXX deprecated - old animation system
+/* XXX deprecated - old animation system */
static void lib_link_constraint_channels(BlendLibReader *reader, ID *id, ListBase *chanbase)
{
LISTBASE_FOREACH (bConstraintChannel *, chan, chanbase) {
@@ -2680,7 +2680,7 @@ static void lib_link_constraints(BlendLibReader *reader, ID *id, ListBase *conli
con->type = CONSTRAINT_TYPE_NULL;
}
/* own ipo, all constraints have it */
- BLO_read_id_address(reader, id->lib, &con->ipo); // XXX deprecated - old animation system
+ BLO_read_id_address(reader, id->lib, &con->ipo); /* XXX deprecated - old animation system */
/* If linking from a library, clear 'local' library override flag. */
if (id->lib != NULL) {
@@ -2829,14 +2829,14 @@ void blo_do_versions_key_uidgen(Key *key)
/* update this also to writefile.c */
static const char *ptcache_data_struct[] = {
- "", // BPHYS_DATA_INDEX
- "", // BPHYS_DATA_LOCATION
- "", // BPHYS_DATA_VELOCITY
- "", // BPHYS_DATA_ROTATION
- "", // BPHYS_DATA_AVELOCITY / BPHYS_DATA_XCONST */
- "", // BPHYS_DATA_SIZE:
- "", // BPHYS_DATA_TIMES:
- "BoidData", // case BPHYS_DATA_BOIDS:
+ "", /* BPHYS_DATA_INDEX */
+ "", /* BPHYS_DATA_LOCATION */
+ "", /* BPHYS_DATA_VELOCITY */
+ "", /* BPHYS_DATA_ROTATION */
+ "", /* BPHYS_DATA_AVELOCITY / BPHYS_DATA_XCONST */
+ "", /* BPHYS_DATA_SIZE: */
+ "", /* BPHYS_DATA_TIMES: */
+ "BoidData", /* case BPHYS_DATA_BOIDS: */
};
static void direct_link_pointcache_cb(BlendDataReader *reader, void *data)
@@ -2923,7 +2923,8 @@ static void lib_link_partdeflect(BlendLibReader *reader, ID *id, PartDeflect *pd
static void lib_link_particlesettings(BlendLibReader *reader, ParticleSettings *part)
{
- BLO_read_id_address(reader, part->id.lib, &part->ipo); // XXX deprecated - old animation system
+ BLO_read_id_address(
+ reader, part->id.lib, &part->ipo); /* XXX deprecated - old animation system */
BLO_read_id_address(reader, part->id.lib, &part->instance_object);
BLO_read_id_address(reader, part->id.lib, &part->instance_collection);
@@ -3222,10 +3223,10 @@ static void lib_link_object(BlendLibReader *reader, Object *ob)
{
bool warn = false;
- // XXX deprecated - old animation system <<<
+ /* XXX deprecated - old animation system <<< */
BLO_read_id_address(reader, ob->id.lib, &ob->ipo);
BLO_read_id_address(reader, ob->id.lib, &ob->action);
- // >>> XXX deprecated - old animation system
+ /* >>> XXX deprecated - old animation system */
BLO_read_id_address(reader, ob->id.lib, &ob->parent);
BLO_read_id_address(reader, ob->id.lib, &ob->track);
@@ -3322,10 +3323,10 @@ static void lib_link_object(BlendLibReader *reader, Object *ob)
lib_link_pose(reader, ob, ob->pose);
lib_link_constraints(reader, &ob->id, &ob->constraints);
- // XXX deprecated - old animation system <<<
+ /* XXX deprecated - old animation system <<< */
lib_link_constraint_channels(reader, &ob->id, &ob->constraintChannels);
lib_link_nlastrips(reader, &ob->id, &ob->nlastrips);
- // >>> XXX deprecated - old animation system
+ /* >>> XXX deprecated - old animation system */
LISTBASE_FOREACH (PartEff *, paf, &ob->effect) {
if (paf->type == EFF_PARTICLE) {
@@ -3339,7 +3340,7 @@ static void lib_link_object(BlendLibReader *reader, Object *ob)
if (fluidmd && fluidmd->fss) {
BLO_read_id_address(
- reader, ob->id.lib, &fluidmd->fss->ipo); // XXX deprecated - old animation system
+ reader, ob->id.lib, &fluidmd->fss->ipo); /* XXX deprecated - old animation system */
}
}
@@ -3881,10 +3882,10 @@ static void direct_link_object(BlendDataReader *reader, Object *ob)
BLO_read_list(reader, &ob->defbase);
BLO_read_list(reader, &ob->fmaps);
- // XXX deprecated - old animation system <<<
+ /* XXX deprecated - old animation system <<< */
direct_link_nlastrips(reader, &ob->nlastrips);
BLO_read_list(reader, &ob->constraintChannels);
- // >>> XXX deprecated - old animation system
+ /* >>> XXX deprecated - old animation system */
BLO_read_pointer_array(reader, (void **)&ob->mat);
BLO_read_data_address(reader, &ob->matbits);
@@ -3951,7 +3952,7 @@ static void direct_link_object(BlendDataReader *reader, Object *ob)
if (ob->soft) {
SoftBody *sb = ob->soft;
- sb->bpoint = NULL; // init pointers so it gets rebuilt nicely
+ sb->bpoint = NULL; /* init pointers so it gets rebuilt nicely */
sb->bspring = NULL;
sb->scratch = NULL;
/* although not used anymore */
@@ -4448,7 +4449,7 @@ static void lib_link_scene(BlendLibReader *reader, Scene *sce)
if (seq->ipo) {
BLO_read_id_address(
- reader, sce->id.lib, &seq->ipo); // XXX deprecated - old animation system
+ reader, sce->id.lib, &seq->ipo); /* XXX deprecated - old animation system */
}
seq->scene_sound = NULL;
if (seq->scene) {
@@ -5139,7 +5140,7 @@ static void direct_link_area(BlendDataReader *reader, ScrArea *area)
}
}
/* we only saved what was used */
- space_outliner->storeflag |= SO_TREESTORE_CLEANUP; // at first draw
+ space_outliner->storeflag |= SO_TREESTORE_CLEANUP; /* at first draw */
}
space_outliner->treehash = NULL;
space_outliner->tree.first = space_outliner->tree.last = NULL;
@@ -6895,7 +6896,7 @@ static void link_global(FileData *fd, BlendFileData *bfd)
bfd->cur_view_layer = blo_read_get_new_globaldata_address(fd, bfd->cur_view_layer);
bfd->curscreen = newlibadr(fd, NULL, bfd->curscreen);
bfd->curscene = newlibadr(fd, NULL, bfd->curscene);
- // this happens in files older than 2.35
+ /* this happens in files older than 2.35 */
if (bfd->curscene == NULL) {
if (bfd->curscreen) {
bfd->curscene = bfd->curscreen->scene;
@@ -7197,7 +7198,7 @@ static BHead *read_userdef(BlendFileData *bfd, FileData *fd, BHead *bhead)
IDP_BlendDataRead(reader, &addon->prop);
}
- // XXX
+ /* XXX */
user->uifonts.first = user->uifonts.last = NULL;
BLO_read_list(reader, &user->uistyles);
@@ -7575,7 +7576,7 @@ static void expand_doit_library(void *fdhandle, Main *mainvar, void *old)
/* ID has not been read yet, add placeholder to the main of the
* library it belongs to, so that it will be read later. */
read_libblock(fd, libmain, bhead, LIB_TAG_INDIRECT, false, NULL);
- // commented because this can print way too much
+ /* commented because this can print way too much */
// if (G.debug & G_DEBUG) printf("expand_doit: other lib %s\n", lib->filepath);
/* for outliner dependency only */
@@ -7642,7 +7643,7 @@ static void expand_doit_library(void *fdhandle, Main *mainvar, void *old)
* and another append happens which invokes same ID...
* in that case the lookup table needs this entry */
oldnewmap_insert(fd->libmap, bhead->old, id, bhead->code);
- // commented because this can print way too much
+ /* commented because this can print way too much */
// if (G.debug & G_DEBUG) printf("expand: already read %s\n", id->name);
}
}
@@ -7660,7 +7661,7 @@ static void expand_ipo(BlendExpander *expander, Ipo *ipo)
}
}
-// XXX deprecated - old animation system
+/* XXX deprecated - old animation system */
static void expand_constraint_channels(BlendExpander *expander, ListBase *chanbase)
{
LISTBASE_FOREACH (bConstraintChannel *, chan, chanbase) {
@@ -7788,7 +7789,7 @@ static void expand_constraints(BlendExpander *expander, ListBase *lb)
/* deprecated manual expansion stuff */
LISTBASE_FOREACH (bConstraint *, curcon, lb) {
if (curcon->ipo) {
- BLO_expand(expander, curcon->ipo); // XXX deprecated - old animation system
+ BLO_expand(expander, curcon->ipo); /* XXX deprecated - old animation system */
}
}
}
@@ -7840,7 +7841,7 @@ static void expand_object(BlendExpander *expander, Object *ob)
BLO_expand(expander, ob->gpd);
- // XXX deprecated - old animation system (for version patching only)
+ /* XXX deprecated - old animation system (for version patching only) */
BLO_expand(expander, ob->ipo);
BLO_expand(expander, ob->action);
@@ -7851,7 +7852,7 @@ static void expand_object(BlendExpander *expander, Object *ob)
BLO_expand(expander, strip->act);
BLO_expand(expander, strip->ipo);
}
- // XXX deprecated - old animation system (for version patching only)
+ /* XXX deprecated - old animation system (for version patching only) */
for (int a = 0; a < ob->totcol; a++) {
BLO_expand(expander, ob->mat[a]);
@@ -8075,7 +8076,7 @@ void BLO_expand_main(void *fdhandle, Main *mainvar)
expand_collection(&expander, (Collection *)id);
break;
case ID_IP:
- expand_ipo(&expander, (Ipo *)id); // XXX deprecated - old animation system
+ expand_ipo(&expander, (Ipo *)id); /* XXX deprecated - old animation system */
break;
case ID_PA:
expand_particlesettings(&expander, (ParticleSettings *)id);
diff --git a/source/blender/blenloader/intern/versioning_250.c b/source/blender/blenloader/intern/versioning_250.c
index dad86f80813..b1a76c65ce9 100644
--- a/source/blender/blenloader/intern/versioning_250.c
+++ b/source/blender/blenloader/intern/versioning_250.c
@@ -23,7 +23,7 @@
#else
# include "BLI_winstuff.h"
# include "winsock2.h"
-# include <io.h> // for open close read
+# include <io.h> /* for open close read */
# include <zlib.h> /* odd include order-issue */
#endif
@@ -65,7 +65,7 @@
#include "BKE_anim_visualization.h"
#include "BKE_armature.h"
#include "BKE_colortools.h"
-#include "BKE_global.h" // for G
+#include "BKE_global.h" /* for G */
#include "BKE_lib_id.h"
#include "BKE_main.h"
#include "BKE_modifier.h"
@@ -113,7 +113,7 @@ static void area_add_header_region(ScrArea *area, ListBase *lb)
static void sequencer_init_preview_region(ARegion *region)
{
- // XXX a bit ugly still, copied from space_sequencer
+ /* XXX a bit ugly still, copied from space_sequencer */
/* NOTE: if you change values here, also change them in space_sequencer.c, sequencer_new */
region->regiontype = RGN_TYPE_PREVIEW;
region->alignment = RGN_ALIGN_TOP;
diff --git a/source/blender/blenloader/intern/versioning_260.c b/source/blender/blenloader/intern/versioning_260.c
index 3abac65a4df..d8a19bfa59e 100644
--- a/source/blender/blenloader/intern/versioning_260.c
+++ b/source/blender/blenloader/intern/versioning_260.c
@@ -54,15 +54,15 @@
#include "BKE_anim_visualization.h"
#include "BKE_image.h"
-#include "BKE_main.h" // for Main
-#include "BKE_mesh.h" // for ME_ defines (patching)
+#include "BKE_main.h" /* for Main */
+#include "BKE_mesh.h" /* for ME_ defines (patching) */
#include "BKE_modifier.h"
#include "BKE_particle.h"
#include "BKE_pointcache.h"
#include "BKE_scene.h"
#include "BKE_screen.h"
#include "BKE_sequencer.h"
-#include "BKE_text.h" // for txt_extended_ascii_as_utf8
+#include "BKE_text.h" /* for txt_extended_ascii_as_utf8 */
#include "BKE_texture.h"
#include "BKE_tracking.h"
@@ -70,7 +70,7 @@
# include "BKE_writeffmpeg.h"
#endif
-#include "IMB_imbuf.h" // for proxy / timecode versioning stuff
+#include "IMB_imbuf.h" /* for proxy / timecode versioning stuff */
#include "NOD_common.h"
#include "NOD_texture.h"
@@ -1343,7 +1343,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain)
if (bmain->versionfile < 263 || (bmain->versionfile == 263 && bmain->subversionfile < 10)) {
{
Scene *scene;
- // composite redesign
+ /* composite redesign */
for (scene = bmain->scenes.first; scene; scene = scene->id.next) {
if (scene->nodetree) {
if (scene->nodetree->chunksize == 0) {
@@ -1921,7 +1921,7 @@ void blo_do_versions_260(FileData *fd, Library *UNUSED(lib), Main *bmain)
}
}
- // add storage for compositor translate nodes when not existing
+ /* add storage for compositor translate nodes when not existing */
if (MAIN_VERSION_OLDER(bmain, 265, 11)) {
FOREACH_NODETREE_BEGIN (bmain, ntree, id) {
if (ntree->type == NTREE_COMPOSIT) {
diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c
index ec0ea79811c..dc945038933 100644
--- a/source/blender/blenloader/intern/versioning_280.c
+++ b/source/blender/blenloader/intern/versioning_280.c
@@ -978,7 +978,7 @@ static void do_version_curvemapping_walker(Main *bmain, void (*callback)(CurveMa
}
}
- // toolsettings
+ /* toolsettings */
ToolSettings *ts = scene->toolsettings;
if (ts->vpaint) {
callback(ts->vpaint->paint.cavity_curve);
@@ -2988,9 +2988,9 @@ void blo_do_versions_280(FileData *fd, Library *UNUSED(lib), Main *bmain)
/* gpencil grid settings */
for (bGPdata *gpd = bmain->gpencils.first; gpd; gpd = gpd->id.next) {
- ARRAY_SET_ITEMS(gpd->grid.color, 0.5f, 0.5f, 0.5f); // Color
- ARRAY_SET_ITEMS(gpd->grid.scale, 1.0f, 1.0f); // Scale
- gpd->grid.lines = GP_DEFAULT_GRID_LINES; // Number of lines
+ ARRAY_SET_ITEMS(gpd->grid.color, 0.5f, 0.5f, 0.5f); /* Color */
+ ARRAY_SET_ITEMS(gpd->grid.scale, 1.0f, 1.0f); /* Scale */
+ gpd->grid.lines = GP_DEFAULT_GRID_LINES; /* Number of lines */
}
}
diff --git a/source/blender/blenloader/intern/versioning_legacy.c b/source/blender/blenloader/intern/versioning_legacy.c
index 58d57f12b8f..b8d9b92a75d 100644
--- a/source/blender/blenloader/intern/versioning_legacy.c
+++ b/source/blender/blenloader/intern/versioning_legacy.c
@@ -24,11 +24,11 @@
#include <limits.h>
#ifndef WIN32
-# include <unistd.h> // for read close
+# include <unistd.h> /* for read close */
#else
# include "BLI_winstuff.h"
# include "winsock2.h"
-# include <io.h> // for open close read
+# include <io.h> /* for open close read */
# include <zlib.h> /* odd include order-issue */
#endif
@@ -72,8 +72,8 @@
#include "BKE_deform.h"
#include "BKE_fcurve.h"
#include "BKE_lattice.h"
-#include "BKE_main.h" // for Main
-#include "BKE_mesh.h" // for ME_ defines (patching)
+#include "BKE_main.h" /* for Main */
+#include "BKE_mesh.h" /* for ME_ defines (patching) */
#include "BKE_modifier.h"
#include "BKE_particle.h"
#include "BKE_pointcache.h"
@@ -886,7 +886,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
for (sce = bmain->scenes.first; sce; sce = sce->id.next) {
- sce->r.stereomode = 1; // no stereo
+ sce->r.stereomode = 1; /* no stereo */
}
/* some oldfile patch, moved from set_func_space */
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c
index 74a4ddfd8f3..a37ec2d9f0a 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -125,7 +125,7 @@
#include "BLI_bitmap.h"
#include "BLI_blenlib.h"
#include "BLI_mempool.h"
-#include "MEM_guardedalloc.h" // MEM_freeN
+#include "MEM_guardedalloc.h" /* MEM_freeN */
#include "BKE_action.h"
#include "BKE_anim_data.h"
@@ -140,7 +140,7 @@
#include "BKE_deform.h"
#include "BKE_fcurve.h"
#include "BKE_fcurve_driver.h"
-#include "BKE_global.h" // for G
+#include "BKE_global.h" /* for G */
#include "BKE_gpencil_modifier.h"
#include "BKE_icons.h"
#include "BKE_idprop.h"