Created attachment 2535[details]
speedup
Building shader buffer can take a lot of time in case if you have many pk3 files with shaders, as actually it grows in algebraic progression according to number of shader files loaded. Suggested solution brings it back to linear dependency which results in significant speedup: from ~2s to ~50ms in my case
Created attachment 2535 [details] speedup Building shader buffer can take a lot of time in case if you have many pk3 files with shaders, as actually it grows in algebraic progression according to number of shader files loaded. Suggested solution brings it back to linear dependency which results in significant speedup: from ~2s to ~50ms in my case