Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntonio Vazquez <blendergit@gmail.com>2020-05-15 17:43:50 +0300
committerAntonio Vazquez <blendergit@gmail.com>2020-05-15 17:50:38 +0300
commit1cad0a627e882cf0c5a98d1b482327e59f65a87a (patch)
tree99e951f7231e55125b0a2f3a1b28aacd7355148b /source/blender/blenkernel/BKE_brush.h
parenta269761ec1bce0f551cf7fc9c373f3c735df412c (diff)
GPencil: Fix unreported missing Sculpt/Vertex/Weight paint brushes
This error was introduced wit the change in commit https://developer.blender.org/rB6a850f3cc840 As the brushes were not created, all modes except Edit were broken. Now, the brushes and palette are not created when load the file in versioning code, but when the mode is enabled. Also, if the brush already exist, the parameters are not reset as it was done in the versioning code in order to keep user settings. The same logic is used for the default palette.
Diffstat (limited to 'source/blender/blenkernel/BKE_brush.h')
-rw-r--r--source/blender/blenkernel/BKE_brush.h16
1 files changed, 12 insertions, 4 deletions
diff --git a/source/blender/blenkernel/BKE_brush.h b/source/blender/blenkernel/BKE_brush.h
index a97263a6523..4e9430ab3e1 100644
--- a/source/blender/blenkernel/BKE_brush.h
+++ b/source/blender/blenkernel/BKE_brush.h
@@ -57,10 +57,18 @@ struct Brush *BKE_brush_copy(struct Main *bmain, const struct Brush *brush);
void BKE_brush_sculpt_reset(struct Brush *brush);
-void BKE_brush_gpencil_paint_presets(struct Main *bmain, struct ToolSettings *ts);
-void BKE_brush_gpencil_vertex_presets(struct Main *bmain, struct ToolSettings *ts);
-void BKE_brush_gpencil_sculpt_presets(struct Main *bmain, struct ToolSettings *ts);
-void BKE_brush_gpencil_weight_presets(struct Main *bmain, struct ToolSettings *ts);
+void BKE_brush_gpencil_paint_presets(struct Main *bmain,
+ struct ToolSettings *ts,
+ const bool reset);
+void BKE_brush_gpencil_vertex_presets(struct Main *bmain,
+ struct ToolSettings *ts,
+ const bool reset);
+void BKE_brush_gpencil_sculpt_presets(struct Main *bmain,
+ struct ToolSettings *ts,
+ const bool reset);
+void BKE_brush_gpencil_weight_presets(struct Main *bmain,
+ struct ToolSettings *ts,
+ const bool reset);
void BKE_gpencil_brush_preset_set(struct Main *bmain, struct Brush *brush, const short type);
/* image icon function */