Homepage Forums RetroPie Project Video Output on RetroPie How to get scanlines and vastly improve picture quality: the best method

Tagged: ,

Viewing 35 posts - 71 through 105 (of 119 total)
  • Author
    Posts
  • #98039
    patrickm
    Participant

    [quote=98032]

    bump; added 5x scale scanline overlay (1920×1080). Also added step-by-step instructions.

    How do I make the changes permanent. I try to go back on the RGUI and hit on the save new config option and nothing happens. Once I restart the emulator it goes back to the old settings.
    By mistake I change on the RGUI the configurations to the retroarch.cfg file is that ok? How do I change back to the old libreto field

    You can make settings stick by navigating to the right config file in /opt/retropie/configs/ and find the right emulator folder. Within each emulator folder there is a “retroarch.cfg” which has settings which overwrite the global settings. Any settings which you wish to make permanent should be added there. There should also be an “emulator-name.cfg” in each emulator folder. You can rename this to “retroarch.cfg” and it will be loaded next time you launch RA.

    well yeah I know how to do that. I set a permanent shader for my snes emulator. What I want to know is that why when I follow your steps I save it in the RGUI and once I exit out of any particular emulator my previous settings of adding the scanlines, filters and scaling are erase. Once I start the emulator again I have to go and go through your steps once again. Do you happen to know the code that I have to write in the retroarch.cfg file to make the steps from your original post permanent for my nes, snes, and megadrive. Also when I apply your scanline file on the RGUI I don’t see a difference on the nes or snes emulator. Also how do you apply the dotmask filter plus the scanline file that you provided together. If I go to options and filters I don’t see that particular filter. All your help is appreciated, thanks.

    [/quote]

    To set the overlay, put the .png and .cfg (for the overlay) in the appropriate overlay folder, then select the .cfg in retroarch. Settings -> overlay settings, set the overlay preset and be sure “overlay enable” is on

    To set the shader go to options -> shader options -> shader passes, set to 1. Then under shader 0 select the dotmask shader in the /shader/CRT/ directory. The hit apply shader settings.

    Make sure SNES and NES are set to render at the correct resolution, also. Scaling can cause overlays to not work correctly. Also make sure overlay opacity is set higher than 0 :)

    #98041
    dragonjab
    Participant

    [quote=98033]Add the extra lines into the existing system retroarch.cfg (at the top), dont rename one to be retroarch.cfg.

    I’ll try to do a video soon.

    [/quote]
    Yeah I didn’t rename one. Which lines do I add to the existing file? I went over your vid on how to setup shaders for the snes, but I want to do exactly what patrickm is doing in his original. I follow all the steps, but I can’t seem to make the changes reload when I restart the emulator. I have to go through the steps all over again every time I want to play a game. If possible can you make a video on how to do all the steps that patrickm wrote. Plus adding the dotmask shader I can’t seem to make this one work. So Scanlines plus dotmask shader. Thanks I apreciate all you guys help.

    #98042
    patrickm
    Participant

    [quote=98033]Add the extra lines into the existing system retroarch.cfg (at the top), dont rename one to be retroarch.cfg.

    I’ll try to do a video soon.

    [/quote]

    You have to do a separate config for each emulator to get the correct resolution and scaling.

    I’m not sure what the exact difference is between renaming configs vs adding lines to retroarch.cfg, but your method is probably safer as you can just delete the added lines if something goes wrong.

    #98043
    dragonjab
    Participant

    [quote=98039]

    bump; added 5x scale scanline overlay (1920×1080). Also added step-by-step instructions.

    How do I make the changes permanent. I try to go back on the RGUI and hit on the save new config option and nothing happens. Once I restart the emulator it goes back to the old settings.
    By mistake I change on the RGUI the configurations to the retroarch.cfg file is that ok? How do I change back to the old libreto field

    You can make settings stick by navigating to the right config file in /opt/retropie/configs/ and find the right emulator folder. Within each emulator folder there is a “retroarch.cfg” which has settings which overwrite the global settings. Any settings which you wish to make permanent should be added there. There should also be an “emulator-name.cfg” in each emulator folder. You can rename this to “retroarch.cfg” and it will be loaded next time you launch RA.

    well yeah I know how to do that. I set a permanent shader for my snes emulator. What I want to know is that why when I follow your steps I save it in the RGUI and once I exit out of any particular emulator my previous settings of adding the scanlines, filters and scaling are erase. Once I start the emulator again I have to go and go through your steps once again. Do you happen to know the code that I have to write in the retroarch.cfg file to make the steps from your original post permanent for my nes, snes, and megadrive. Also when I apply your scanline file on the RGUI I don’t see a difference on the nes or snes emulator. Also how do you apply the dotmask filter plus the scanline file that you provided together. If I go to options and filters I don’t see that particular filter. All your help is appreciated, thanks.

    To set the overlay, put the .png and .cfg (for the overlay) in the appropriate overlay folder, then select the .cfg in retroarch. Settings -> overlay settings, set the overlay preset and be sure “overlay enable” is on

    To set the shader go to options -> shader options -> shader passes, set to 1. Then under shader 0 select the dotmask shader in the /shader/CRT/ directory. The hit apply shader settings.

    Make sure SNES and NES are set to render at the correct resolution, also. Scaling can cause overlays to not work correctly. Also make sure overlay opacity is set higher than 0 :)

    [/quote]
    Ok snes and nes are set to render at correct resolutions. The scanlines part is done and dotmask shader too. I’m still having the problem were I have to set this setting over again when I restart the emulator.

    #98044
    patrickm
    Participant

    [quote=98041]

    Add the extra lines into the existing system retroarch.cfg (at the top), dont rename one to be retroarch.cfg.

    I’ll try to do a video soon.

    Yeah I didn’t rename one. Which lines do I add to the existing file? I went over your vid on how to setup shaders for the snes, but I want to do exactly what patrickm is doing in his original. I follow all the steps, but I can’t seem to make the changes reload when I restart the emulator. I have to go through the steps all over again every time I want to play a game. If possible can you make a video on how to do all the steps that patrickm wrote. Plus adding the dotmask shader I can’t seem to make this one work. So Scanlines plus dotmask shader. Thanks I apreciate all you guys help.

    [/quote]

    The dotmask shader is very very subtle, you have to have your nose pressed to the screen to see the mask. If you are able to get other shaders working than this one is probably working, too. The most immediately noticeable effect is that it darkens the screen somewhat.

    Yeah, some videos would be nice :)

    I don’t really have the means to record quality video.

    #98046
    dragonjab
    Participant

    [quote=98044]

    Add the extra lines into the existing system retroarch.cfg (at the top), dont rename one to be retroarch.cfg.

    I’ll try to do a video soon.

    Yeah I didn’t rename one. Which lines do I add to the existing file? I went over your vid on how to setup shaders for the snes, but I want to do exactly what patrickm is doing in his original. I follow all the steps, but I can’t seem to make the changes reload when I restart the emulator. I have to go through the steps all over again every time I want to play a game. If possible can you make a video on how to do all the steps that patrickm wrote. Plus adding the dotmask shader I can’t seem to make this one work. So Scanlines plus dotmask shader. Thanks I apreciate all you guys help.

    The dotmask shader is very very subtle, you have to have your nose pressed to the screen to see the mask. If you are able to get other shaders working than this one is probably working, too. The most immediately noticeable effect is that it darkens the screen somewhat.

    Yeah, some videos would be nice :)

    I don’t really have the means to record quality video.

    [/quote]
    Yep as soon as I apply the scanlines the screen darkens, so I know I did that right.
    But like said earlier I’m still having the problem of redoing everything after I change games or exit out of the emulator.

    #98048
    Floob
    Member

    A key reason for using the existing retroarch.cfg files is the internal reference to the overarching retroarch.cfg in the /all folder – which in turn pulls in the autoconfig controller files.

    I’ll hopefully have time this weekend to do a guide.
    If you want to give me a specific shader or scanline setting example to try I’ll base the video on that.

    #98051
    patrickm
    Participant

    [quote=98046]

    Yep as soon as I apply the scanlines the screen darkens, so I know I did that right.
    But like said earlier I’m still having the problem of redoing everything after I change games or exit out of the emulator.

    [/quote]

    You know, the easiest way to so this might be to select “configuration per core ON” and “configuration save on Exit ON”. Both are in general settings.

    Although I have not personally tested this.

    You can also rename the core-specific config in the opt/retropie/configs/emulatorfolder to “retroarch.cfg”. If you do this, be sure to name the existing .cfg in that same folder to “retroarch.cfg.bk” or something, so you can revert to it if something goes wrong.

    That, or wait for Floob’s video that makes this easy to understand :)

    #98053
    patrickm
    Participant

    [quote=98048]A key reason for using the existing retroarch.cfg files is the internal reference to the overarching retroarch.cfg in the /all folder – which in turn pulls in the autoconfig controller files.

    I’ll hopefully have time this weekend to do a guide.
    If you want to give me a specific shader or scanline setting example to try I’ll base the video on that.

    [/quote]

    It seems like in an older version of the script, the internal references were carried over to the core-specific config when it was saved. Maybe that isn’t the case any more?

    Would it be possible to bypass needing to edit config files by doing the following under general settings:
    -configuration per core: ON
    -configuration save on exit: ON

    Would this work?

    A video explaining the following would be excellent:
    -how to get proper integer video scaling and set a custom ratio (needed to get proper scanlines)
    -how to properly set the scanline overlays in the OP (both the 4x version and the 5x version)
    -how to apply the dotmask shader
    -how to save these settings

    #98054
    dragonjab
    Participant

    [quote=98053]

    A key reason for using the existing retroarch.cfg files is the internal reference to the overarching retroarch.cfg in the /all folder – which in turn pulls in the autoconfig controller files.

    I’ll hopefully have time this weekend to do a guide.
    If you want to give me a specific shader or scanline setting example to try I’ll base the video on that.

    It seems like in an older version of the script, the internal references were carried over to the core-specific config when it was saved. Maybe that isn’t the case any more?

    Would it be possible to bypass needing to edit config files by doing the following under general settings:
    -configuration per core: ON
    -configuration save on exit: ON

    Would this work?

    A video explaining the following would be excellent:
    -how to get proper integer video scaling and set a custom ratio (needed to get proper scanlines)
    -how to properly set the scanline overlays in the OP (both the 4x version and the 5x version)
    -how to apply the dotmask shader
    -how to save these settings

    [/quote]
    Couldn’t say it better myself. All the steps you listed would be great in a vid. Also if you can add what I good shader might be for the megadrive or genesis. All look horrible in my part. thanks for the help both of you.

    Also do you guys happen to know on how to add shadders or scanlines into mame or Final burn alpha. Also how in the world do you scale the emulator for MAME and Final Burn Alpha?

    #98056
    patrickm
    Participant

    [quote=98054]

    A key reason for using the existing retroarch.cfg files is the internal reference to the overarching retroarch.cfg in the /all folder – which in turn pulls in the autoconfig controller files.

    I’ll hopefully have time this weekend to do a guide.
    If you want to give me a specific shader or scanline setting example to try I’ll base the video on that.

    It seems like in an older version of the script, the internal references were carried over to the core-specific config when it was saved. Maybe that isn’t the case any more?

    Would it be possible to bypass needing to edit config files by doing the following under general settings:
    -configuration per core: ON
    -configuration save on exit: ON

    Would this work?

    A video explaining the following would be excellent:
    -how to get proper integer video scaling and set a custom ratio (needed to get proper scanlines)
    -how to properly set the scanline overlays in the OP (both the 4x version and the 5x version)
    -how to apply the dotmask shader
    -how to save these settings

    Couldn’t say it better myself. All the steps you listed would be great in a vid. Also if you can add what I good shader might be for the megadrive or genesis. All look horrible in my part. thanks for the help both of you.

    [/quote]

    I just use the 5x scanline overlay at 100% with integer scaling at 5x (vertical) on pretty much everything. This crops the video on some systems but it never crops more than the overscan area.

    I wouldn’t recommend most shaders, personally, unless you have a 720p native display. The dotmask shader is an exception because it’s lightweight enough to run at 1080p without causing performance problems. Personally, I like the look of just scanlines without the dotmask.

    #98068
    dragonjab
    Participant

    so do you guys have any suggestions for a better picture quality for MAME and finalburn ALpha?

    #98070
    patrickm
    Participant

    [quote=98068]so do you guys have any suggestions for a better picture quality for MAME and finalburn ALpha?

    [/quote]

    I haven’t used those, but I believe you can use an overlay to get scanlines in MAME in a similar way.

    #98163
    zonitz
    Participant

    I tried your scanline overlay but the picture (scanlines) was not show. The overlay only darkened the picture. Could you please upload the two pictures in a .zip file instead, they might have been modified during upload or something?

    #98179
    patrickm
    Participant

    [quote=98163]I tried your scanline overlay but the picture (scanlines) was not show. The overlay only darkened the picture. Could you please upload the two pictures in a .zip file instead, they might have been modified during upload or something?

    [/quote]

    Are you sure that your video is rendering correctly? The retropie does bilinear filtering when it upscales, which could be causing the scanlines to blur together. Make sure you follow the instructions for getting proper video rendering, which I linked to in the OP.

    #98183
    patl
    Participant

    Check your Retrench render resolution.
    When you load a rom press “x”, select point “8”
    (Select Retroarch render res for xxx)
    in the menu select point 5
    (Use video Output resolution)

    And be ensure that your display is a 1080p display.
    Otherwise scanline overlay image of patrickm will be downscaled, the scaliness itself blurred and only darken the whole image.

    #98190
    patrickm
    Participant

    [quote=98183]Check your Retrench render resolution.
    When you load a rom press “x”, select point “8”
    (Select Retroarch render res for xxx)
    in the menu select point 5
    (Use video Output resolution)

    And be ensure that your display is a 1080p display.
    Otherwise scanline overlay image of patrickm will be downscaled, the scaliness itself blurred and only darken the whole image.

    [/quote]

    yep, I just tested an overlay that is larger than my screen resolution and it just darkened the whole screen. Render resolution, screen resolution and overlay resolution need to match.

    #98191
    zonitz
    Participant

    Display is 1080p CEA mode 16, RA render output doesn’t matter I tried them all. The preset RA scanline overlay is working but does not look good (only the picture differs between patrickm’s and RA’s from what I could tell by looking). Also the file size differ, 44k for the RA preset .png and 2kb for patricksm’s picture, that’s why im wondering.

    #98192
    patrickm
    Participant

    Are you using video smoothing? That should be disabled. Not sure why the image in the OP isn’t working for you. Did you set overlay_fullscreen to true in the .cfg for the overlay? Here are direct links to the files. It sounds like maybe you downloaded a preview image instead of the fully zoomed version, or something, and that it’s getting scaled improperly and thus blurring the lines together.

    https://www.dropbox.com/s/3e9x8bpu2u0iyug/scanlines1920x1080.png?dl=0
    https://www.dropbox.com/s/88bj4jqgeqzx1c6/scanlines1920x1080-5x.png?dl=0

    #98194
    patl
    Participant

    Video smoothing in the config.cfg doesen’t matter.
    With smooth on, only the emulated image is soft, not the overlay image.
    Probably you really habe the wrong overlay image.

    #98195
    zonitz
    Participant

    The dropbox files worked, something probably got corrupted during attachment.

    Thanks!

    #98205
    patrickm
    Participant

    [quote=98195]The dropbox files worked, something probably got corrupted during attachment.

    Thanks!

    [/quote]

    Glad you got it working, I’ll add the links to the OP

    #98216
    dragonjab
    Participant

    That was the problem that I was having on my previous post. The only thing I was getting was a darker screen but no scanlines. The dropbox attachment fix my problem. @paratrikm have you gotten your 64 games working, if so could you post the settings that you are using. I was playing paper mario earlier, but it just looks terrible, or at least the title screen does. The game is unplayable on my end, even with the rice video plug in.

    #98250
    shadowmoses
    Participant

    Hello, this topic is very great thanks to patrickm!
    I’m a noob here so can you explain how we enter the RGUI (retroarch menu ?).

    I think the keyboard shortcut is not activate in the last retropie version. Do we have to uncommment something somewhere or add a line in a cfg file?

    #98253
    Floob
    Member

    [quote=98250]Hello, this topic is very great thanks to patrickm!
    I’m a noob here so can you explain how we enter the RGUI (retroarch menu ?).

    I think the keyboard shortcut is not activate in the last retropie version. Do we have to uncommment something somewhere or add a line in a cfg file?

    [/quote]

    Press F1.
    If you have a button set to enable hotkeys (like Select), hold that then press F1. (or x on the joypad).

    #98368
    patrickm
    Participant

    update; added a link to a new 1920×1080 scanline overlay. The old one was not correct.

    #98715
    Floob
    Member

    @patrickm

    If I can confirm your settings, I could add it as an option in my new tool here:
    https://github.com/biscuits99/rp-video-manager

    If we just focus on SNES for the moment, then I can apply it to others by largely just updating the resolution settings.

    Can you see if this content in your /opt/retropie/configs/snes/retroarch.cfg achieves what you expect?

    video_shader = /opt/retropie/emulators/retroarch/shader/crt/dotmask.glsl
    video_shader_enable = true
    video_smooth = false
    video_scale_integer = "true"
    aspect_ratio_index = "22"
    input_overlay = /opt/retropie/emulators/retroarch/overlays/effects/scanlines/scanlines1920x1080-5x.cfg
    
    input_overlay_opacity = "1.000000"
    custom_viewport_width = "1536"
    custom_viewport_height = "1120"
    custom_viewport_x = "0"
    custom_viewport_y = "0"
    #include "/opt/retropie/configs/all/retroarch.cfg"

    It would also help if you posted your videomode file:
    /opt/retropie/configs/all/videomodes.cfg

    #99205
    houseoftheed
    Participant

    This scanline method and your scaling info worked amazingly well. Thanks for sharing!

    #99268
    patrickm
    Participant

    [quote=99205]This scanline method and your scaling info worked amazingly well. Thanks for sharing!

    [/quote]

    Thanks for the feedback. Glad it helped.

    #100182
    Anonymous
    Inactive

    Well crt-hyllian and crt-caligari shaders seem to be the best crt scanline shaders that run full speed without hitching BUT you have to set the RetroArch render resolution to 720p, setting it to 1080p has an impact and the fps drop. As setting it to 720p both crt-hyllian and crt-caligari have ever so slight scanline uneven artifacts, enabling integer scaling removes these artifacts but obviously your getting a smaller display area, i know crt-hyllian and crt-caligari were 2 shaders that didn’t need integer scaling enabled to get even scanlines at 1080p+ resolutions.

    Is there a way to have crt-hyllian and crt-caligari shaders for 720p with even scanlines and integer scaling disabled, or a way to compile these shaders for 720p?

    #100200
    patrickm
    Participant

    [quote=100182]

    Is there a way to have crt-hyllian and crt-caligari shaders for 720p with even scanlines and integer scaling disabled, or a way to compile these shaders for 720p?

    [/quote]

    The short answer to both questions is no.

    #100220
    Anonymous
    Inactive

    [quote=100200]

    Is there a way to have crt-hyllian and crt-caligari shaders for 720p with even scanlines and integer scaling disabled, or a way to compile these shaders for 720p?

    The short answer to both questions is no.

    [/quote]

    Guess I’ll have to stick with integer scaling enabled then….odd thing is for Playstation there doesn’t appear to be any artifacts when integer scaling is disabled….I guess that’s because Playstation games have a higher internal render res than snes and genesis games.

    We’ll probably have to wait for the RPi 3 to be able to get these emulators running at full speed, 1080p rendering res and with shaders

    #100225
    Floob
    Member

    Although in the meantime patrickm has provided some great overlays which really do make a big improvement. I’m using overlays instead of shaders now.

    #100228
    Anonymous
    Inactive

    I found the overlays just made the whole picture too dark once applied.

    Which of patrickm’s overlays do you recommended?

    On another note if you set a vertical res of 728 then it seems to remove the scanline artifacts but you lose 4 rows of pixels top and bottom, so slight overscan.

    EDIT: I have just re-read patrickm’s first post and noticed this paragraph….

    “To get perfect scaling (and perfect scanlines), turn integer scale ON (video settings), and set a custom aspect ratio by going to options -> video options -> custom ratio. You may need to turn crop overscan ON or OFF depending on the core being used; crop overscan behaves differently for each core.”

    So even with patrickm’s scanline overlay method he still recommends integer scaling to be enabled?? If so i might as well just keep using crt-hyllian shader, as with that at 720p and integer scaling you get NO artifacts and the scanlines are perfect!!. The only reason i was asking at this shader at 720p was i would prefer not to have integer scaling enable as the display screen is then smaller.

    So in video settings make sure…

    Use Fullscreen Mode………ON
    Windowed Fullscreen Mode….OFF
    Aspect Ratio…………….Core Provided
    Integer Scaling………….ON
    Bilinear filtering……….OFF

    in Options>Shader….

    Select CRT>crt-hyllian-glow>crt-hyllian.glsl

    leave settings as ‘Dont Care’ and the select apply. You get 100% performance with even scanlines and a great authentic CRT look

    #100317
    patrickm
    Participant

    “I found the overlays just made the whole picture too dark once applied.”

    First, make sure you are using the correct overlay for the display resolution and integer scale that you are using.

    Second, you can adjust the overlay strength by adjusting “opacity” under settings -> overlay settings

    Third, you can adjust your LCD’s “backlight” control.

    Fourth, and this should go without saying, but make sure you have calibrated the greyscale and color correctly on your display.

    IMO the best effect is achieved with opacity at 100% and my backlight at 85-100% depending on if I’m using the 5x or 4x overlay. Some might prefer lighter scanlines, though.

    “So even with patrickm’s scanline overlay method he still recommends integer scaling to be enabled?? If so i might as well just keep using crt-hyllian shader, as with that at 720p and integer scaling you get NO artifacts and the scanlines are perfect!!.”

    You can do that but then you are dedicating a huge amount of screen space to letterboxing and overscan:
    1080-720= 360 lines dedicated to letterboxing alone, or 1/3rd of the total vertical area.

    With the right integer scale you can avoid this, or eliminate letterboxing/overscan completely to take full advantage of the display area.

Viewing 35 posts - 71 through 105 (of 119 total)
  • The forum ‘Video Output on RetroPie’ is closed to new topics and replies.