summaryrefslogtreecommitdiff
path: root/glamor/glamor_core.c
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2016-02-01 13:58:07 -0800
committerAdam Jackson <ajax@redhat.com>2016-03-10 11:12:42 -0500
commitc7574c63c618d3a017105c380542eb04341b04a2 (patch)
treeaf5fde1f07d5867da572ce2c84754da76c616ca6 /glamor/glamor_core.c
parent1bed5ef2b80c77c1bb9b62971367bea864fd8f66 (diff)
glamor: Propagate that is_upload is always true.
Reviewed-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Eric Anholt <eric@anholt.net>
Diffstat (limited to 'glamor/glamor_core.c')
-rw-r--r--glamor/glamor_core.c18
1 files changed, 4 insertions, 14 deletions
diff --git a/glamor/glamor_core.c b/glamor/glamor_core.c
index b9948b569..a8768f4e8 100644
--- a/glamor/glamor_core.c
+++ b/glamor/glamor_core.c
@@ -164,8 +164,6 @@ glamor_init_finish_access_shaders(ScreenPtr screen)
"uniform int swap_rb;\n"
"#define REVERT_NONE 0\n"
"#define REVERT_NORMAL 1\n"
- "#define SWAP_NONE_DOWNLOADING 0\n"
- "#define SWAP_DOWNLOADING 1\n"
"#define SWAP_UPLOADING 2\n"
"#define SWAP_NONE_UPLOADING 3\n";
@@ -175,18 +173,14 @@ glamor_init_finish_access_shaders(ScreenPtr screen)
" vec4 color = texture2D(sampler, source_texture);\n"
" if (revert == REVERT_NONE) \n"
" { \n"
- " if ((swap_rb != SWAP_NONE_DOWNLOADING) && (swap_rb != SWAP_NONE_UPLOADING)) \n"
+ " if ((swap_rb != SWAP_NONE_UPLOADING)) \n"
" gl_FragColor = color.bgra;\n"
" else \n"
" gl_FragColor = color.rgba;\n"
" } \n"
" else \n"
" { \n"
- " if (swap_rb == SWAP_DOWNLOADING) \n"
- " gl_FragColor = color.argb;\n"
- " else if (swap_rb == SWAP_NONE_DOWNLOADING)\n"
- " gl_FragColor = color.abgr;\n"
- " else if (swap_rb == SWAP_UPLOADING)\n"
+ " if (swap_rb == SWAP_UPLOADING)\n"
" gl_FragColor = color.gbar;\n"
" else if (swap_rb == SWAP_NONE_UPLOADING)\n"
" gl_FragColor = color.abgr;\n"
@@ -199,18 +193,14 @@ glamor_init_finish_access_shaders(ScreenPtr screen)
" vec4 color = texture2D(sampler, source_texture);\n"
" if (revert == REVERT_NONE) \n"
" { \n"
- " if ((swap_rb != SWAP_NONE_DOWNLOADING) && (swap_rb != SWAP_NONE_UPLOADING)) \n"
+ " if (swap_rb != SWAP_NONE_UPLOADING) \n"
" gl_FragColor = vec4(color.bgr, 1);\n"
" else \n"
" gl_FragColor = vec4(color.rgb, 1);\n"
" } \n"
" else \n"
" { \n"
- " if (swap_rb == SWAP_DOWNLOADING) \n"
- " gl_FragColor = vec4(1, color.rgb);\n"
- " else if (swap_rb == SWAP_NONE_DOWNLOADING)\n"
- " gl_FragColor = vec4(1, color.bgr);\n"
- " else if (swap_rb == SWAP_UPLOADING)\n"
+ " if (swap_rb == SWAP_UPLOADING)\n"
" gl_FragColor = vec4(color.gba, 1);\n"
" else if (swap_rb == SWAP_NONE_UPLOADING)\n"
" gl_FragColor = vec4(color.abg, 1);\n"