diff --git a/source/blender/gpu/opengl/gl_state.cc b/source/blender/gpu/opengl/gl_state.cc index 3a474da8b8e..5483f889a8a 100644 --- a/source/blender/gpu/opengl/gl_state.cc +++ b/source/blender/gpu/opengl/gl_state.cc @@ -437,6 +437,13 @@ void GLStateManager::set_blend(const eGPUBlend value) } } + if (value == GPU_BLEND_SUBTRACT) { + glBlendEquation(GL_FUNC_REVERSE_SUBTRACT); + } + else { + glBlendEquation(GL_FUNC_ADD); + } + /* Always set the blend function. This avoid a rendering error when blending is disabled but * GPU_BLEND_CUSTOM was used just before and the frame-buffer is using more than 1 color target. */