[Bf-blender-cvs] [01c5335422a] master: Cleanup: Comments

Sergey Sharybin noreply at git.blender.org
Mon Mar 18 15:55:01 CET 2019


Commit: 01c5335422a741b6847f082dad14389d3cb62201
Author: Sergey Sharybin
Date:   Mon Mar 18 12:51:01 2019 +0100
Branches: master
https://developer.blender.org/rB01c5335422a741b6847f082dad14389d3cb62201

Cleanup: Comments

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

M	source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc

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

diff --git a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
index c545099c97b..c161d32a1f0 100644
--- a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
@@ -26,8 +26,7 @@
  * material) to be handled in same way as "real" datablocks, even tho some
  * internal BKE routines doesn't treat them like that.
  *
- * TODO(sergey): Re-evaluate that after new ID handling is in place.
- */
+ * TODO(sergey): Re-evaluate that after new ID handling is in place. */
 #define NESTED_ID_NASTY_WORKAROUND
 
 /* Silence warnings from copying deprecated fields. */
@@ -162,8 +161,7 @@ void nested_id_hack_discard_pointers(ID *id_cow)
 
 /* Set ID pointer of nested owned IDs (nodetree, key) to NULL.
  *
- * Return pointer to a new ID to be used.
- */
+ * Return pointer to a new ID to be used. */
 const ID *nested_id_hack_get_discarded_pointers(NestedIDHackTempStorage *storage,
                                                 const ID *id)
 {
@@ -278,8 +276,7 @@ struct ValidateData {
 };
 
 /* Similar to generic BKE_id_copy() but does not require main and assumes pointer
- * is already allocated,
- */
+ * is already allocated. */
 bool id_copy_inplace_no_main(const ID *id, ID *newid)
 {
 	const ID *id_for_copy = id;
@@ -305,8 +302,7 @@ bool id_copy_inplace_no_main(const ID *id, ID *newid)
 }
 
 /* Similar to BKE_scene_copy() but does not require main and assumes pointer
- * is already allocated.
- */
+ * is already allocated. */
 bool scene_copy_inplace_no_main(const Scene *scene, Scene *new_scene)
 {
 	const ID *id_for_copy = &scene->id;
@@ -461,8 +457,7 @@ BLI_INLINE bool check_datablock_expanded(const ID *id_cow)
  * does not need any remapping or anything.
  *
  * TODO(sergey): How to make it more robust for the future, so we don't have
- * to maintain exception lists all over the code?
- */
+ * to maintain exception lists all over the code? */
 bool check_datablocks_copy_on_writable(const ID *id_orig)
 {
 	const ID_Type id_type = GS(id_orig->name);
@@ -476,8 +471,7 @@ bool check_datablocks_copy_on_writable(const ID *id_orig)
 }
 
 /* Callback for BKE_library_foreach_ID_link which remaps original ID pointer
- * with the one created by CoW system.
- */
+ * with the one created by CoW system. */
 
 struct RemapCallbackUserData {
 	/* Dependency graph for which remapping is happening. */
@@ -592,8 +586,7 @@ void update_mesh_edit_mode_pointers(const Depsgraph *depsgraph,
 }
 
 /* Edit data is stored and owned by original datablocks, copied ones
- * are simply referencing to them.
- */
+ * are simply referencing to them. */
 void update_edit_mode_pointers(const Depsgraph *depsgraph,
                                const ID *id_orig, ID *id_cow)
 {
@@ -659,8 +652,7 @@ void update_pose_orig_pointers(const bPose *pose_orig, bPose *pose_cow)
 /* Do some special treatment of data transfer from original ID to it's
  * CoW complementary part.
  *
- * Only use for the newly created CoW datablocks.
- */
+ * Only use for the newly created CoW datablocks. */
 void update_id_after_copy(const Depsgraph *depsgraph,
                           const IDNode *id_node,
                           const ID *id_orig, ID *id_cow)
@@ -709,8 +701,7 @@ void update_id_after_copy(const Depsgraph *depsgraph,
 }
 
 /* This callback is used to validate that all nested ID datablocks are
- * properly expanded.
- */
+ * properly expanded. */
 int foreach_libblock_validate_callback(void *user_data,
                                        ID * /*id_self*/,
                                        ID **id_p,
@@ -731,8 +722,7 @@ int foreach_libblock_validate_callback(void *user_data,
 /* Actual implementation of logic which "expands" all the data which was not
  * yet copied-on-write.
  *
- * NOTE: Expects that CoW datablock is empty.
- */
+ * NOTE: Expects that CoW datablock is empty. */
 ID *deg_expand_copy_on_write_datablock(const Depsgraph *depsgraph,
                                        const IDNode *id_node,
                                        DepsgraphNodeBuilder *node_builder,
@@ -846,8 +836,7 @@ struct ObjectRuntimeBackup {
 
 /* Make a backup of object's evaluation runtime data, additionally
  * make object to be safe for free without invalidating backed up
- * pointers.
- */
+ * pointers. */
 static void deg_backup_object_runtime(
         Object *object,
         ObjectRuntimeBackup *object_runtime_backup)
@@ -1014,8 +1003,7 @@ void discard_scene_pointers(ID *id_cow)
 }
 
 /* NULL-ify all edit mode pointers which points to data from
- * original object.
- */
+ * original object. */
 void discard_edit_mode_pointers(ID *id_cow)
 {
 	const ID_Type type = GS(id_cow->name);
@@ -1050,8 +1038,7 @@ void discard_edit_mode_pointers(ID *id_cow)
 /* Free content of the CoW datablock
  * Notes:
  * - Does not recurs into nested ID datablocks.
- * - Does not free datablock itself.
- */
+ * - Does not free datablock itself. */
 void deg_free_copy_on_write_datablock(ID *id_cow)
 {
 	if (!check_datablock_expanded(id_cow)) {



More information about the Bf-blender-cvs mailing list