phr00t / FocusEngine

Focus Game Engine. This is Stride/Xenko fast-tracked for Phr00t's Software games. Improvements over the original Focus on Vulkan support, PC platforms, VR, performance & ease. Cherry-picks commits from other forks as needed.
MIT License
98 stars 11 forks source link

Resource loader (shaders, audio etc.) #72

Closed phr00t closed 5 years ago

phr00t commented 5 years ago

To avoid in-game hiccups for shaders to build or audio to load, there should be a system that preloads these things at the start of the application.

It would be a simple list of materials & audios, which would be played and rendered. This would load them all at once at an expected time, so it wouldn't need to be done at unpredictable times later.

phr00t commented 5 years ago

A shader resource loader wouldn't be that important if we could just use "recorded" shaders on Windows platforms and include them with Linux and Mac (which also use Vulkan). I'm not sure this is possible, since compiled shaders (aka "effects") only automatically include themselves in the running platform. This might have been done because there wasn't a unifying API used before -- but now there is: Vulkan. I need to test this out, but having other issues

phr00t commented 5 years ago

Shaders might actually be used on different platforms! When including the data/db/XX shader outputs in the Mac, I got different output from Mac -- so it must have tried to use them.

phr00t commented 5 years ago

Shaders can be easily added to any operating system. No shader resource loader is needed. An audio resource loader would be nice, though...