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:
authorClément Foucault <foucault.clem@gmail.com>2020-02-11 16:57:41 +0300
committerClément Foucault <foucault.clem@gmail.com>2020-02-11 16:57:41 +0300
commit30f65b54a78edc2a974ba93fefa86534fe2b7ff4 (patch)
tree030cf43b7c2cbd649a2e8758bf319a5b76a29aef /source/blender/editors/sculpt_paint/paint_image_2d.c
parent9052c6fafa87654c9a45ce0d5b9ecee073ec1a5b (diff)
parent3657bb514130ce2d28c407432d6f10202a68c92a (diff)
Merge branch 'master' into draw-colormanagementdraw-colormanagement
Diffstat (limited to 'source/blender/editors/sculpt_paint/paint_image_2d.c')
-rw-r--r--source/blender/editors/sculpt_paint/paint_image_2d.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_image_2d.c b/source/blender/editors/sculpt_paint/paint_image_2d.c
index 7f71110b360..a667c7062e6 100644
--- a/source/blender/editors/sculpt_paint/paint_image_2d.c
+++ b/source/blender/editors/sculpt_paint/paint_image_2d.c
@@ -1646,7 +1646,7 @@ void paint_2d_stroke(void *ps,
continue;
}
- ImBuf *ibuf = BKE_image_acquire_ibuf(s->image, &tile->iuser, NULL);
+ ImBuf *ibuf = tile->canvas;
/* OCIO_TODO: float buffers are now always linear, so always use color correction
* this should probably be changed when texture painting color space is supported
@@ -1711,6 +1711,7 @@ void *paint_2d_new_stroke(bContext *C, wmOperator *op, int mode)
}
if (ibuf->channels != 4) {
+ BKE_image_release_ibuf(s->image, ibuf, NULL);
BKE_report(op->reports, RPT_WARNING, "Image requires 4 color channels to paint");
MEM_freeN(s->tiles);
MEM_freeN(s);