Fix light uniforms not properly being updated


- We cache commands and only rebuild them when really needed. When we rebuild
  then, we also store the mapping between uniform location and parameter name
- When reusing a command, we only update the uniform values but expect the
  mapping between to remain the same.
- When dealing with lights however, we can end up in a case where the light type
  changes, and therefore so does the shader data associated. The command remains
  cached as nothing really requires a rebuid. Yet, this means we could
  have more or less parameters than the number of mappings we have stored
  previously if the shader data defines more or less properties. To account for
  this, we now rebuild the mapping when building the command or if the number of
  parameters in the parameter pack is different than at the previous frame.

Change-Id: I9400fc7e5bcb4b97ac9da69cdf794010cf81103b
Pick-to: 6.0 5.15
Reviewed-by: Mike Krus <mike.krus@kdab.com>
commita7f627b29b2792154bc2a45f31bd32b74fd508b4
parenta70e425611d80cc1d62ddd724d9f234e213503fd
authorPaul Lemire <paul.lemire@kdab.com>
committerPaul Lemire <paul.lemire@kdab.com>
commit timeWed, 27 Jan 2021 16:00:33 +0100