Hello,
I wanted to revisit this topic, that was outlined in details by @readme in this thread a while ago:
Simmilar to the problems in this thread, i am having an application that continously need to load from a large amount of textures on a drive.
I am loading 64 times 1024x1024 res texture in a for loop and rendering them to basic meshrenderer drawcalls. And the textures are changing often during runtime.
The problem is, that FileTexture is the node that is producing the least lag, however it is keeping the texture in memory. This is useful in this scenario because then the texture is directly available when its loaded a second time.
The problem is that the RAM is filling up quiete fast. Only when it is maxing out at 64 GB, it is starting to have some kind of garbage collection process in the background, causing it to go down with RAM to about under 55 GB, but then it would hover with this high RAM through out the runtime of the application, making it instable as soon as a browser is opened or any other task performed on the system! It might also stop loading textures at all after additional Ram is needed from the system.
So the question here is, can we limit RAM usage of the underlying Stride engine?
The second problem I have is that as an alternative TextureReader (Async) was proposed in another thread.
However this node is producing a lag when used in a for loop region and is significantly slower, so i can not use it (at least not in the same instance, and i am refusing so far to try piping continusly 64 textures with spout and ending up with a complicated loading logic)
As a workaround to the for loop lag, I tried to build a sequential loader that uses TextureReader (Async) and a Queue node with a respective loading logic, but it is unfortunatly too slow even on the fastest NVME SSD.
The ImageReader Skia Node is much fast and could be used to fill the sequential loading queue. However, when using SkiaTexture Node. The Queue node has a bug that causes all the slices to be set to the current input texture, instead of only the first slice. This does not happen with FileTexture or any other Texture Input. Reporting this bug is a bit of an extra story, but my point is, that I feel like I am out of choises for effective on the fly loading of a lot of textures??
Any recommendations to this are very appreciated :)
edit: and it is not possible to convert the textures (.png and .jpg) to compressed format because of filesize is huge and it would take probably more than a week
