diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2012-04-02 20:30:01 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2012-04-02 20:30:01 +0400 |
commit | 186d16e325cc16d0a108e1a82fb428792ee64536 (patch) | |
tree | 98b86177cf604fe1697a8c9708565a8408e73180 /source/blender/editors/sculpt_paint | |
parent | 095118d21e2d39dc82ee02730732c4b1d0b662b9 (diff) |
Fix #30769: cycles showing wrong image from active face in the uv editor,
with multiple material slots.
Diffstat (limited to 'source/blender/editors/sculpt_paint')
-rw-r--r-- | source/blender/editors/sculpt_paint/paint_image.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_image.c b/source/blender/editors/sculpt_paint/paint_image.c index 9cf8cc21996..5cea8d11c09 100644 --- a/source/blender/editors/sculpt_paint/paint_image.c +++ b/source/blender/editors/sculpt_paint/paint_image.c @@ -531,7 +531,7 @@ static Image *imapaint_face_image(const ImagePaintState *s, int face_index) if (scene_use_new_shading_nodes(s->scene)) { MFace *mf = &s->dm_mface[face_index]; - ED_object_get_active_image(s->ob, mf->mat_nr, &ima, NULL, NULL); + ED_object_get_active_image(s->ob, mf->mat_nr+1, &ima, NULL, NULL); } else { MTFace *tf = &s->dm_mtface[face_index]; @@ -547,7 +547,7 @@ static Image *project_paint_face_image(const ProjPaintState *ps, MTFace *dm_mtfa if (ps->do_new_shading_nodes) { /* cached scene_use_new_shading_nodes result */ MFace *mf = ps->dm_mface + face_index; - ED_object_get_active_image(ps->ob, mf->mat_nr, &ima, NULL, NULL); + ED_object_get_active_image(ps->ob, mf->mat_nr+1, &ima, NULL, NULL); } else { ima = dm_mtface[face_index].tpage; |