diff options
author | Brian Paul <[email protected]> | 2011-11-03 19:56:51 -0600 |
---|---|---|
committer | Brian Paul <[email protected]> | 2011-11-07 14:25:47 -0700 |
commit | af734468fee1e1fc0714557ddd199e2f91940afc (patch) | |
tree | 049bab94f731edd6f0f7d8c40a009dbd4fd8628f /src/mesa/state_tracker/st_program.c | |
parent | 0d05422c2001b5d0d50ea4f0d99a5cc1c301fccb (diff) |
st/mesa: clean-up st_translate_interp()
Diffstat (limited to 'src/mesa/state_tracker/st_program.c')
-rw-r--r-- | src/mesa/state_tracker/st_program.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/mesa/state_tracker/st_program.c b/src/mesa/state_tracker/st_program.c index 146e77f9dbb..6c1568dcfa9 100644 --- a/src/mesa/state_tracker/st_program.c +++ b/src/mesa/state_tracker/st_program.c @@ -416,7 +416,9 @@ st_get_vp_variant(struct st_context *st, return vpv; } -static int st_translate_interp(enum glsl_interp_qualifier glsl_qual) + +static unsigned +st_translate_interp(enum glsl_interp_qualifier glsl_qual) { switch (glsl_qual) { case INTERP_QUALIFIER_NONE: @@ -426,11 +428,13 @@ static int st_translate_interp(enum glsl_interp_qualifier glsl_qual) return TGSI_INTERPOLATE_CONSTANT; case INTERP_QUALIFIER_NOPERSPECTIVE: return TGSI_INTERPOLATE_LINEAR; + default: + assert(0 && "unexpected interp mode in st_translate_interp()"); + return TGSI_INTERPOLATE_PERSPECTIVE; } - assert(0); - return TGSI_INTERPOLATE_PERSPECTIVE; } + /** * Translate a Mesa fragment shader into a TGSI shader using extra info in * the key. |