==============================================================================
  A R C T I C   R O B O T S   -   P R O D U C T I O N   W R I T E U P
==============================================================================

  PROD NAME...........: URBAN CYCLES
  TYPE................: Windows 8k Intro
  SIZE................: 8187 bytes
  DURATION............: 210 Seconds (3:30)
  RELEASED............: Black Valley 2026
  PLATFORM............: Windows 11 (might work on Win 10)
  CODE/VISUALS/AUDIO..: Zeko ^ Arctic Robots

==============================================================================
[00] THE CONCEPT & VISUALS
==============================================================================
Urban Cycles is designed as a late night "in-between-programs" filler for
a fictional government-funded national TV station (like the BBC or NRK).

It is inspired by dub music videos on YouTube, which feature monotone
dub music paired with monotone B&W industrial footage.

It is supposed to be timelapse footage of urban locations filmed in 1964,
then turned into the final filler production in 1993.

The visuals use a heavily stylized procedural timelapse system to evoke
the hypnotic rhythm of city life. The aesthetic aims for a raw, early-90s
CRT/VHS broadcast texture.

Everything you see is rendered in real time, packed inside 8187 bytes.


==============================================================================
[01] THE TECHNICALS (VISUALS)
==============================================================================
The demo is all about the shader (OpenGL/GLSL).

There are basically four scenes (with one close-up shot in scene 3).
- The train junction
- The city street
- The downtown plaza
- The harbour

Each scene reuses the same geometry and calculations, with heavy use of
mirroring and repetition, but with variations in size for each cell.

In the downtown plaza there is a bit of extra manually placed
building geometry and outdoor furniture to make the open space a little more
interesting.

The last shot (the harbour) is basically the train junction scene seen from
the side, but with an "if p.x < 0" to add the ocean. The trains are instead
drawn as cars, and the train closest to the camera is drawn as a boat :-)

Instead of linear timing, a lot of stuff is timed on a "sample and hold" basis,
where the time is updated only 15 times a second. This makes for a nice
stuttering, timelapse-like effect. This is most prominent in the clouds.
For shadows and train/car movement I let them move on linear time,
but push/offset them on the beat to create sudden jumps, enforcing the
timelapse feel.

Most elements have some kind of reflection. Most only fake a reflection of the
sky, like all buildings and the ground. I tone down the fake reflections
on vertical surfaces and make them stronger on the roofs.

For the downtown plaza buildings and the water, there are "real" raymarched
reflections mixed with the fake reflection to give the buildings a glass look.

There are two types of smoke (which contributed way too much to the size).
In the first scene there is crude volumetric smoke, whereas the smoke
in the last scene is more traditional 2D billboard-like smoke.

The text is rendered into a texture on the first frame (or rather second,
since the audio is rendered in frame 0). The font is the Windows built-in font
Consolas, but to make it more interesting I stretch and squeeze it on different
coordinates on the screen, so that it looks a bit more like a 1993
low budget TV font.

Crossfades are made by doing two raymarching passes and mixing them, needing
twice as much computing power during the crossfades. However, on my RTX4090
I still get 144 FPS (my target) for the majority of the demo, with some
slowdowns, and only just 80 FPS in the crossfade between the city street
and the downtown plaza.

To finish off the visuals and get that 1993 VHS/CRT look, I do a lot more
post processing than I usually do for size coded demos.

The post processing pipeline is actually very long: CRT curvature,
bezel distortion, horizontal glitch/tear bands, soft focus, phosphor bloom,
flicker, vignette, grain, dust/scratches, scanline modulation, screen glare,
and green-white bloom tint.


==============================================================================
[02] THE TECHNICALS (AUDIO)
==============================================================================
My Mirrors 4k demo was (rightfully) said to have "lackluster audio", so I
wanted to improve on that. But instead of using Sointu (which of course would
have been a viable option) I instead explored shader audio further.

Enter "Dubber", my shader audio composition tool. The idea is that dub music is
very repetitive, but evolves over time. This is perfect for procedurally
generated music, like shader audio.

The music is still repetitive and might still be perceived as boring, but it 
is dub music: boring, maybe, but also hypnotic :-D

My Dubber tool features instruments, delay, side-chaining, LFOs, ARP, tape 
hiss, vinyl crackle and many more features to make repetitive procedural 
music. It even estimates the final crinkled size for all aspects of the song, 
so you can monitor the size impact your musical decisions make as you make the
song. Then Dubber exports the GLSL code to put into the shader of the demo.

The Urban Cycles audio is < 900 bytes (minified and crinkled), generated
by Dubber, and then a few hand tweaks have been made to it afterwards.

Here's a screenshot of Dubber: https://www.arcticrobots.com/gfx/dubber.png
If you want to test it, let me know. If there's interest I'll release it.


==============================================================================
[03] THE TECHNICALS (SIZE)
==============================================================================
As usual code golfing is a bigger part of this than I like. When I was
satisfied with the content I was building at approx 8500 bytes. I expected
that would not be too hard to get down to the 8192 byte limit. It proved a lot
harder than I thought.

After removing low hanging fruit I was still way over
8300 bytes, and starting to think about what content could be removed to
find the final bytes, or just admitting defeat and calling it a 64k :-)

But I didn't want to do either. So I made a size benchmarking script that would
compare the two versions of the code (all minified and crinkled), and began the
hunt for the last bytes. And again I've learned a lot. Most of my ideas for
using less code would instead increase the final size, because they broke the
compression entropy. So I actually ended up "duplicating" a lot of the
code instead of simplifying it, generating repeated tokens for Crinkler to
compress instead of fewer bytes in the shader source.

This was nighttime, deep-concentration, tedious work, and as usual the hours
just disappeared until daylight appeared again and sleep called.

But when I finally broke the 8192 byte limit I was, of course, very satisfied!


==============================================================================
[04] CREDITS (& HAIKU)
==============================================================================
Code, Visuals & Audio-Design: Zeko / Arctic Robots

  "Urban Cycles turn
   windows bloom across the dusk
   trains carry the dark"

  - Arctic Robots (2026) -

See readme.nfo for greetings.

==============================================================================
                             www.arcticrobots.com
==============================================================================
EOF // NO CARRIER
