On Wed Apr 19 20:13:19 2023 +0000, Francisco Casas wrote:
Yep, it is supposed to be `count`. The purpose of `count` is indeed to keep track of how many registers the variable actually needs to allocate, which may be less than the register size. If the resource has a register reservation, `count` should be the register size. If the resource is not used at all, `count` should be zero. If only some elements are used, sampler arrays only allocate until the last used one, while texture arrays allocate all. I have some tests along the line for patches after these ones, but perhaps some are missing at this stage. I added a couple of simple tests for texture arrays in object-parameters.shader_test .
Yeah, I understand the code in this case, I just wanted to double-check if this was correct, without going to the trouble of checking personally whether we have tests for it :-)