summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandroid-build-team Robot <android-build-team-robot@google.com>2018-11-22 03:28:06 +0000
committerandroid-build-team Robot <android-build-team-robot@google.com>2018-11-22 03:28:06 +0000
commit286a83b7cd5bf70a12384820955a366399845903 (patch)
treeaf9ccdf32653250541fd8fdfc37c4bd745835a1a
parentb277b42215f2d9af666d6c6a7e04019b678f7cd8 (diff)
parent39fa5cf241465ce4587a551735b5cccea2c98144 (diff)
downloadnative-286a83b7cd5bf70a12384820955a366399845903.tar.gz
Merge cherrypicks of [5585450, 5587462, 5586398, 5586660, 5587382, 5586512, 5586485] into pi-b4s4-release
Change-Id: I1d0502bb04513702e3a76a8527b4fc23c74062eb
-rw-r--r--services/surfaceflinger/RenderEngine/ProgramCache.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/services/surfaceflinger/RenderEngine/ProgramCache.cpp b/services/surfaceflinger/RenderEngine/ProgramCache.cpp
index 9dc6858566..338d27c2e4 100644
--- a/services/surfaceflinger/RenderEngine/ProgramCache.cpp
+++ b/services/surfaceflinger/RenderEngine/ProgramCache.cpp
@@ -611,7 +611,7 @@ String8 ProgramCache::generateFragmentShader(const Key& needs) {
fs << "void main(void) {" << indent;
if (needs.isTexturing()) {
- fs << "gl_FragColor = texture2D(sampler, outTexCoords);";
+ fs << "gl_FragColor = clamp(texture2D(sampler, outTexCoords), 0.0, 1.0);";
if (needs.isY410BT2020()) {
fs << "gl_FragColor.rgb = convertY410BT2020(gl_FragColor.rgb);";
}