Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Retroarch: Add libretro glsl and slang shaders if platform is not rpi #3395

Closed
wants to merge 2 commits into from
Closed

Conversation

gizmo98
Copy link
Member

@gizmo98 gizmo98 commented Aug 29, 2021

The current RetroPie/common-shaders master branch is outdated (last update 2016). Libretro has an own glsl repo with glsl now. Common-shaders has no slang shaders for video drivers glcore and vulkan.

This PR adds three folders in the shader directory if platform is not rpi.
shaders/slang: Contains libretro slang shaders for drivers glcore/vulkan
shaders/glsl: Contains libretro glsl shaders for driver gl
shaders/retropie: Contains common-shaders branch rpi shaders for driver gl

… rpi

Add an shaders/retropie folder which contains the current
RetroPie/common-shaders:rpi branch, so it is possible to use the same
shaders as a rpi user.
Another advantage: CRT-PI is faster then the most libretro crt shaders.
@joolswills
Copy link
Member

I assume this will cause issues though for existing configs - maybe we should put a notice somewhere or at least have a topic on the forum ?

@gizmo98
Copy link
Member Author

gizmo98 commented Sep 1, 2021

It will certainly interfere with current configs. So it’s a good idea to add a notice. Our master branch is neglected. I cannot load shaders of folder retropie because all precision fixes of branch ‚rpi‘ are missing. The other shaders can be loaded but all upstream changes and fixes are missing. Non of the current shaders can be used if video driver is glcore or vulkan.

@joolswills
Copy link
Member

Yeah - I agree with it in general. Perhaps we should make it so we have a similar folder structure for the rpi also - but obviously this is more config breakage unless we put it elsewhere and symlink.

@gizmo98
Copy link
Member Author

gizmo98 commented Sep 1, 2021

Really ugly solution:
Keep current shader folder and add folders glsl and slang. Remove content of shaders/retropie folder (these shaders are not usefull without fixes of branch common-shaders: rpi ). Just fill the three folders and keep the rest as it is.

V0rt3x667 added a commit to V0rt3x667/ArchyPie-Setup that referenced this pull request Oct 17, 2021
@barbudreadmon
Copy link
Contributor

What about pi4 ? I think this PR doesn't allow usage of slang shaders on pi4, while it should also support vulkan & glcore (note that glcore won't be forced on gles platforms).

Note that glcore should probably always be prefered over gl on platforms compatible with both : from the tests i did last year it was slightly faster due to less retroarch overhead.

@cmitu
Copy link
Contributor

cmitu commented Oct 30, 2021

What about pi4 ? I think this PR doesn't allow usage of slang shaders on pi4, while it should also support vulkan & glcore (note that glcore won't be forced on gles platforms).

Isn't glcore for OpenGL 3+ devices ? The Pi4 has only OpenGL 2.1 support, so it wouldn't work with it.

For vulkan, this will probably be available on the next RPI OS release (based on Debian 11 bullseye) and we can probably add a (new) vulkan flag to pull in the slang shaders for the platforms supporting it.

@joolswills
Copy link
Member

I'm not going to implement the PR as is anyway most likely. Just was referencing it. I've not yet decided how I will implement it.

@barbudreadmon
Copy link
Contributor

@cmitu glcore is kinda misnamed, it should have been moderngl or something, in the case of gles platforms i think RA's glcore video driver is associated with gles3 capabilities.

@gizmo98
Copy link
Member Author

gizmo98 commented Oct 31, 2021

@barbudreadmon does it make sense to enable glcore for Pi4? Rpi optimized glsl shaders will not work by default.

Should we test if glcore + rpi optimized ported slang shaders run better than gl + rpi optimized shaders?

@barbudreadmon
Copy link
Contributor

@gizmo98 you should probably give it a try

This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants