Hey fellow devs,
banging my head against a problem and i can’t seem to find a good solution.
I’m updating an RGBAFloat Texture2D using GetRawTextureData + Apply, then pass it to a shader which is used to blit one rendertexture to another.
My problem is that not enough time passes between texture.Apply and doing the blit, so that in the fragment shader the Texture2D has not been uploaded to the GPU yet. Moving a long enough CPU operation in that place fixes the problem, but i can’t rely on that since it might take less time on beefier machines.
I can’t seem to find any way around this.
Is there a reliable way to wait for texture.Apply finish GPU upload?