All effects

colour = f(scanline)

Raster bars.

1977 to today

The oldest trick in the book: change a colour register at exactly the right moment while the electron beam sweeps the screen. No pixels drawn, just perfect timing, line after line.

8-bit16-bitPCGPU

How it works

The algorithm

A raster bar is a colour gradient that belongs to scanlines, not to pixels. For each line of the screen, decide which bar covers it (bars move on sine curves, nearer ones drawn last) and set the background colour for that line. Kefrens bars are a different beast: one line buffer that is never cleared, so every scanline adds a small bar and shows the accumulated result.

The old-hardware trick

On the C64 a raster interrupt fires at a chosen line and the code rewrites the border colour register, timed to the cycle. The Amiga's Copper co-processor runs a tiny program in sync with the beam: ‘wait for line 100, set colour 0 to $F80’, free bars without using the CPU. The Atari 2600 had no frame buffer at all, so every game raced the beam.

Per frame, in pseudo-code
on every scanline y:            // raster interrupt / copper
  c = background
  for bar in bars sorted by depth:
    if |y − bar.y(t)| < bar.size / 2:
      c = bar.gradient[y − bar.top]
  COLOR0 = c                     // written as the beam passes

// Kefrens bars: line buffer is never cleared
  draw_bar(linebuffer, x = sine(y, t))
  show(linebuffer) on line y

Timeline

Documented milestones, with a source for each. Famous examples, not claims of who did it first.

  1. 19778-bit

    Racing the beam

    Atari 2600 programmers · Atari 2600

    The console has no frame buffer: programs set colours while the beam draws each line. Raster-bar-style colour changes were part of the hardware's everyday reality, on the 2600 and on Atari's 8-bit computers.

    Source
  2. 1980s8-bit

    C64 raster interrupts

    C64 coders · Commodore 64

    A raster interrupt at a chosen scanline lets code rewrite the border or background colour register mid-frame, gradients without touching a single bitmap byte.

    Source
  3. 198516-bit

    The Copper

    Commodore Amiga · Amiga OCS

    The Amiga's Copper co-processor executes a list of ‘wait for beam position, write register’ instructions in sync with the display. Copper bars cost the CPU nothing.

    Source
  4. 198916-bit

    Alcatraz bars

    Alcatraz · Megademo 3 · Amiga

    The ‘We Are First’ part shows the vertical curtain of bars built line by line from a buffer that is never cleared, known to most as Kefrens bars.

    Source
  5. 199016-bit

    Copper Master

    Angels · Amiga OCS/ECS

    A whole production dedicated to Copper effects. Its preservation notes describe timing repairs, proof of how tightly these effects hung on display timing.

    Source
  6. 19928-bit

    Kefrens bars on the Plus/4

    Rachy, TPSH, LBM · 48 Hours Party · Commodore Plus/4

    Part 3 is explicitly labelled ‘Kefrens Bars’: the effect migrates from the Amiga to another 8-bit architecture.

    Source
  7. 1997PC

    Copper bars in 256 bytes

    XtaC / Garbage · MS-DOS

    Without any display co-processor, the PC packs the look into a 256-byte intro: executable size, not hardware, becomes the constraint.

    Source
  8. 2021GPU

    Raster bars as a shader

    reilar · GLSL · KodeLife / Shadertoy

    The appearance rebuilt from pure shader arithmetic, no longer timed to a physical CRT beam.

    Source

Over time

5 live versions, from the oldest platform to today: 4 on the CPU, 1 on the GPU. Retro versions run at their original resolution and palette. Demos pause when off screen.

Atari 2600 · 160×192

Racing the beam

1977

Every scanline gets its own background colour from the 128-colour NTSC palette, and a mirrored 20-block playfield is reprogrammed on the fly, there is no frame buffer to draw into.

8-bitCPUno frame bufferplayfield
Detail page
C64 · raster IRQ

Border rasters

1980s

Five classic C64 colour ramps race through the border while BASIC sits there, READY. The screen is untouched: only the border colour register changes per line.

8-bitCPU$D02016 colours
Detail page
Amiga · Copper

Copper bars

1985

Seven 12-bit gradient bars on sine paths, depth-sorted so they pass behind each other, mirrored in a wobbling copper floor.

16-bitCPU12-bit colourcopper list
Detail page
Amiga · line buffer

Kefrens bars

1989

One 320-pixel line buffer that is never cleared. Each scanline stamps a 16-pixel bar at a sine-driven x and shows the buffer, the curtain builds itself.

16-bitCPUAlcatraz barsnever cleared
Detail page
GPU · GLSL

Neon rasters

2021

The same bars as a fragment shader: additive glow, a reflective floor, scanlines and CRT curvature, the beam simulated instead of raced.

GPUGPUglowCRT
Detail page