SDL_shader

Hi

First, I apologize for my english again :wink:
With you help, I wrote a GLSL shader class for SDL2 some month ago for the Solarus Engine which will render a SDL_Texture with an arbitrary shader (still WIP).
Issue (https://github.com/christopho/solarus/issues/394) and Sources (https://github.com/christopho/solarus/tree/master/src/lowlevel/shaders)

With the 1.2 release which coming soon, I’ll continue this little project, planning to support GLES and DX shaders (if possible) in addition to GL ones, by using some additional libraries like MojoShader (https://icculus.org/mojoshader/) and Angle (https://chromium.googlesource.com/angle/angle) to be able to use a shader written with any of the 3 main shader languages on any driver context.

Before I start the remaining work, I wonder if someone could be interested by such a project, in which case I’ll separate the code in a library like “SDL_shader” and change some implementation details.
The code is written in C++ and currently uses Lua5.1 to read and parse shader scripts, but if I’ll separate the code from the engine, I think using an XML parser can be better.

For now, I “just” plan to add a little shader abstraction (especially with samplers type), and support GLSL ES and HLSL shaders, but it will surely change if an external library is considered.

Please let me know if this can interest someone, and/or if you have any advice to make me do the proper work possible or if you see a useful features which I didn’t think about :wink:

Thank you !
Best regards.