Replicating Mednafen's 'Goat' shader in Retroarch

Hey. So, Mednafen’s Goat shader is pretty much exactly what I’m looking for for MegaDrive/Genesis games (and most 16/32-bit consoles), but I can’t seem to replicate it using Retroarch’s shader library. The closest I’ve managed is to use crt-easymode or crt-geom with the geometry turned off and horizontal scanlines turned down, and tweaking some other bits, but it’s just not quite right.

Road Rash II - Mednafen - Goat OpenGL + scanlines (goatron mask pattern)

Road Rash II - Retroarch (Genesis Plus GX core) - crt-easymode

The big difference is that Goat gives a more fuzzy effect, and crt-easymode has an overbright luminescence/bloom.

Are there any existing shaders that can replicate that sweet, sweet Mednafen look in Retroarch?

shaders

i asked this once when goat shader was included. i think @hunterk has best know-how of the shaders

Does anyone have a link for Mednafen’s GOAT shader (the actual code) because that would help alot? I’ve been looking and I can’t find it, their github just has pre-compiled versions of the emulator, which makes this alot more difficult (for a multitude of reasons).

Apologies if this is not what you’re looking for, but I found the Mednafen shader C++ file on the OpenEmu github:

1 Like

Yeahhhhh… That’s close to what I was looking for, it seems like it’s a combo of that link and the shader.h, alongside a couple of files (that I haven’t tried to search for, on mobile and it’s having none of github).

This is over my head though, but having these links makes it easier for anyone thats willing/can to try and port it. Sorry, if I got your hopes up…

@hunterk can I cry about it? lmfao :joy:

So, instead of trying to decode the GOAT shader settings using Mednafen’s C++ & .h files, I went along and changed some parameters of the much-loved crt-easymode to give, what I think, is a lovely replication of the CRT displays I remember in my youth, where individual pixels were visible, and it was less scanline-intensive. I grew up with PAL games, using a big-ass SONY (Grundig? Ferguson?) aperture-grille (Trinitron?) woodgrain CRT television set, where scanlines really weren’t much of a thing, but pixel definition was particularly acute. But I digress.

I use this as a general preset for my arcade and 8/16-bit console emulators.

Arcade cabinet settings:

parameters = "SHARPNESS_H;SHARPNESS_V;MASK_STRENGTH;MASK_DOT_WIDTH;MASK_DOT_HEIGHT;MASK_STAGGER;MASK_SIZE;SCANLINE_STRENGTH;SCANLINE_BEAM_WIDTH_MIN;SCANLINE_BEAM_WIDTH_MAX;SCANLINE_BRIGHT_MIN;SCANLINE_BRIGHT_MAX;SCANLINE_CUTOFF;GAMMA_INPUT;GAMMA_OUTPUT;BRIGHT_BO OST;DILATION"
SHARPNESS_H = "0.500000"
SHARPNESS_V = "1.000000"
MASK_STRENGTH = "0.300000"
MASK_DOT_WIDTH = "1.000000"
MASK_DOT_HEIGHT = "1.000000"
MASK_STAGGER = "0.000000"
MASK_SIZE = "1.000000"
SCANLINE_STRENGTH = "1.000000"
SCANLINE_BEAM_WIDTH_MIN = "1.500000"
SCANLINE_BEAM_WIDTH_MAX = "1.500000"
SCANLINE_BRIGHT_MIN = "0.350000"
SCANLINE_BRIGHT_MAX = "0.650000"
SCANLINE_CUTOFF = "400.000000"
GAMMA_INPUT = "2.000000"
GAMMA_OUTPUT = "1.800000"
BRIGHT_BOOST = "1.200000"
DILATION = "1.000000"

8/16-bit console settings:

parameters = "SHARPNESS_H;SHARPNESS_V;MASK_STRENGTH;MASK_DOT_WIDTH;MASK_DOT_HEIGHT;MASK_STAGGER;MASK_SIZE;SCANLINE_STRENGTH;SCANLINE_BEAM_WIDTH_MIN;SCANLINE_BEAM_WIDTH_MAX;SCANLINE_BRIGHT_MIN;SCANLINE_BRIGHT_MAX;SCANLINE_CUTOFF;GAMMA_INPUT;GAMMA_OUTPUT;BRIGHT_BOOST;DILATION"
SHARPNESS_H = "0.750000"
SHARPNESS_V = "0.750000"
MASK_STRENGTH = "0.500000"
MASK_DOT_WIDTH = "1.000000"
MASK_DOT_HEIGHT = "1.000000"
MASK_STAGGER = "1.000000"
MASK_SIZE = "1.000000"
SCANLINE_STRENGTH = "0.350000"
SCANLINE_BEAM_WIDTH_MIN = "2.000000"
SCANLINE_BEAM_WIDTH_MAX = "1.000000"
SCANLINE_BRIGHT_MIN = "0.250000"
SCANLINE_BRIGHT_MAX = "0.500000"
SCANLINE_CUTOFF = "225.000000"
GAMMA_INPUT = "2.000000"
GAMMA_OUTPUT = "2.000000"
BRIGHT_BOOST = "1.240000"
DILATION = "1.000000"

I’m sorta happy with these settings. They’re not as similar to Mednafen’s Goatron as I’d like, but they hit the aperture-grille nostalgia mark for me, so until such time as the GOAT shader can be 100% recreated in Retroarch, I’ll be using these settings, instead :wink: