CRT shaders and vertical games

I’m using crt-hyllian-multipass.glslp with libretro-fbalpha and core-provided aspect ratio (DAR). I read that you should use integer scaling with CRT shaders, so I am.

This works quite well for games that use a horizontal 4:3 monitor, and games that have an exact 3:4 raster.

For example, DoDonPachi has a display aspect ratio and pixel aspect ratio of 3:4. It looks OK:

(Click on these images to view them at full size)

It has a bit of rainbow banding, though, which doesn’t seem to be visible in horizontal games, or with the pi-vertical shader.

19XX has a display aspect ratio of 3:4, but the pixel aspect ratio is longer. The game’s pixels are intended to be squashed when played on a CRT. When displayed with any CRT shader and integer scaling, the viewport is small, and the scanlines look odd:

  • I’m better off using non-integer bilinear scaling and scanlines.glsl with the games that look bad, right?
  • Does forcing RetroArch to display the game in its display aspect ratio invalidate integer scaling?
  • Will the distortions go away if I use a higher resolution display?
  • Is there a proper way to stack a shader like sharp-bilinear or pixellate with a CRT shader? Would this help?
  • Am I doing something wrong?

You need integer scaling on the axis perpendicular to the scanline direction. That is, horizontal games have horizontal scanlines, so you need the integer scaling on the vertical axis. Vertical games have vertical scanlines, so you need integer on the horizontal axis. I think the easiest way to do this is to enable a custom aspect ratio with integer scaling enabled and then make the custom aspect ratio height whatever you need to get the most picture and then adjust the width to whatever looks about right. Once you have it looking pretty close, you can disable integer scaling and do fine-tuning, if needed (e.g., if you need to make the screen a little taller/shorter to play nicely with overscan, etc.)

1 Like

Thanks! So, something like this?

672x896 is 3:4.

It results in this:

Just a bit annoying that the picture can’t auto-centre when configured in this way.

yeah, having to center it manually is a drag. I think for 19XX, I would make it one tick wider and taller with integer (i.e., bleed off the screen a bit) and then disable integer and reduce the height until the rainbowing goes down.

That needs more than 1100 pixels vertical resolution, yeah? It’s for playing in windowed (1600x960) on a 1080p monitor.

yeah. I typically play with a little bit larger viewport than my screen. It’s harder on arcade games, where overscan compensation wasn’t factored in by the programmers, though.