diff options
-rw-r--r-- | source/blender/blenkernel/BKE_blender.h | 3 | ||||
-rw-r--r-- | source/blender/blenloader/intern/readfile.c | 16 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_brush.c | 6 |
3 files changed, 20 insertions, 5 deletions
diff --git a/source/blender/blenkernel/BKE_blender.h b/source/blender/blenkernel/BKE_blender.h index a0c2908a646..84e24df43e5 100644 --- a/source/blender/blenkernel/BKE_blender.h +++ b/source/blender/blenkernel/BKE_blender.h @@ -42,8 +42,7 @@ extern "C" { * and keep comment above the defines. * Use STRINGIFY() rather than defining with quotes */ #define BLENDER_VERSION 268 -#define BLENDER_SUBVERSION 1 - +#define BLENDER_SUBVERSION 2 /* 262 was the last editmesh release but it has compatibility code for bmesh data */ #define BLENDER_MINVERSION 262 #define BLENDER_MINSUBVERSION 0 diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c index 1ed22a53251..0ff3392ad00 100644 --- a/source/blender/blenloader/intern/readfile.c +++ b/source/blender/blenloader/intern/readfile.c @@ -9495,6 +9495,22 @@ static void do_versions(FileData *fd, Library *lib, Main *main) brush->spacing = MAX2(1, brush->spacing); } } + + if (!MAIN_VERSION_ATLEAST(main, 268, 2)) { + Brush *brush; + #define BRUSH_FIXED (1 << 6) + for (brush = main->brush.first; brush; brush = brush->id.next) { + brush->flag &= ~BRUSH_FIXED; + + if(brush->cursor_overlay_alpha < 2) + brush->cursor_overlay_alpha = 33; + if(brush->texture_overlay_alpha < 2) + brush->texture_overlay_alpha = 33; + if(brush->mask_overlay_alpha <2) + brush->mask_overlay_alpha = 33; + } + #undef BRUSH_FIXED + } { bScreen *sc; diff --git a/source/blender/makesrna/intern/rna_brush.c b/source/blender/makesrna/intern/rna_brush.c index c1707048612..5d68a6905a3 100644 --- a/source/blender/makesrna/intern/rna_brush.c +++ b/source/blender/makesrna/intern/rna_brush.c @@ -1086,19 +1086,19 @@ static void rna_def_brush(BlenderRNA *brna) prop = RNA_def_property(srna, "texture_overlay_alpha", PROP_INT, PROP_PERCENTAGE); RNA_def_property_int_sdna(prop, NULL, "texture_overlay_alpha"); - RNA_def_property_range(prop, 1, 100); + RNA_def_property_range(prop, 0, 100); RNA_def_property_ui_text(prop, "Texture Overlay Alpha", ""); RNA_def_property_update(prop, 0, "rna_Brush_update"); prop = RNA_def_property(srna, "mask_overlay_alpha", PROP_INT, PROP_PERCENTAGE); RNA_def_property_int_sdna(prop, NULL, "mask_overlay_alpha"); - RNA_def_property_range(prop, 1, 100); + RNA_def_property_range(prop, 0, 100); RNA_def_property_ui_text(prop, "Mask Texture Overlay Alpha", ""); RNA_def_property_update(prop, 0, "rna_Brush_update"); prop = RNA_def_property(srna, "cursor_overlay_alpha", PROP_INT, PROP_PERCENTAGE); RNA_def_property_int_sdna(prop, NULL, "cursor_overlay_alpha"); - RNA_def_property_range(prop, 1, 100); + RNA_def_property_range(prop, 0, 100); RNA_def_property_ui_text(prop, "Mask Texture Overlay Alpha", ""); RNA_def_property_update(prop, 0, "rna_Brush_update"); |