• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

frameworks/base


Commit MetaInfo

Revision927459c53af3063ea49f5af6af96a334c25cc11e (tree)
Time2015-12-22 13:13:53
AuthorPaulo Sergio Travaglia <pstglia@gmai...>
CommiterChih-Wei Huang

Log Message

Avoid crashes with Suspendon Lollipop (ColorFade)

ColorFade (which is called on Suspend during STATE_OFF)
uses some GLSL commands to make some effects ( fade current screen
to black and white before blacking it out completelly)

However, it produces a crash on mesa. To avoid this crash,
Fragment Shader code was commented out, keeping just
gl_FragColor to set a single black color

Change Summary

Incremental Difference

--- a/core/res/res/raw/color_fade_frag.frag
+++ b/core/res/res/raw/color_fade_frag.frag
@@ -7,6 +7,7 @@ uniform float saturation;
77 uniform float gamma;
88 varying vec2 UV;
99
10+/*
1011 vec3 rgb2hsl(vec3 rgb)
1112 {
1213 float e = 1.0e-7;
@@ -32,11 +33,14 @@ vec3 hsl2rgb(vec3 hsl)
3233 float c = (1.0 - abs(2.0 * hsl.z - 1.0)) * hsl.y;
3334 return (rgb - vec3(0.5)) * c + hsl.z;
3435 }
36+*/
3537
3638 void main()
3739 {
40+/*
3841 vec4 color = texture2D(texUnit, UV);
3942 vec3 hsl = rgb2hsl(color.xyz);
4043 vec3 rgb = pow(hsl2rgb(vec3(hsl.x, hsl.y * saturation, hsl.z * opacity)), vec3(gamma));
41- gl_FragColor = vec4(rgb, 1.0);
44+*/
45+ gl_FragColor = vec4(0.0, 0.0, 0.0, 1.0);
4246 }