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:
authorAntony Riakiotakis <kalast@gmail.com>2014-04-13 20:03:14 +0400
committerAntony Riakiotakis <kalast@gmail.com>2014-04-13 20:03:14 +0400
commit6f153046e0ffec912883ab24b9fda823e9fbeb38 (patch)
tree9a0d2705acdfe2a920eeaaeb0a0924cc9bf65e37 /source/blender/editors/sculpt_paint/paint_utils.c
parent5d79c2662e043c35feeb4a31f3c5eb288e93c9c1 (diff)
Reduce overhead when sampling texture images for brushes. The tests can
be cached and reused.
Diffstat (limited to 'source/blender/editors/sculpt_paint/paint_utils.c')
-rw-r--r--source/blender/editors/sculpt_paint/paint_utils.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_utils.c b/source/blender/editors/sculpt_paint/paint_utils.c
index 2eb397563e6..7316c58755c 100644
--- a/source/blender/editors/sculpt_paint/paint_utils.c
+++ b/source/blender/editors/sculpt_paint/paint_utils.c
@@ -179,7 +179,7 @@ float paint_get_tex_pixel(MTex *mtex, float u, float v, struct ImagePool *pool,
return intensity;
}
-void paint_get_tex_pixel_col(MTex *mtex, float u, float v, float rgba[4], struct ImagePool *pool, int thread, bool convert_to_linear, ImBuf *ibuf)
+void paint_get_tex_pixel_col(MTex *mtex, float u, float v, float rgba[4], struct ImagePool *pool, int thread, bool convert_to_linear, struct ColorSpace *colorspace)
{
float co[3] = {u, v, 0.0f};
int hasrgb;
@@ -195,7 +195,7 @@ void paint_get_tex_pixel_col(MTex *mtex, float u, float v, float rgba[4], struct
}
if (convert_to_linear)
- IMB_colormanagement_colorspace_to_scene_linear_v3(rgba, ibuf->rect_colorspace);
+ IMB_colormanagement_colorspace_to_scene_linear_v3(rgba, colorspace);
linearrgb_to_srgb_v3_v3(rgba, rgba);