[Bf-blender-cvs] [cfa43025707] soc-2019-openxr: Merge branch 'temp-openxr-ghostxr' into temp-openxr-blenderside

Julian Eisel noreply at git.blender.org
Tue Mar 10 18:23:55 CET 2020


Commit: cfa4302570715c10a38583dc1c2b736379c4ecad
Author: Julian Eisel
Date:   Tue Mar 10 18:23:32 2020 +0100
Branches: soc-2019-openxr
https://developer.blender.org/rBcfa4302570715c10a38583dc1c2b736379c4ecad

Merge branch 'temp-openxr-ghostxr' into temp-openxr-blenderside

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



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

diff --cc source/blender/blenloader/intern/versioning_280.c
index 7e824da1baa,b19ba351795..b885950c581
--- a/source/blender/blenloader/intern/versioning_280.c
+++ b/source/blender/blenloader/intern/versioning_280.c
@@@ -4534,17 -4797,57 +4799,81 @@@ void blo_do_versions_280(FileData *fd, 
        }
      }
  
 +    /* Keep this block, even when empty. */
 +    if (!DNA_struct_find(fd->filesdna, "bXrSessionSettings")) {
 +      for (wmWindowManager *wm = bmain->wm.first; wm; wm = wm->id.next) {
 +        const View3D *v3d_default = DNA_struct_default_get(View3D);
 +
 +        wm->xr.session_settings.shading_type = OB_SOLID;
 +        wm->xr.session_settings.draw_flags = (V3D_OFSDRAW_SHOW_GRIDFLOOR |
 +                                              V3D_OFSDRAW_SHOW_ANNOTATION);
 +        wm->xr.session_settings.clip_start = v3d_default->clip_start;
 +        wm->xr.session_settings.clip_end = v3d_default->clip_end;
 +      }
 +    }
++
+     /* Alembic Transform Cache changed from local to world space. */
+     LISTBASE_FOREACH (Object *, ob, &bmain->objects) {
+       LISTBASE_FOREACH (bConstraint *, con, &ob->constraints) {
+         if (con->type == CONSTRAINT_TYPE_TRANSFORM_CACHE) {
+           con->ownspace = CONSTRAINT_SPACE_WORLD;
+         }
+       }
+     }
+ 
+     /* Boundary Edges Automasking. */
+     if (!DNA_struct_elem_find(
+             fd->filesdna, "Brush", "int", "automasking_boundary_edges_propagation_steps")) {
+       for (Brush *br = bmain->brushes.first; br; br = br->id.next) {
+         br->automasking_boundary_edges_propagation_steps = 1;
+       }
+     }
+ 
+     /* Corrective smooth modifier scale*/
+     if (!DNA_struct_elem_find(fd->filesdna, "CorrectiveSmoothModifierData", "float", "scale")) {
+       for (Object *ob = bmain->objects.first; ob; ob = ob->id.next) {
+         for (ModifierData *md = ob->modifiers.first; md; md = md->next) {
+           if (md->type == eModifierType_CorrectiveSmooth) {
+             CorrectiveSmoothModifierData *csmd = (CorrectiveSmoothModifierData *)md;
+             csmd->scale = 1.0f;
+           }
+         }
+       }
+     }
+ 
+     /* Default Face Set Color. */
+     for (Mesh *me = bmain->meshes.first; me != NULL; me = me->id.next) {
+       if (me->totpoly > 0) {
+         int *face_sets = CustomData_get_layer(&me->pdata, CD_SCULPT_FACE_SETS);
+         if (face_sets) {
+           me->face_sets_color_default = abs(face_sets[0]);
+         }
+       }
+     }
+   }
+ 
+   /**
+    * Versioning code until next subversion bump goes here.
+    *
+    * \note Be sure to check when bumping the version:
+    * - #do_versions_after_linking_280 in this file.
+    * - "versioning_userdef.c", #BLO_version_defaults_userpref_blend
+    * - "versioning_userdef.c", #do_versions_theme
+    *
+    * \note Keep this message at the bottom of the function.
+    */
+   {
+     /* Keep this block, even when empty. */
++    if (!DNA_struct_find(fd->filesdna, "bXrSessionSettings")) {
++      for (wmWindowManager *wm = bmain->wm.first; wm; wm = wm->id.next) {
++        const View3D *v3d_default = DNA_struct_default_get(View3D);
++
++        wm->xr.session_settings.shading_type = OB_SOLID;
++        wm->xr.session_settings.draw_flags = (V3D_OFSDRAW_SHOW_GRIDFLOOR |
++                                              V3D_OFSDRAW_SHOW_ANNOTATION);
++        wm->xr.session_settings.clip_start = v3d_default->clip_start;
++        wm->xr.session_settings.clip_end = v3d_default->clip_end;
++      }
++    }
    }
  }



More information about the Bf-blender-cvs mailing list