From: Brian Date: Mon, 26 Mar 2007 19:04:57 +0000 (-0600) Subject: In _mesa_lookup_parameter_constant() make sure we return a full, 4-component swizzle. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=680abf8a02bd88e55ebaa81326c7621a745bedd4;p=mesa.git In _mesa_lookup_parameter_constant() make sure we return a full, 4-component swizzle. --- diff --git a/src/mesa/shader/prog_parameter.c b/src/mesa/shader/prog_parameter.c index adffafdd713..2c8a3407634 100644 --- a/src/mesa/shader/prog_parameter.c +++ b/src/mesa/shader/prog_parameter.c @@ -532,6 +532,10 @@ _mesa_lookup_parameter_constant(const struct gl_program_parameter_list *list, } } } + /* smear last value to remaining positions */ + for (; j < 4; j++) + swz[j] = swz[j-1]; + if (match == vSize) { *posOut = i; *swizzleOut = MAKE_SWIZZLE4(swz[0], swz[1], swz[2], swz[3]);