Skip to content

Instantly share code, notes, and snippets.

@mariodivece
mariodivece / mad-scanlines-crt.glsl
Last active September 11, 2024 07:19
CRT Scanline Effect for Dolphin Emulator
void main()
{
float currentMillis = GetTime() / float(1000.0);
float2 coords = GetCoordinates();
float lineCount = GetWindowResolution().y / 2.0;
// scanlines
int lineIndex = int( ( coords.y + currentMillis * 0.5 ) * lineCount );
#ifdef API_OPENGL
float lineIntensity = mod(float(lineIndex), 2);
@mariodivece
mariodivece / scanlines.glsl
Last active August 17, 2024 15:29
A simple, configurable GLSL scanline effect shader for Dolphin
/*
[configuration]
[OptionRangeFloat]
GUIName = Blur Area
OptionName = BLUR_SIZE
MinValue = 0.0
MaxValue = 10.0
StepAmount = 0.1
DefaultValue = 1.6