Commit: ff716e3c34b8959c9dd2630888ef34999990647b
Author: Campbell Barton
Date:   Fri Mar 31 21:41:26 2017 +1100
Branches: custom-manipulators
https://developer.blender.org/rBff716e3c34b8959c9dd2630888ef34999990647b

Merge branch 'blender2.8' into custom-manipulators

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



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

diff --cc source/blender/blenloader/intern/writefile.c
index ff75185477d,f21003b66ac..d0756a78152
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@@ -1874,71 -1862,66 +1870,67 @@@ static void write_modifiers(WriteData *
        }
  }
  
- static void write_objects(WriteData *wd, ListBase *idbase)
+ static void write_object(WriteData *wd, Object *ob)
  {
-       for (Object *ob = idbase->first; ob; ob = ob->id.next) {
-               if (ob->id.us > 0 || wd->current) {
-                       /* write LibData */
-                       writestruct(wd, ID_OB, Object, 1, ob);
-                       write_iddata(wd, &ob->id);
+       if (ob->id.us > 0 || wd->current) {
+               /* write LibData */
+               writestruct(wd, ID_OB, Object, 1, ob);
+               write_iddata(wd, &ob->id);
  
-                       if (ob->adt) {
-                               write_animdata(wd, ob->adt);
-                       }
+               if (ob->adt) {
+                       write_animdata(wd, ob->adt);
+               }
  
-                       /* direct data */
-                       writedata(wd, DATA, sizeof(void *) * ob->totcol, 
ob->mat);
-                       writedata(wd, DATA, sizeof(char) * ob->totcol, 
ob->matbits);
-                       /* write_effects(wd, &ob->effect); */ /* not used 
anymore */
-                       write_properties(wd, &ob->prop);
-                       write_sensors(wd, &ob->sensors);
-                       write_controllers(wd, &ob->controllers);
-                       write_actuators(wd, &ob->actuators);
- 
-                       if (ob->type == OB_ARMATURE) {
-                               bArmature *arm = ob->data;
-                               if (arm && ob->pose && arm->act_bone) {
-                                       BLI_strncpy(ob->pose->proxy_act_bone, 
arm->act_bone->name, sizeof(ob->pose->proxy_act_bone));
-                               }
+               /* direct data */
+               writedata(wd, DATA, sizeof(void *) * ob->totcol, ob->mat);
+               writedata(wd, DATA, sizeof(char) * ob->totcol, ob->matbits);
+               /* write_effects(wd, &ob->effect); */ /* not used anymore */
+               write_properties(wd, &ob->prop);
+               write_sensors(wd, &ob->sensors);
+               write_controllers(wd, &ob->controllers);
+               write_actuators(wd, &ob->actuators);
+ 
+               if (ob->type == OB_ARMATURE) {
+                       bArmature *arm = ob->data;
+                       if (arm && ob->pose && arm->act_bone) {
+                               BLI_strncpy(ob->pose->proxy_act_bone, 
arm->act_bone->name, sizeof(ob->pose->proxy_act_bone));
                        }
+               }
  
-                       write_pose(wd, ob->pose);
-                       write_defgroups(wd, &ob->defbase);
-                       write_fmaps(wd, &ob->fmaps);
-                       write_constraints(wd, &ob->constraints);
-                       write_motionpath(wd, ob->mpath);
+               write_pose(wd, ob->pose);
+               write_defgroups(wd, &ob->defbase);
++              write_fmaps(wd, &ob->fmaps);
+               write_constraints(wd, &ob->constraints);
+               write_motionpath(wd, ob->mpath);
  
-                       writestruct(wd, DATA, PartDeflect, 1, ob->pd);
-                       writestruct(wd, DATA, SoftBody, 1, ob->soft);
-                       if (ob->soft) {
-                               write_pointcaches(wd, &ob->soft->ptcaches);
-                               writestruct(wd, DATA, EffectorWeights, 1, 
ob->soft->effector_weights);
-                       }
-                       writestruct(wd, DATA, BulletSoftBody, 1, ob->bsoft);
+               writestruct(wd, DATA, PartDeflect, 1, ob->pd);
+               writestruct(wd, DATA, SoftBody, 1, ob->soft);
+               if (ob->soft) {
+                       write_pointcaches(wd, &ob->soft->ptcaches);
+                       writestruct(wd, DATA, EffectorWeights, 1, 
ob->soft->effector_weights);
+               }
+               writestruct(wd, DATA, BulletSoftBody, 1, ob->bsoft);
  
-                       if (ob->rigidbody_object) {
-                               /* TODO: if any extra data is added to handle 
duplis, will need separate function then */
-                               writestruct(wd, DATA, RigidBodyOb, 1, 
ob->rigidbody_object);
-                       }
-                       if (ob->rigidbody_constraint) {
-                               writestruct(wd, DATA, RigidBodyCon, 1, 
ob->rigidbody_constraint);
-                       }
+               if (ob->rigidbody_object) {
+                       /* TODO: if any extra data is added to handle duplis, 
will need separate function then */
+                       writestruct(wd, DATA, RigidBodyOb, 1, 
ob->rigidbody_object);
+               }
+               if (ob->rigidbody_constraint) {
+                       writestruct(wd, DATA, RigidBodyCon, 1, 
ob->rigidbody_constraint);
+               }
  
-                       if (ob->type == OB_EMPTY && ob->empty_drawtype == 
OB_EMPTY_IMAGE) {
-                               writestruct(wd, DATA, ImageUser, 1, ob->iuser);
-                       }
+               if (ob->type == OB_EMPTY && ob->empty_drawtype == 
OB_EMPTY_IMAGE) {
+                       writestruct(wd, DATA, ImageUser, 1, ob->iuser);
+               }
  
-                       write_particlesystems(wd, &ob->particlesystem);
-                       write_modifiers(wd, &ob->modifiers);
+               write_particlesystems(wd, &ob->particlesystem);
+               write_modifiers(wd, &ob->modifiers);
  
-                       writelist(wd, DATA, LinkData, &ob->pc_ids);
-                       writelist(wd, DATA, LodLevel, &ob->lodlevels);
+               writelist(wd, DATA, LinkData, &ob->pc_ids);
+               writelist(wd, DATA, LodLevel, &ob->lodlevels);
  
-                       write_previews(wd, ob->preview);
-               }
+               write_previews(wd, ob->preview);
        }
- 
-       mywrite_flush(wd);
  }

_______________________________________________
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to