decoder-composite-to-svideo

This shader takes a composite signal (like you'd get via a console's composite input) and separates out the luma from the chroma so it is effectively an SVideo signal.

This shader is capable of doing TWO luma/chroma demodulations at once (one to the r and g output channels and one to b and a), for purposes of temporal aliasing reduction.

See Decoding A Fake NTSC Signal for more information.

Index

Input Textures/Samplers

Uniform Buffer Values

Input Textures/Samplers

g_sourceTexture
                g_sourceTexture
              
Type
texture (platform-specific)
Description
The texture to sample.
g_sampler
                g_sampler
              
Type
sampler (platform-specific, does not exist on some platforms)
Description
The sampler to use to sample g_sourceTexture.

Uniform Buffer Values

g_samplesPerColorburstCycle
                uint g_samplesPerColorburstCycle
              
Type
uint
Description

How many samples (texels along a scanline) there are per colorburst cycle (the color wave in the composite signal).

This shader currently assumes that it is integral (hence the int input) but it is totally possible to make the shader support a floating-point value instead - it would just need to do an extra fractional addition of the last texel.