Full-size demo gallery

Every example at full size, linked from the example catalog's preview thumbnails. Every GIF here is committed. They are regenerated by bb record, a maintainer-only task driving a screen-capture tool that is not publicly released; the per-example capture settings and input timelines live in scripts/demo_manifest.edn.

๐ŸŽฎ Original games (9)

hello-world

the minimal raylib window + text (Q exits, F1 toggles debug stats)

hello-world

pong

two-paddle classic, P1 (W/S) vs P2 (K/J)

pong

asteroids

the classic vector shooter (rotate/thrust/fire)

asteroids

asteroids2

an alternate asteroids build (rotate/thrust/fire)

asteroids2

tetris

the block-stacking puzzle (move/rotate/drop)

tetris

vampire-survivors

auto-fire survival: move (WASD), waves chase you

vampire-survivors

snake

the classic snake (arrow keys, grow, don't crash)

snake

floppy

flap through the pipe gaps (SPACE)

floppy

retro-maze-3d

a GameBoy-style 3D maze escape (WASD + mouse look)

retro-maze-3d

๐Ÿ“ฆ Core (37)

bouncing-ball

a ball bouncing around the window (SPACE pauses, G toggles gravity)

bouncing-ball

following-eyes

two eyes track the mouse

following-eyes

screen-manager

a LOGO/TITLE/GAMEPLAY/ENDING state flow (ENTER advances)

screen-manager

input-keys

steer a ball with the arrow keys

input-keys

input-mouse

a ball follows the mouse; click to recolor

input-mouse

input-gamepad

a live gamepad axis/button readout

input-gamepad

mouse-wheel

scroll a box with the mouse wheel

mouse-wheel

gestures-testbed

a testbed for raylib's touch/click gesture detection

gestures-testbed

scissor-test

a scissor rectangle clips a grid (S toggles, mouse moves it)

scissor-test

random-values

a new random value every two seconds

random-values

camera-2d

a 2D camera over a scene (arrows pan, A/S rotate, wheel zooms)

camera-2d

camera-3d-free

a free-orbit 3D camera (mouse look, wheel zoom)

camera-3d-free

split-screen-3d

two 3D viewports, one per player (W/S, UP/DOWN)

split-screen-3d

first-person-3d

a first-person camera walkthrough (WASD + mouse, 1-4 switch modes)

first-person-3d

camera-fps

an FPS camera with jump/crouch physics (WASD, Space, Ctrl)

camera-fps

world-screen

project 3D world points to 2D screen space (mouse, wheel)

world-screen

picking-3d

click to raycast and pick a 3D cube

picking-3d

collision-area

AABB collision between two boxes (mouse moves, SPACE)

collision-area

colors-palette

every named raylib color in a grid (hover, SPACE)

colors-palette

logo-anim

the raylib logo animating in (R replays)

logo-anim

window-should-close

intercept the close button with a Y/N confirm

window-should-close

camera-2d-platformer

5 platformer camera-follow styles (SPACE cycles, C/R/wheel)

camera-2d-platformer

window-letterbox

resolution-independent rendering via letterboxing (SPACE, resize)

window-letterbox

camera-2d-split-screen

two players, two cameras, one grid (P1 W/S/A/D, P2 arrows)

camera-2d-split-screen

camera-3d-mode

a minimal 3D scene, one cube on a grid

camera-3d-mode

delta-time

frame-rate independent vs fixed-step motion (wheel changes the FPS cap, R resets)

delta-time

input-gestures

a running log of detected touch gestures (click, drag, or flick in the test area)

input-gestures

input-multitouch

a numbered circle per touch point

input-multitouch

input-virtual-controls

an on-screen D-pad (click the pad)

input-virtual-controls

keyboard-testbed

an on-screen ENG-US keyboard that lights up as you press keys (hover highlights a key)

keyboard-testbed

render-texture

a bouncing ball drawn into an offscreen target, then blitted

render-texture

smooth-pixelperfect

a pixel-aligned world viewed through a sub-pixel smooth camera

smooth-pixelperfect

storage-values

save and load values to a file (R randomises, ENTER saves, SPACE loads)

storage-values

undo-redo

a ring-buffer undo history on a grid (arrows move, SPACE recolours, CTRL+Z / CTRL+Y)

undo-redo

viewport-scaling

six ways to fit a fixed-resolution game onto a resizable window (click < > to change resolution and mode)

viewport-scaling

input-actions

a box steered through an action layer, so WASD and the arrow keys can drive the same actions (TAB swaps keysets)

input-actions

clipboard-text

cut, copy and paste against the system clipboard, by button or by CTRL+X / CTRL+C / CTRL+V

clipboard-text

๐Ÿ”ท Shapes (28)

logo-raylib

the raylib logo built from rectangles + text

logo-raylib

logo-raylib-anim

the logo animating together, piece by piece (R replays)

logo-raylib-anim

basic-shapes

circles, rectangles, triangles, polygons + an rlgl triangle

basic-shapes

rectangle-scaling

drag the bottom-right corner to resize a rectangle

rectangle-scaling

mouse-trail

a fading trail follows the cursor

mouse-trail

lines-bezier

a cubic bezier curve, drag the endpoints

lines-bezier

easings-ball

a ball animating along an easing curve (ENTER replays)

easings-ball

ball-physics

grab, throw, and resize bouncing balls (click, right-click, wheel)

ball-physics

simple-particles

water/smoke/fire particle effects (arrows switch, click emits)

simple-particles

dashed-line

a dashed line follows the mouse (arrows, C)

dashed-line

starfield-effect

a 3D starfield flying toward the camera (SPACE, wheel)

starfield-effect

easings-box

a grid of boxes, each on a different easing curve (SPACE resets)

easings-box

double-pendulum

chaotic double-pendulum motion + trail

double-pendulum

lines-drawing

click-drag to paint a rainbow fan of thick lines

lines-drawing

easings-rectangles

a grid of rectangles animating on easing curves (SPACE replays)

easings-rectangles

bullet-hell

rows of bullets fired from a rotating circle (ENTER switches between texture and circle drawing)

bullet-hell

clock-of-clocks

digits drawn from a grid of analogue clocks (SPACE toggles 12/24h)

clock-of-clocks

easings-testbed

all 28 easing curves, one per axis (arrows pick the curves, ENTER plays)

easings-testbed

ellipse-collision

steer one ellipse into another (A/B switch which one the mouse drives)

ellipse-collision

math-angle-rotation

fixed and sweeping angle lines

math-angle-rotation

penrose-tile

an L-system Penrose tiling drawn by turtle (UP/DOWN change the generation count)

penrose-tile

circle-sector-drawing

a circle sector with its angles, radius and segment count on sliders

circle-sector-drawing

kaleidoscope

mouse strokes repeated around six-fold symmetry and mirrored (< and > step through the stored lines)

kaleidoscope

recursive-tree

a binary tree grown by splitting each branch in two (sliders set the angle, length, decay and depth)

recursive-tree

ring-drawing

a ring with its radii, angles and segment count on sliders, and three draw modes to overlay

ring-drawing

rounded-rectangle-drawing

a rounded rectangle with its corner roundness, size and outline thickness on sliders

rounded-rectangle-drawing

hilbert-curve

a Hilbert curve drawn stroke by stroke, hue cycling along its length (a spinner sets the order)

hilbert-curve

math-sine-cosine

the unit circle animated, with sine, cosine, tangent and the related angles drawn against it

math-sine-cosine

๐Ÿ“ Text (3)

writing-anim

a message types itself out (SPACE speeds up, ENTER restarts)

writing-anim

format-text

padded score + MM:SS timer readouts

format-text

input-box

type into a text box (click to focus, Backspace to edit)

input-box

๐Ÿ–ผ๏ธ Textures (4)

background-scrolling

a parallax-scrolling background

background-scrolling

sprite-animation

a spritesheet character walk cycle (LEFT/RIGHT)

sprite-animation

srcrec-dstrec

source and destination rectangles with rotation applied

srcrec-dstrec

tiled-drawing

one patch of a texture atlas tiled across the window, with the pattern, tint, scale and rotation all selectable

tiled-drawing

โœจ Shaders (3)

basic-lighting

dynamic per-pixel lighting (mouse moves it, Y/R/G/B toggle lights)

basic-lighting

ascii-rendering

the scene rendered to an offscreen target, then post-processed into ASCII glyphs (arrows resize the cells)

ascii-rendering

palette-switch

eight near-black bands that a fragment shader remaps through a palette, so the colour on screen is never drawn by the program

palette-switch

๐Ÿ”Š Audio (4)

audio-module

a music-driven waveform/spectrum visualizer

audio-module

sound-loading

load and play a WAV/OGG sound effect (SPACE, ENTER)

sound-loading

music-stream

stream an MP3 with play/pause/seek (SPACE, P, arrows)

music-stream

sound-multi

fire the same sound multiple times, overlapping (SPACE)

sound-multi

๐Ÿ—ฟ Models (25)

geometric-shapes

3D primitive shapes on display

geometric-shapes

waving-cubes

an NxN grid of cubes rippling in 3D

waving-cubes

box-collisions

a player cube colliding with 3D boxes (arrow keys)

box-collisions

orthographic-projection

perspective vs orthographic (SPACE toggles)

orthographic-projection

tesseract-view

a rotating 4D hypercube projected to 2D

tesseract-view

solar-system

Sun/Earth/Moon orbiting via the rlgl matrix stack

solar-system

spinning-cubes

a row of cubes, each spinning with a color-cycling phase offset

spinning-cubes

point-cloud

~1500 points forming a rotating sphere (UP/DOWN adjusts)

point-cloud

wireframe-shapes

pyramid/octahedron/torus/helix in 3D lines (SPACE cycles)

wireframe-shapes

camera-modes

Free/Orbital/FPS camera modes (1/2/3 switches, WASD)

camera-modes

ray-picking

click to select cubes via ray-picking

ray-picking

bouncing-spheres

spheres bouncing inside a 3D box (SPACE, R, G)

bouncing-spheres

rotating-cube

a single cube spinning via the rlgl matrix stack (arrows, +/-, R)

rotating-cube

particle-system

a 3D particle emitter (SPACE bursts, G toggles gravity, W/R reset)

particle-system

dna-helix

a rotating double-helix structure (arrows, SPACE, R)

dna-helix

first-person-maze

walk a 3D maze in first person (WASD + mouse, M for map)

first-person-maze

yaw-pitch-roll

yaw/pitch/roll rotation on a 3D model (arrows, SPACE, R)

yaw-pitch-roll

lissajous-3d

3D Lissajous parametric curves (1-5 picks a pattern, W/S, SPACE)

lissajous-3d

lorenz-attractor

the Lorenz attractor's chaotic butterfly path (1-3, arrows, SPACE, R)

lorenz-attractor

terrain-generation

procedurally generated terrain (1-3 picks an algorithm, G, W, SPACE)

terrain-generation

mesh-generation

procedurally generated 3D meshes (Left/Right cycles, click, SPACE, R)

mesh-generation

basic-voxel

an 8x8x8 block of cubes walked in first person, with left-click removing the one under the crosshair

basic-voxel

billboard-rendering

two alpha billboards that always face the camera, drawn far-to-near so the transparency blends correctly

billboard-rendering

cubicmap-rendering

a 3D maze built from a 32x16 PNG, one cube per non-black pixel, textured from an atlas (P pauses the orbit)

cubicmap-rendering

heightmap-rendering

terrain generated from a greyscale PNG, each pixel's brightness read as an elevation

heightmap-rendering