diff --git a/client/renderers/EGL/shader/desktop_rgb.frag b/client/renderers/EGL/shader/desktop_rgb.frag index 59128b8b..2fba4a91 100644 --- a/client/renderers/EGL/shader/desktop_rgb.frag +++ b/client/renderers/EGL/shader/desktop_rgb.frag @@ -84,4 +84,6 @@ void main() color *= 1.0 + lumi; color *= nvGain; } + + color.a = 1.0; } diff --git a/client/renderers/EGL/shader/splash_bg.frag b/client/renderers/EGL/shader/splash_bg.frag index 058afdbe..cff04f20 100644 --- a/client/renderers/EGL/shader/splash_bg.frag +++ b/client/renderers/EGL/shader/splash_bg.frag @@ -1,7 +1,6 @@ #version 300 es in highp vec3 pos; -in highp float a; out highp vec4 color; uniform sampler2D sampler1; @@ -9,5 +8,5 @@ uniform sampler2D sampler1; void main() { highp float d = 1.0 - sqrt(pos.x * pos.x + pos.y * pos.y) / 2.0; - color = vec4(0.234375 * d, 0.015625f * d, 0.425781f * d, a); + color = vec4(0.234375 * d, 0.015625f * d, 0.425781f * d, 1); } diff --git a/client/renderers/EGL/shader/splash_bg.vert b/client/renderers/EGL/shader/splash_bg.vert index d47bc73c..c863e2ed 100644 --- a/client/renderers/EGL/shader/splash_bg.vert +++ b/client/renderers/EGL/shader/splash_bg.vert @@ -2,8 +2,6 @@ layout(location = 0) in vec3 vertexPosition_modelspace; -uniform float alpha; - out highp vec3 pos; out highp float a; @@ -13,5 +11,4 @@ void main() gl_Position.w = 1.0; pos = vertexPosition_modelspace; - a = alpha; } diff --git a/client/renderers/EGL/shader/splash_logo.frag b/client/renderers/EGL/shader/splash_logo.frag index bd09551c..4c7840b6 100644 --- a/client/renderers/EGL/shader/splash_logo.frag +++ b/client/renderers/EGL/shader/splash_logo.frag @@ -1,11 +1,10 @@ #version 300 es out highp vec4 color; -in highp float a; uniform sampler2D sampler1; void main() { - color = vec4(1.0, 1.0, 1.0, a); + color = vec4(1.0, 1.0, 1.0, 1.0); } diff --git a/client/renderers/EGL/shader/splash_logo.vert b/client/renderers/EGL/shader/splash_logo.vert index a717f3a1..a4125b7d 100644 --- a/client/renderers/EGL/shader/splash_logo.vert +++ b/client/renderers/EGL/shader/splash_logo.vert @@ -2,15 +2,11 @@ layout(location = 0) in vec3 vertexPosition_modelspace; -uniform vec2 scale; - -out highp float a; +uniform float scale; void main() { gl_Position.xyz = vertexPosition_modelspace; - gl_Position.y *= scale.y; + gl_Position.y *= scale; gl_Position.w = 1.0; - - a = scale.x; } diff --git a/client/renderers/EGL/splash.c b/client/renderers/EGL/splash.c index eeb81c84..9fe9663c 100644 --- a/client/renderers/EGL/splash.c +++ b/client/renderers/EGL/splash.c @@ -45,7 +45,6 @@ struct EGL_Splash EGL_Model * logo; // uniforms - GLint uBGAlpha; GLint uScale; }; @@ -74,8 +73,6 @@ bool egl_splash_init(EGL_Splash ** splash) return false; } - (*splash)->uBGAlpha = egl_shader_get_uniform_location((*splash)->bgShader, "alpha"); - if (!egl_model_init(&(*splash)->bg)) { DEBUG_ERROR("Failed to intiailize the splash bg model"); @@ -166,14 +163,14 @@ void egl_splash_free(EGL_Splash ** splash) void egl_splash_render(EGL_Splash * splash, float alpha, float scaleY) { glEnable(GL_BLEND); - glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); + glBlendColor(0, 0, 0, alpha); + glBlendFunc(GL_CONSTANT_ALPHA, GL_ONE_MINUS_CONSTANT_ALPHA); egl_shader_use(splash->bgShader); - glUniform1f(splash->uBGAlpha, alpha); egl_model_render(splash->bg); egl_shader_use(splash->logoShader); - glUniform2f(splash->uScale, alpha, scaleY); + glUniform1f(splash->uScale, scaleY); egl_model_render(splash->logo); glDisable(GL_BLEND);