From f8d384fa8f0fa2a3ac04c4ad21fb04400490e8e6 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Fri, 27 Dec 2013 02:13:27 -0800 Subject: [PATCH] glamor: Move shader precision stuff from build time to shader compile time. This is the last desktop-versus-ES2 build ifdef in core glamor. Signed-off-by: Eric Anholt Reviewed-by: Keith Packard Reviewed-by: Adam Jackson --- glamor/glamor_priv.h | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/glamor/glamor_priv.h b/glamor/glamor_priv.h index 81b46b6e9..e28a02158 100644 --- a/glamor/glamor_priv.h +++ b/glamor/glamor_priv.h @@ -37,11 +37,10 @@ #include -#ifdef GLAMOR_GLES2 -#define GLAMOR_DEFAULT_PRECISION "precision mediump float;\n" -#else -#define GLAMOR_DEFAULT_PRECISION -#endif +#define GLAMOR_DEFAULT_PRECISION \ + "#ifdef GL_ES\n" \ + "precision mediump float;\n" \ + "#endif\n" #ifdef RENDER #include "glyphstr.h"