RHI: handle uniforms of type arrays properly
We weren't handling the possible array stride for uniform arrays.
For a float[8], the GPU might expect each float to fit in a vec4 slot.
We therefore have to handle that when uploading the values otherwise
we could end having data in what the GPU believe is padding data.
This required modifying the UniformValue object to report the number
of elements it contains as it might not necessarely be the same as the
array dimension reported by the shader introspection.
Note: it seems that the arrayStride might not be reported properly.
To work around that, if we know we are dealing with an array, we
compute the stride ourselves.
Pick-to: 6.0
Change-Id: I12b5379927dd47be888a40db58c2e5aba6e0730b
Reviewed-by: Mike Krus <mike.krus@kdab.com>