[Piglit] [PATCH] shader_runner: Support "matN" notation for loading uniforms.

Ian Romanick idr at freedesktop.org
Thu Jan 19 08:44:58 PST 2012

On 01/18/2012 03:54 PM, Kenneth Graunke wrote:
> On 01/18/2012 03:28 PM, Ian Romanick wrote:
>> On 01/17/2012 10:42 PM, Kenneth Graunke wrote:
>>> Prior to this patch, shader_runner only accepted the "matMxN" notation,
>>> rejecting the simpler "matN" form. Since "matN" is by far more common,
>>> it makes sense to support "mat4" rather than requiring "mat4x4".
>> When I added matMxN support I intentionally left out matN. It just adds
>> extra crap to shader_runner, which is already out of control. You can
>> use matMxN with a shader code that uses matN, so I don't see the point.
>> Maybe you can convince me otherwise?
> When I started, I thought that shader_runner simply didn't support
> matrices; it didn't occur to me to try the matNxN notation. If it were
> complicated to support, I'd agree with you, but I think the diffstat
> debunks your "it adds extra crap" argument pretty soundly:

Fair point.

Reviewed-by: Ian Romanick <ian.d.romanick at intel.com>

>>> tests/shaders/shader_runner.c | 14 +++++++-------
>>> 1 files changed, 7 insertions(+), 7 deletions(-)
> It takes net 0 lines of code to support matN. Also, using descriptive
> names like "rows" and "cols" is arguably easier to read.

More information about the Piglit mailing list