diff options
author | Antonio Vazquez <blendergit@gmail.com> | 2019-08-30 15:19:07 +0300 |
---|---|---|
committer | Antonio Vazquez <blendergit@gmail.com> | 2019-08-30 15:26:39 +0300 |
commit | d5d3dc418912863b172ef9f79f9991bb9d46bea8 (patch) | |
tree | d3aeb45c89025a1c5c0cabdf6ca4d3746115b848 /source/blender/editors/gpencil/gpencil_utils.c | |
parent | 4608220c9b3c0adfdab3cd6994d29c0ced748794 (diff) |
GPencil: Use default material when slot material is empty
When a material slot is empty, the default material is used.
The default color used is Gray to get a good contrast in dense scenes with dark and white background.
Reviewers: brecht, dfelinto, mendio, pepeland
Differential Revision: https://developer.blender.org/D5625
Diffstat (limited to 'source/blender/editors/gpencil/gpencil_utils.c')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_utils.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/gpencil/gpencil_utils.c b/source/blender/editors/gpencil/gpencil_utils.c index 25b4036b8b1..d7492b5be4d 100644 --- a/source/blender/editors/gpencil/gpencil_utils.c +++ b/source/blender/editors/gpencil/gpencil_utils.c @@ -2064,7 +2064,7 @@ void ED_gpencil_update_color_uv(Main *bmain, Material *mat) if (ED_gpencil_stroke_color_use(ob, gpl, gps) == false) { continue; } - gps_ma = give_current_material(ob, gps->mat_nr + 1); + gps_ma = BKE_material_gpencil_get(ob, gps->mat_nr + 1); /* update */ if ((gps_ma) && (gps_ma == mat)) { ED_gpencil_calc_stroke_uv(ob, gps); |