The GLSL shaders are possibly the most complete solution to bringing back the authentic feel and look of old school CRTs when retrogaming via emulation. While there have been a few solutions to this in the past i.e. scanlines, scale2x, scale3x, hq2x, etc none come close to the HLSL shaders (directx) nor GLSL shader (opengl) implementations of current day gaming.

You can try out Mah!Cade a MAME frontend based on Wah!Cade

Default GLSL Enabled Black Tiger Outrun Pac-Man Teenage Mutant Ninja Turtles

~/.mame/osd: CRT-geom_idx16_lut.fsh CRT-geom_rgb32_dir.fsh CRT-geom_rgb32_lut.fsh CRT-geom.vsh makefile shader ~/.mame/osd/shader: genc.sh glsl_bilinear_idx16_lut.fsh glsl_bilinear_idx16_lut.fsh.c glsl_bilinear_rgb32_dir.fsh glsl_bilinear_rgb32_dir.fsh.c glsl_bilinear_rgb32_lut.fsh glsl_bilinear_rgb32_lut.fsh.c glsl_bilinear.vsh glsl_general.vsh glsl_general.vsh.c glsl_plain_idx16_lut.fsh glsl_plain_idx16_lut.fsh.c glsl_plain_rgb32_dir.fsh glsl_plain_rgb32_dir.fsh.c glsl_plain_rgb32_lut.fsh glsl_plain_rgb32_lut.fsh.c glsl_plain.vsh

gl_glsl 1 gl_glsl_filter 1 glsl_shader_mame0 /home/user/.mame/osd/shader/glsl_plain glsl_shader_mame1 /home/user/.mame/osd/CRT-geom

An alternate edit to CRT-geom.vsh has been kindly provided by @p_e_z_z

// overscan (e.g. 1.02 for 2% overscan) overscan = vec2(1.0,1.0); // aspect ratio aspect = vec2(0.1, 0.1); // lengths are measured in units of (approximately) the width of the monitor // simulated distance from viewer to monitor d = 1.0; // radius of curvature R = 1.0; // tilt angle in radians // (behavior might be a bit wrong if both components are nonzero) const vec2 angle = vec2(0.0,0.0); // size of curved corners cornersize = 0.0005; // border smoothness parameter // decrease if borders are too aliased cornersmooth = 2000.0;