[gtk+/wip/otte/shader: 21/71] xxx: Change the clip shader do not use #f
- From: Benjamin Otte <otte src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/wip/otte/shader: 21/71] xxx: Change the clip shader do not use #f
- Date: Thu, 12 Oct 2017 23:40:33 +0000 (UTC)
commit a3ca7f00c182d16da94a85cc1a0e63fc60eb71a5
Author: Benjamin Otte <otte redhat com>
Date: Mon Oct 2 16:59:32 2017 +0200
xxx: Change the clip shader do not use #f
Use #ifdef instead.
gsk/resources/vulkan/clip.frag.glsl | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
---
diff --git a/gsk/resources/vulkan/clip.frag.glsl b/gsk/resources/vulkan/clip.frag.glsl
index 472dc6f..1717e99 100644
--- a/gsk/resources/vulkan/clip.frag.glsl
+++ b/gsk/resources/vulkan/clip.frag.glsl
@@ -11,13 +11,17 @@ vec4 clip(vec2 pos, vec4 color)
return color * rounded_rect_coverage (r, pos);
}
-#elif defined(CLIP_RECT)
+#else
+#ifdef CLIP_RECT
+//#elif defined(CLIP_RECT)
vec4 clip(vec2 pos, vec4 color)
{
/* clipped in vertex shader already */
return color;
}
-#elif defined(CLIP_NONE)
+#else
+#ifdef CLIP_NONE
+//#elif defined(CLIP_NONE)
vec4 clip(vec2 pos, vec4 color)
{
return color;
@@ -25,5 +29,7 @@ vec4 clip(vec2 pos, vec4 color)
#else
#error "No clipping define given. Need CLIP_NONE, CLIP_RECT or CLIP_ROUNDED_RECT"
#endif
+#endif
+#endif
#endif
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]