fix stroke shader with better blending and initial support to opacity
This commit is contained in:
@@ -1872,7 +1872,7 @@ public:
|
||||
glGetIntegerv(GL_VIEWPORT, vp);
|
||||
glGetFloatv(GL_COLOR_CLEAR_VALUE, cc);
|
||||
|
||||
glClearColor(0, 0, 0, 1);
|
||||
glClearColor(1, 1, 1, 1);
|
||||
glClear(GL_COLOR_BUFFER_BIT);
|
||||
float zoom = root()->m_zoom;
|
||||
auto box = m_clip * zoom;
|
||||
@@ -1901,6 +1901,10 @@ public:
|
||||
if (m_canvas->m_show_tmp)
|
||||
{
|
||||
glEnable(GL_BLEND);
|
||||
ui::ShaderManager::use(kShader::TextureAlpha);
|
||||
ui::ShaderManager::u_int(kShaderUniform::Tex, 0);
|
||||
ui::ShaderManager::u_mat4(kShaderUniform::MVP, mvp);
|
||||
ui::ShaderManager::u_float(kShaderUniform::Alpha, .5);
|
||||
m_canvas->m_tmp.bindTexture();
|
||||
NodeBorder::m_plane.draw_fill();
|
||||
m_canvas->m_tmp.unbindTexture();
|
||||
|
||||
Reference in New Issue
Block a user