diff options
author | Philipp Oeser <info@graphics-engineer.com> | 2020-03-19 14:47:06 +0300 |
---|---|---|
committer | Philipp Oeser <info@graphics-engineer.com> | 2020-03-19 17:18:09 +0300 |
commit | 9ace7e2439781457bed40994519a26cd22e63a78 (patch) | |
tree | fb5dfd583865499050a30e397516c3f35bdd27c8 /source/blender/gpu/intern/gpu_draw.c | |
parent | 42012493a8e183bef945a8fd88334e93541304ce (diff) |
Fix T74925: Texture Paint Stencil Mask crash
Use first texture if we dont have an ImageUser.
Maniphest Tasks: T74925
Differential Revision: https://developer.blender.org/D7181
Diffstat (limited to 'source/blender/gpu/intern/gpu_draw.c')
-rw-r--r-- | source/blender/gpu/intern/gpu_draw.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/gpu/intern/gpu_draw.c b/source/blender/gpu/intern/gpu_draw.c index 348b9dddba9..350c616e359 100644 --- a/source/blender/gpu/intern/gpu_draw.c +++ b/source/blender/gpu/intern/gpu_draw.c @@ -877,7 +877,7 @@ GPUTexture *GPU_texture_from_blender(Image *ima, ImageUser *iuser, ImBuf *ibuf, BKE_image_tag_time(ima); /* Test if we already have a texture. */ - GPUTexture **tex = gpu_get_image_gputexture(ima, textarget, iuser->multiview_eye); + GPUTexture **tex = gpu_get_image_gputexture(ima, textarget, iuser ? iuser->multiview_eye : 0); if (*tex) { return *tex; } |