crt-pi shader users - reduce scaling artifacts with these configs in lr-mame2003, lr-fbalpha, lr-nestopia (and more to come)
-
@Furluge there's no need for integer scaling on the curved version i think. it doesn't line up the same way
-
@dankcushions Ok, but it is still useful to have the override for all the vertical games.
-
@Furluge said in crt-pi shader users - reduce scaling artifacts in lr-mame2003/lr-fbalpha (horizontal AND vertical games):
@dankcushions Ok, but it is still useful to have the override for all the vertical games.
very true! i've done this also now - check the top post :) I've also updated the other links to have the 'tolerance' version also. not tested any of this yet but it looks ok.
-
Hi !
I am very interested in this. My Samsung UN28H4000 has a 1366x768 resolution though. Can you share a version of your work for that specific resolution ? Unless you think its too odd ? There is some part of the conversation, specifically about aspect ratio, I dont fully understand. All I am interested in is to get the proper vertical shader for vertical game and not touch my horizontal games since I am happy with the result.
Thank you for your help !
If it is easy to do, it would be nice to add a few more resolutions to your first post so you get less requests :P
-
@Nataq said in crt-pi shader users - reduce scaling artifacts in lr-mame2003/lr-fbalpha (horizontal AND vertical games):
Hi !
I am very interested in this. My Samsung UN28H4000 has a 1366x768 resolution though. Can you share a version of your work for that specific resolution ? Unless you think its too odd ?
Done! see original post :)
There is some part of the conversation, specifically about aspect ratio, I dont fully understand. All I am interested in is to get the proper vertical shader for vertical game and not touch my horizontal games since I am happy with the result.
the scripts do change horizontal games, but i think you will either not notice or be happy with what it does. if you only want to do vertical games i can generate that for you, but try first :)
-
@dankcushions Awesome ! Can't wait to try this out. Thank you :)
-
Ok I extracted the file into /opt/retropie/configs/all/retroarch/config/MAME 2003/ and I can see all the files there although the vertical shader isn't loaded in games.
- I still see the horizontal rainbow effect on vertical games
- I am using version 4.1 of retropie
- My Roms are located directly into retropie\roms\mame-libretro
- Even if I add .zip to the cfg file name and drop in roms folder it isn't working
- I can see the message saying override cfg file has been loaded when launching games
Can some part of my config block the shader change somehow ?
-
@Nataq said in crt-pi shader users - reduce scaling artifacts in lr-mame2003/lr-fbalpha (horizontal AND vertical games):
Ok I extracted the file into /opt/retropie/configs/all/retroarch/config/MAME 2003/ and I can see all the files there although the vertical shader isn't loaded in games.
- I still see the horizontal rainbow effect on vertical games
- I am using version 4.1 of retropie
- My Roms are located directly into retropie\roms\mame-libretro
- Even if I add .zip to the cfg file name and drop in roms folder it isn't working
- I can see the message saying override cfg file has been loaded when launching games
Can some part of my config block the shader change somehow ?
it's maybe possible! what i would suggest is updating to the latest retroarch binary, which should be via retropie-setup > manage packages > core > retroarch > update by binary. this should make sure you have the latest shaders in the right place, and the version of retroarch that supports these overrides (which I guess you should already have but still...)
if that doesn't work, can you upload your configs:
/opt/retropie/configs/all/retroarch.cfg
/opt/retropie/configs/mame-libretro/retroarch.cfg
maybe something in there, but i thought that overrides should override all!
-
@dankcushions Will my config files be overwritten by updating to the latest retroarch binary ? I have put so much work in this hehe. Will make sure to backup first anyway but would like to know.
Will post my main retroarch.cfg and mame-libreto one later tonight as I can't access it right now.
I have seen in another post that those lines are needed for per rom config to work :
core_specific_config=false
auto_overrides_enable=trueCan you confirm ?
Thanks again for your time !
-
@Nataq said in crt-pi shader users - reduce scaling artifacts in lr-mame2003/lr-fbalpha (horizontal AND vertical games):
@dankcushions Will my config files be overwritten by updating to the latest retroarch binary ? I have put so much work in this hehe. Will make sure to backup first anyway but would like to know.
no :)
Will post my main retroarch.cfg and mame-libreto one later tonight as I can't access it right now.
I have seen in another post that those lines are needed for per rom config to work :
core_specific_config=false
auto_overrides_enable=trueCan you confirm ?
oh, this might be it! yes the second one is required. the first... i don't think so. i wouldn't change it.
-
@dankcushions Thank you, you're a real lifesaver. It was so strange having all my crt based systems doing curve but arcades.
-
Well, it didnt worked :(
Updated to latest binaries and tried the two strings in retrorach.cfg all and libretro-mame.
Here is my \retropie\configs\all\retroarch.cfg : https://dl.dropboxusercontent.com/u/26446913/all-cfg/retroarch.cfg
And \retropie\configs\mame-libretro\retroarch.cfg : https://dl.dropboxusercontent.com/u/26446913/mame-libretro-cfg/retroarch.cfg -
@Nataq i see some problems with your cfgs. you should put
auto_overrides_enable="true"
as the first line in both to be sure.also what game are you running, from which directory and using which emulator?
-
Spent another few hours on this this morning and found a few interesting things although still not working.
I did realized the .cfg files located in /opt/retropie/configs/all/retroarch/config/MAME 2003/ are actually doing something : When I load a game, like Aliens, the screen is now more squished vertically with smaller black bars on the left and right of the screen. If I remove the aliens.cfg from that folder then the screen is back to normal or unaltered format with bigger black bars on the sides. Seems like the config files are taken into account finally BUT, and this is where I really scratch my head now, whatever shader I specify from those game config files isn't loaded properly thus explaining why vertical games are not showing the vertical shader.
So my only focus now is to figure out why I can't specify a shader in those config files.
For example, the command line for an horizontal game as per your game cfg files is this :
video_shader = "/opt/retropie/configs/all/retroarch/shaders/crt-pi.glslp"If I change it for video_shader = "/opt/retropie/configs/all/retroarch/shaders/crt-pi-curvature.glslp" its should be pretty obvious if working by seeing the curved screen. But it isn't showing. Whatever shader I specify there has no effect (still show the crt-pi shader) although the other format settings related to the format are taken into account.
I can see all the shaders in the folder located here: /opt/retropie/configs/all/retroarch/shaders so its not like they are not present.
I am wondering if MAME somehow has more privilege over the per game cfg files (as for the button mapping for example) and is not taking control of the shader... if that make sense...
My MAME roms are located in : \retropie\roms\mame-libretro and as far as I know I am using MAME2003. I would like to confirm this but somehow my retroarch menu binding isn't working in MAME (that is another story).
I appreciate your help and wouldn't mind opening another thread for that "can't change shader" issue since I understand it might not be totally related to the solution you offer here.
Thank you again very much.
-
ok i have a 1080p override file for nes that i'm playing around with. name it
Nestopia.cfg
:# Auto-generated crt-pi.glslp .cfg # Place in /opt/retropie/configs/all/retroarch/config/Nestopia video_shader_enable = "true" video_shader = "/opt/retropie/configs/all/retroarch/shaders/crt-pi.glslp" custom_viewport_width = "1536" custom_viewport_height = "1120" custom_viewport_x = "192" custom_viewport_y = "-20" aspect_ratio_index = "22"
it requires lr-nestopia as your default nes emulator (it's lr-fceumm by default i think). this is because fceumm seems to have some dropped frames at 1080p. plus it handles resolutions slightly differently.
i need to try it with more games but it seems to work quite nicely. you lose a bit of the extreme top and bottom of the image but this doesn't seem to cut off anything relevant to gameplay so far. plus with these settings it's properly integer scaled, and pretty close to 4:3 resolution :)
-
I have created another thread not to pollute this one with my issue above but since I have found a solution I will put it here too.
In short, the path to the shader was the issue. I don't know why since I can find the shaders in the folder but using the Retroarch GUI to save a shader change, I have found it created this path to get to the shader :
video_shader = "~/.config/retroarch/shaders/crt-pi-vertical.glslp"
If I use that same line in any .cfg files I have, it works fine.
I am wondering why your path isn't working though but I can now easily adjust.
I hope that can help others getting this to work.
Thanks for the help again !
Edit: My issue might have something to do with this : https://github.com/libretro/RetroArch/issues/349
-
Back to the topic,
I can see the scanlines are working great with your cfgs but the aspect ratio bugs me. I find it considerably squished the screen vertically for horizontal games (maybe more so because of my lower 1366x768 resolution ?).
On the good part, it does result in more screen space used which is good for my 28" monitor in my arcade cabinet.
Didn't tried tons of games yet but some games seems totally off as far as aspect ratio. For example, Toobin resulted in a very slim vertical screen.
-
@Nataq said in crt-pi shader users - reduce scaling artifacts in lr-mame2003/lr-fbalpha (horizontal AND vertical games):
Back to the topic,
I can see the scanlines are working great with your cfgs but the aspect ratio bugs me. I find it considerably squished the screen vertically for horizontal games (maybe more so because of my lower 1366x768 resolution ?).
On the good part, it does result in more screen space used which is good for my 28" monitor in my arcade cabinet.
Didn't tried tons of games yet but some games seems totally off as far as aspect ratio. For example, Toobin resulted in a very slim vertical screen.
toobin cfg in mame2003:
# Auto-generated crt-pi-vertical.glslp .cfg # Place in /opt/retropie/configs/all/retroarch/config/MAME 2003/ video_shader_enable = "true" video_shader = "/opt/retropie/configs/all/retroarch/shaders/crt-pi-vertical.glslp" # To avoid horizontal rainbow artefacts, use integer scaling for the width aspect_ratio_index = "22" custom_viewport_width = "384" custom_viewport_height = "768" custom_viewport_x = "491" custom_viewport_y = "0"
the native gamewidth is 384. so you've basically got the choice between 384 or 768 (1x or 2x horizontal scale). as it stands, 384 / 768 (the current height) is an aspect ratio of 0.5, vs the 0.75 (3:4) it would be usually (so slimmer than usual). if you used 768 as the width, the aspect ratio is 1.0, which is a square image (fatter than usual).
they're both out by the same amount so it's a matter of preference. the algorithm should actually default to the fatter image.. i've just fixed that and re-uploaded all the configs.
it might be you don't like the fat version either :) if so let me know and maybe i'll also generate a set without any scaling changes, with just the vertical/regular crt-pi shaders. smaller screens probably suffer from this sort of thing regularly. but you'll get scaling artifacts...
-
i have updated the top post to include cfgs for lr-nestopia :)
-
In some games the fatter version is OK and i some other it bugs me more. Both options are viable I guess. I don't want to take more of your time but would it be feasible to genarate configs with my shader path ? What works for me is this :
video_shader = "~/.config/retroarch/shaders/crt-pi-vertical.glslp"
And like if its not enough, how about a little windows GUI instead of a python script where you could input your shaders path, screen resolution and hit "Generate" to start the magic ? ;) You could always chose to include the scaling parameter or not or just generate cfgs for vertical games only. Why not add a blank space too so to add any other custom command lines... That would be fantastic ! And probably not so hard to code. You may already have the code for that actually.
Makes me think if there is other sort of "config generators" already... That could really be helpful instead of editing cfg one by one.
Thanks again for your work !
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.