diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2020-07-16 04:31:25 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2020-07-16 19:01:44 +0300 |
commit | 436d38bb548d904200337d58720552b6f78555cb (patch) | |
tree | 57cd4e5978a0c0a60e2559642cc39b224333d0a2 /source/blender/editors/util | |
parent | 3481f6eaf290b45025f66e5205530649502f351f (diff) |
Cleanup: GPU: Move XOR logic op to gpu_state.c
Diffstat (limited to 'source/blender/editors/util')
-rw-r--r-- | source/blender/editors/util/ed_util_imbuf.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/source/blender/editors/util/ed_util_imbuf.c b/source/blender/editors/util/ed_util_imbuf.c index 132a63a8249..3e85342e0d7 100644 --- a/source/blender/editors/util/ed_util_imbuf.c +++ b/source/blender/editors/util/ed_util_imbuf.c @@ -447,15 +447,16 @@ void ED_imbuf_sample_draw(const bContext *C, ARegion *region, void *arg_info) (float[2]){event->x - region->winrct.xmin, event->y - region->winrct.ymin}, (float)(info->sample_size / 2.0f) * sima->zoom); - glEnable(GL_COLOR_LOGIC_OP); - glLogicOp(GL_XOR); + GPU_logic_op_xor_set(true); + GPU_line_width(1.0f); imm_draw_box_wire_2d(pos, (float)sample_rect_fl.xmin, (float)sample_rect_fl.ymin, (float)sample_rect_fl.xmax, (float)sample_rect_fl.ymax); - glDisable(GL_COLOR_LOGIC_OP); + + GPU_logic_op_xor_set(false); immUnbindProgram(); } |