Gameboy-colors glsl shader on android not working

Hello,

I’ve had trouble with glsl shader which corrects GBA colors (cgp/gameboy-colors.glslp). I’m running it on android. It does not do the job, colors stay the same. Other shaders are working fine. For example Gameboy-screen-grid.glslp does the grid (but not the color correction). Maybe the misc/image-adjustment.glsl is not working properly?

Can someone confirm that this is bug or point to how to fix it?

Those cgp files depend on parameters working, and our cg2glsl script is incapable of converting them (among a few other problems.). However, I have a repo where I’ve converted some shaders to glsl by hand and included parameters and LUTs:

If you get the image-adjustment shader from there and replace the script-converted one, it should work.

[QUOTE=hunterk;27290]Those cgp files depend on parameters working, and our cg2glsl script is incapable of converting them (among a few other problems.). However, I have a repo where I’ve converted some shaders to glsl by hand and included parameters and LUTs:

If you get the image-adjustment shader from there and replace the script-converted one, it should work.[/QUOTE]

Thank you for converting shaders for android hunterk! But I tried image-adjustment one and it didn’t work for me. Shows “no shader parameters” in shader menu. I tried to edit the saturation value manually in notepad “#define saturation 3.0”. No change, colors stay the same. I use the latest version of Retroarch from Google Play.

Hmm. Works fine here. How are you getting them? Saving directly from github can be weird. You have to display as ‘raw’ and then ‘save as’; if you just right-click and ‘save link as’ it will save an html file instead of the actual shader.

Yes I saved as glsl. I tried other shaders from your repo and they work but I still can’t change parameters. In Windows I can but on Android I can’t. Maybe android build doesnt support parameter changing?

I just tried it on my phone and was able to see the parameters just fine. Which version of RetroArch are you using? I’m on the one from the Play store.

Play store version here too. I don’t know what to think. Well, at least now I know that the problem is on my side sigh

Dunno if it’ll help, but you could try to use one of the nightlies. Are you making sure you hit ‘apply shader changes’ before you try to modify the values? ‘load shader preset’ automatically applies changes, but if you manually set the passes, you have to apply them before you can fiddle with parameters.

Yes I hit apply before modifying values. Tried latest nightly and older versions (1.2.1, 1.2.0) with no luck. Will test on my friend’s tablet. Maybe something is wrong with my software hardware combo.

Great work, I always wanted to use those gameboy preset, just tried the converted ones and runs perfect. Hunterk, could you fix other glsl shaders too?, such crt lottes and the ntsc ones? PS: tried the crt geom but it didint work.

Sure, I’ll fix a few others. I focused on ones that either didn’t work at all–mostly due to LUTs not getting copied over–or ones that were basically useless without parameters (e.g., image-adjustment). I’m not planning to do many that already work fine auto-converted (minus the parameters, of course) because I don’t want this repo to diverge too much from the main one and I don’t want to have to maintain a bunch by hand.

I don’t think I’ll be able to tackle the NTSC shaders because they’re very complex with a bunch of weird includes. However, I already ported a version to higan’s quark glsl (and unrolled all of the labyrinthine includes), so i might be able to re-port that a little easier…

Oops, crt-geom is broken on my phone, too. IIRC, it worked on my linux PC, so there may be something screwy going on with drivers or something. I’ll investigate.

Logs show that image-adjustment.glsl simply doesn’t compile and reverts to stock. And as a result I don’t see any shader parameters.

I also tried this shader in http://themaister.net/glslview/ It shows “Vertex shader failed to compile” and “Vertex errors: ERROR: 0:? : ‘’ : syntax error”

That shader only has ~210 lines, so the fact that you’re getting 1200+ lines suggests that it was downloaded from github incorrectly and is actually a bunch of html code labeled as GLSL. This can happen if you right-click on the link in the repo and ‘save link as’ instead of going into it and viewing the ‘raw’ code and saving that. I’m looking at the incorrect method’s output right now and it’s a little under 1400 lines with lots of quotation marks, so it seems likely that’s what’s happened.

Try this one:

Mediafire one gives me the same result. I don’t think I save incorrectly because it works perfectly on Windows version of Retroarch (this same file from your repo). Does this shader work for you in http://themaister.net/glslview/ ?

Mediafire one gives me the same result. I don’t think I save incorrectly because it works perfectly on Windows version of Retroarch (this same file from your repo). Does this shader work for you in http://themaister.net/glslview/ ?

No, it crashes with a vertex error here, too.

This ended up being a weird issue but I got it worked out now, hopefully (works on my PC and phone, at least), and I also got parameters added to crt-lottes.

Thanks for the good work, hunterk.

My android tab refused to charge so it went to repair for a month and now I got it back. When I tried your shaders on phone they haven’t worked for me either. I will try again with my tab today.

EDIT: It works correctly. Must have done some mistake with the phone.