glslop
[ CC0 shader vibe commons · everything here is public domain ]
experimental backend WebGL2 · not opted in
Enable WebGPU controls in settings. WebGL2 remains unchanged.
preview clip · live controls are optional about 12s to compile on a fast gpu; slower hardware can take longer. this browser needs the main-thread fallback, which may freeze the page.
params (21)
240.00
1.00
1.00
1.00
5.00
1.25
0.90
3.40
0.30
1.00
9.00
0.00
1.00
1.00
1.00
0.50
0.60
1.00
1.00
0.00
1.00
.fs source · isf not running

Ciggies

#sji87eet
⑂ fork it{ } json

A procedurally generated pack of cigarettes turning on a PlayStation-1 'examine item' screen. It is not a raymarcher wearing a pixel filter: it is a small software rasteriser, and every PS1 artefact comes from doing what the PS1 did. Vertices are projected onto a 240-line screen and ROUNDED to whole pixels, as the GTE handed the GPU integer coordinates, so every corner jumps pixel to pixel as the pack turns and the edges wobble. Each quad is two triangles filled from those snapped corners, with barycentrics taken in screen space and used as they are - no divide by depth - so the textures swim and kink along each quad's diagonal exactly as affine mapping did (the perspective-correct answer is computed too, and a dial blends to it). Texels are point sampled, light is per vertex and MODULATES the texture up to twice as bright, colour is 15-bit, and the ordered dither is the PS1's own 4x4 matrix, floor(bayer/2) - 4 in 8-bit steps. Back-face culling is free: the faces are wound so cross(B-A, C-A) is the outward normal, projection keeps the winding, and a negative screen area is a face turned away. An optional ordering-table mode sorts by one depth per polygon, as the hardware did, instead of per pixel. Each pack comes from one integer: size (king, 100s, compact), a palette, one of five wrap layouts, an emblem, a brand name built from syllables - or, one pack in eight, a house brand the syllables cannot reach - a variant word, a warning, sealed or opened, how many are left, which slots are empty and which cigarettes stand proud. The filters seen down the open lid ARE the count: the twenty slots are taken in the order (a*s + b) mod 20 with a coprime to 20, a slot is still full if its turn is under the count, and the ones standing proud are the next three due, found by inverting the permutation - so the caption, the holes and the raised cigarettes cannot disagree. All of those decisions are exact integer arithmetic carried in floats, every intermediate whole and under 2^24, and all text packs four 5-bit symbols to a float so every divide is by a power of two and exact. The wrap artwork is drawn in millimetres of the CLOSED pack, so the design runs unbroken across the lid cut until the lid swings. Controls: resolution, vertex snap, affine amount, dither, colour depth, texel density, spin, focal length, elevation, camera sway, seconds per pack, seed, lid, pulled cigarettes, key light, gloss, fog, floor, caption, ordering-table sort and exposure.

#cigs#ciggies#cigarettes#smokes#stupid#dumb#moron#coolps1retrorasterizerprocedurallowpoly3ddithergenerator
by ksinwitnessed_generationmade with ClaudeCC0-1.0credit: CC0activecreated 2026-09-13 12:28Z104 views0 forks21 paramsClaude-Opus-5
export clip · render a video in your browser

Renders to video in your browser (no upload), stepping the real renderer frame by frame so multipass + feedback come out right. motion auto-animates the shader's own knobs — each export rolls a fresh take (🎲 re-roll, 🔒 to pin one you like). GIF is slower with a tighter length cap; MP4/WebM are faster. Some devices record in real time (noted below if so) — keep the tab visible.

caps: ≤1920 per side, ≤60fps, ≤18000 frames (GIF ≤300)
embed · drop this shader into any page
preview ↗

Renders client-side in the reader's browser (CC0 — no attribution required, but the backlink is appreciated).