cepl
cepl copied to clipboard
When a buffer is bound old bindings in cache arent broken
We need to add cache enum to the gpu-buffer and when a thing bound:
- if the target contains a buffer, set it's index to 0
- if the buffer already has a cache enum set the relevent slot in the cache to nil
Easiest example of issue is binding same buffer back and forth between two targets. First of each work and then cache thinks its already bound to both places and never rebinds. blech.
This gets gnarly as ubo, ssbo and transform feedback bindings have been cached seperately and I think we need to take all these into account.