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:
authorBastien Montagne <montagne29@wanadoo.fr>2018-06-25 13:50:32 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2018-06-25 13:50:32 +0300
commite97237892c804a0ea82fe430cf0e1f4d16039dc4 (patch)
treeaea045588506e38ff44a6e04d37a02094a7fddeb /source/blender/editors/sculpt_paint/paint_image.c
parentcdee53edfc4d249ce198965a35cefe32a813854d (diff)
parent8a7f317666caa41aad0428b5ed3f399cdfbbd816 (diff)
Merge branch 'master' into blender2.8
Conflicts: source/blender/editors/sculpt_paint/paint_image.c source/blender/editors/space_view3d/view3d_draw.c source/blender/editors/space_view3d/view3d_view.c source/blender/gpu/GPU_draw.h source/blender/gpu/GPU_material.h source/blender/gpu/intern/gpu_draw.c source/blender/gpu/intern/gpu_material.c source/blender/makesrna/intern/rna_userdef.c source/blender/windowmanager/intern/wm_files_link.c source/blender/windowmanager/intern/wm_init_exit.c source/creator/creator_args.c source/gameengine/GamePlayer/ghost/GPG_ghost.cpp source/gameengine/Ketsji/KX_PythonInit.cpp source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_OpenGLRasterizer.cpp
Diffstat (limited to 'source/blender/editors/sculpt_paint/paint_image.c')
-rw-r--r--source/blender/editors/sculpt_paint/paint_image.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_image.c b/source/blender/editors/sculpt_paint/paint_image.c
index cdb7a3bcce6..4342778a5d1 100644
--- a/source/blender/editors/sculpt_paint/paint_image.c
+++ b/source/blender/editors/sculpt_paint/paint_image.c
@@ -1054,6 +1054,7 @@ static int texture_paint_toggle_poll(bContext *C)
static int texture_paint_toggle_exec(bContext *C, wmOperator *op)
{
struct wmMsgBus *mbus = CTX_wm_message_bus(C);
+ Main *bmain = CTX_data_main(C);
Scene *scene = CTX_data_scene(C);
Object *ob = CTX_data_active_object(C);
const int mode_flag = OB_MODE_TEXTURE_PAINT;
@@ -1069,14 +1070,13 @@ static int texture_paint_toggle_exec(bContext *C, wmOperator *op)
ob->mode &= ~mode_flag;
if (U.glreslimit != 0)
- GPU_free_images();
- GPU_paint_set_mipmap(1);
+ GPU_free_images(bmain);
+ GPU_paint_set_mipmap(bmain, 1);
toggle_paint_cursor(C, 0);
}
else {
bScreen *sc;
- Main *bmain = CTX_data_main(C);
Image *ima = NULL;
ImagePaintSettings *imapaint = &scene->toolsettings->imapaint;
@@ -1121,8 +1121,8 @@ static int texture_paint_toggle_exec(bContext *C, wmOperator *op)
BKE_paint_init(bmain, scene, ePaintTextureProjective, PAINT_CURSOR_TEXTURE_PAINT);
if (U.glreslimit != 0)
- GPU_free_images();
- GPU_paint_set_mipmap(0);
+ GPU_free_images(bmain);
+ GPU_paint_set_mipmap(bmain, 0);
toggle_paint_cursor(C, 1);
}