Then if the maximum amount is something that will fit in a uniform array, not sure what the limits are, you could on the shader side allocate enough space for the maximum and have another uniform that tells you how many of those data points are valid.
↧