diff options
author | Ilia Mirkin <imirkin@alum.mit.edu> | 2015-02-09 19:39:13 -0500 |
---|---|---|
committer | Ilia Mirkin <imirkin@alum.mit.edu> | 2015-02-10 21:56:49 -0500 |
commit | 63687177b023df8855826a3c9414eb36f4847b91 (patch) | |
tree | aa1663c1a0f473131674aa763439e5c74291eab2 | |
parent | 294d5d448ca26a4e13e8e4a154d948cd50ff2576 (diff) |
shader_runner: fix dvec ubo uploads
The number of elements is at index 4, not 3 (like in vec)
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Dave Airlie <airlied@redhat.com>
-rw-r--r-- | tests/shaders/shader_runner.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/shaders/shader_runner.c b/tests/shaders/shader_runner.c index baccd355e..c193de9d6 100644 --- a/tests/shaders/shader_runner.c +++ b/tests/shaders/shader_runner.c @@ -1305,7 +1305,7 @@ set_ubo_uniform(const char *name, const char *type, const char *line, int ubo_ar get_uints(line, uints, elements); memcpy(data, uints, elements * sizeof(unsigned)); } else if (string_match("dvec", type)) { - int elements = type[3] - '0'; + int elements = type[4] - '0'; get_doubles(line, d, elements); memcpy(data, d, elements * sizeof(double)); } else if (string_match("mat", type)) { |