[Bf-blender-cvs] [0a9d5c10067] greasepencil-object: GPencil: Patch Subdivision Simple option and fix buf in Tint patching

Antonio Vazquez noreply at git.blender.org
Sun Feb 23 13:11:50 CET 2020


Commit: 0a9d5c1006738ddc410d0909f55e9af18b0153c2
Author: Antonio Vazquez
Date:   Sun Feb 23 12:45:59 2020 +0100
Branches: greasepencil-object
https://developer.blender.org/rB0a9d5c1006738ddc410d0909f55e9af18b0153c2

GPencil: Patch Subdivision Simple option and fix buf in Tint patching

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

M	source/blender/blenloader/intern/versioning_280.c

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

diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c
index 136fc368bb3..c5bf3a1e20e 100644
--- a/source/blender/blenloader/intern/versioning_280.c
+++ b/source/blender/blenloader/intern/versioning_280.c
@@ -4477,11 +4477,20 @@ void blo_do_versions_280(FileData *fd, Library *UNUSED(lib), Main *bmain)
         LISTBASE_FOREACH (GpencilModifierData *, md, &ob->greasepencil_modifiers) {
           const GpencilModifierTypeInfo *mti = BKE_gpencil_modifierType_getInfo(md->type);
           switch (mti->type) {
-            case eGpencilModifierTypeType_Gpencil: {
+            case eGpencilModifierType_Tint: {
               TintGpencilModifierData *mmd = (TintGpencilModifierData *)md;
               srgb_to_linearrgb_v3_v3(mmd->rgb, mmd->rgb);
               break;
             }
+            case eGpencilModifierType_Subdiv: {
+              const short simple = (1 << 0);
+              SubdivGpencilModifierData *mmd = (SubdivGpencilModifierData *)md;
+              if (mmd->flag & simple) {
+                mmd->flag &= ~simple;
+                mmd->type = GP_SUBDIV_SIMPLE;
+              }
+              break;
+            }
             default:
               break;
           }



More information about the Bf-blender-cvs mailing list