Analysis model: gpt-5.5 xhigh
Unleashed Power by Surprise! Productions - Technical Dissection
Scope
Unleashed Power is a 1993 MS-DOS demo by Surprise! Productions. The release
text says it was released at TCC in Goteborg around May 30, 1993, and the
Computer Crossroad 1993 results list places it fourth in the PC demo compo,
behind Crystal Dream 2, Lunatic, and Mayday.
Public references:
- Scene.org archive: https://archive.scene.org/pub/parties/1993/computer_crossroad93/demo/unleaspo.zip
- Scene.org TCC 1993 results: https://archive.scene.org/pub/parties/1993/computer_crossroad93/results.txt
- Scene.org TCC 1993 demo directory: https://archive.scene.org/pub/parties/1993/computer_crossroad93/demo/
- Demozoo TCC 1993 party page: https://demozoo.org/parties/428/
This writeup is based on the scene.org archive, the bundled release text, PKLITE expansion with UNP under DOSBox-X, file layout inspection, and static 16-bit disassembly. It is not a source-level rebuild, but the executable parts are open enough to describe the actual VGA and geometry inner loops in useful detail.
Old private contact listings from the release text are deliberately omitted.
Release Notes And Requirements
UNLPOWER.TXT gives the basic runtime target:
- Release year: 1993.
- Machine: 286 or newer, with a warning that some sections may effectively expect a 386.
- Video: register-compatible VGA.
- Memory: about 530 KB free conventional memory.
- Audio: Sound Blaster, Covox, or simple DAC output.
The same text explains that the demo had originally been intended for another party where the demo compo was cancelled. The final archive is therefore a multi-part real-mode trackmo rather than one monolithic executable.
Examined Files
Archive hash:
d17500839aeb2afddac91a10f5bc5007456e623f61f35ba784e629a07bbfd88e unleaspo.zip
Extracted files:
LOADER.EXE 3664 bytes MZ executable
UNLPOWER.000 23286 bytes PKLITE-packed MZ executable
UNLPOWER.001 63880 bytes MZ executable
UNLPOWER.002 36432 bytes ProTracker M.K. module, title "Intro1"
UNLPOWER.003 277954 bytes PKLITE-packed MZ executable
UNLPOWER.004 48506 bytes ProTracker M.K. module, title "Another score"
UNLPOWER.005 345825 bytes MZ executable
UNLPOWER.006 109362 bytes ProTracker M.K. module, title "fastblast"
UNLPOWER.007 14151 bytes PKLITE-packed MZ executable
UNLPOWER.008 31280 bytes ProTracker M.K. module, title "ag"
UNLPOWER.009 26240 bytes data
UNLPOWER.010 45120 bytes data
UNLPOWER.TXT 1439 bytes release text
FILE_ID.DIZ 56 bytes short release description
The four module files line up with the executable sections:
UNLPOWER.001 -> UNLPOWER.002
UNLPOWER.003 -> UNLPOWER.004
UNLPOWER.005 -> UNLPOWER.006
UNLPOWER.007 -> UNLPOWER.008
UNLPOWER.009 and UNLPOWER.010 are not MZ files or modules. Their sizes are
interesting: 26240 = 320 * 82 and 45120 = 320 * 141, which fits raw or
lightly packed screen material used by the later parts.
Extracted hashes for the main files:
e7d90556f4d233614d77cecab2914da310ab8822e7ae8a1f9fb9759398241cac LOADER.EXE
4b10de20d1e4a683dfe406b6357f90bfda1d3cdcc9ca745185d407ecadb1616b UNLPOWER.000
60c8937d037564d209cbb3e88ccf1734b02e8398bf33e3067c51a4bfc01a31d2 UNLPOWER.001
3420efd2caf0817d05d87e5f704ab006a5ea979f815de55a0f7296bdcb6918ac UNLPOWER.003
85b3dc492c65eeca6f2150d3f149d296365664df36f2403fbce5206b0e913da2 UNLPOWER.005
43388dd1a3c531cbd1e35380a2506a4b9c81decb0cc41d8f547add47604e815b UNLPOWER.007
UNP-expanded hashes:
f36c14171cd125df31488cf196659b8ee510fe44e01c903d85db1b3dd1f2e857 UP000.EXE
5509903c5c000c6eab51c98c7c3fb42fda6072d9fd16066a26e64b7a17f1d262 UP003.EXE
9c9c1fd4d1567b53f15d4164d6a586f70e7dd647e33dfe1e9b6266b9d59b81e5 UP007.EXE
The ZIP timestamps are not reliable evidence. Several entries carry obviously bogus DOS dates, while others sit around April and May 1993.
Executable Chain
LOADER.EXE embeds the five executable filenames:
unlpower.000
unlpower.001
unlpower.003
unlpower.005
unlpower.007
The loader is a small Borland-style MZ program. Its main job is to execute each part as a child process and preserve enough DOS interrupt state between parts that the trackmo behaves like one production.
The key loader routine is around LOADER.EXE+0x7dc..0x7f8:
mov ax,4b00h
int 21h
That is DOS EXEC. Around it, the loader builds the file parameter block and
path buffer for the selected child executable. The surrounding loops at
+0x819, +0x8a9, and +0x9fd walk a 0x13-entry interrupt-vector table,
saving and later restoring vectors. The old vectors are stored in a table near
file offset 0x26a.
The effect is simple but important: this is not one huge engine. It is a sequence of independent executables with shared conventions: GoldPlay setup, VGA mode setup, external module loading, and a return to the loader.
MZ And Expansion Layout
The packed parts use PKLITE. UNP reconstructs usable MZ images for static inspection:
| File | Image bytes | Header bytes | Relocs | Entry | Entry file offset |
|---|---|---|---|---|---|
LOADER.EXE |
3664 | 144 | 27 | 0000:0042 |
0x00d2 |
UP000.EXE |
260708 | 512 | 14 | 35a9:0c97 |
0x36927 |
UNLPOWER.001 |
63880 | 512 | 11 | 0000:2c86 |
0x2e86 |
UP003.EXE |
473924 | 512 | 35 | 68ac:1fc8 |
0x6ac88 |
UNLPOWER.005 |
345825 | 512 | 43 | 10fe:18cd |
0x12aad |
UP007.EXE |
60606 | 512 | 9 | 0000:0fd9 |
0x11d9 |
The repeated shape is typical early 1993 PC demo engineering: real-mode segments, Mode X, direct VGA ports, external Amiga-style modules, and small part-specific engines instead of a single protected-mode runtime.
Audio Runtime
The executable strings identify GoldPlay 1.00 in multiple parts. The setup menus and part entries write sound parameters into a small low-memory handoff area and then call far routines in the GoldPlay code.
For example, UNLPOWER.001 writes choices into variables at ES=02d6h,
including words near [095a], [095c], [0960], and [0962]. UP003 and
UNLPOWER.005 also read the same timer/audio fields after checking a word at
physical offsets around 04f0h..04f6h. When no prior timing state exists, the
parts program the PIT directly:
out 43h, 24h
out 40h, reload_word
The music path is therefore split in two layers:
- Each visual executable loads its own ProTracker module.
- GoldPlay supplies PIT/audio timing state that the visual code can read for delays and section changes.
That is why many visual loops divide a local tick value by the GoldPlay/PIT rate word before deciding whether enough time has elapsed.
Common VGA Model
Most parts start from BIOS mode 13h and then unchain the VGA memory model into a Mode X-like planar layout. The common recipe is:
mov ax,0013h
int 10h
; Sequencer memory mode: disable odd/even style access and alter chain mode.
mov dx,03c4h
mov al,04h
out dx,al
inc dx
in al,dx
and al,0f7h
or al,04h
out dx,al
; Graphics mode / misc registers: planar write semantics.
mov dx,03ceh
...
; CRTC Offset = 0a0h, so one scanline is 160 bytes per plane page.
mov dx,03d4h
mov al,13h
mov ah,0a0h
out dx,ax
The 320-pixel line width appears as 0x140. In planar mode that often means
80 byte positions, one byte per four pixels across the planes, but these parts
also use 0x140 as a convenient page/row stride when copying already separated
plane material.
The second recurring trick is a low-byte CRTC start swap:
mov dx,03d4h
mov al,0dh
out dx,al
inc dx
mov al,00h or 50h or a0h or f0h
out dx,al
Changing CRTC start lets the part display a different 64K window offset without
copying the entire frame. The code usually wraps this around a retrace wait on
port 03dah bit 3.
Part 1: UP000.EXE
UNLPOWER.000 is PKLITE-packed in the archive and expands to UP000.EXE. It
is the first substantial visual part, and it already contains the key idioms
that reappear later: retrace waits, whole-DAC palette math, Mode X setup, page
swapping, and four-plane blitters.
Retrace Wait Helpers
At UP000.EXE+0x35c97..0x35cb2 there are four tiny polling loops:
mov dx,03dah
in al,dx
test al,08h
je wait_until_vretrace_set
mov dx,03dah
in al,dx
test al,08h
jne wait_until_vretrace_clear
mov dx,03dah
in al,dx
test al,01h
jne wait_until_display_bit_clear
mov dx,03dah
in al,dx
test al,01h
je wait_until_display_bit_set
Bit 3 is vertical retrace. Bit 0 is the display-enable/status bit. The palette writers use these loops to place visible color changes at stable times.
Screen Clear
At UP000.EXE+0x35cbb:
mov ax,0a000h
mov es,ax
mov cx,7d00h
xor di,di
xor ax,ax
rep stosw
0x7d00 words is exactly 64000 bytes. That is the mode 13h visible aperture,
but in the later unchained mode it is still a fast way to clear the currently
selected window.
Full DAC Upload
At UP000.EXE+0x35d34:
mov dx,03c8h
xor al,al
out dx,al ; start at palette index 0
inc dx ; 03c9h data port
mov cx,0300h
again:
mov al,[si]
out dx,al
inc si
loop again
0x300 bytes is 256 RGB triples. The code keeps the palette in normal
6-bit-per-channel VGA form and streams it straight to the DAC.
Grayscale Conversion
At UP000.EXE+0x35d75 the part converts a palette in place:
mov cx,0100h
entry:
xor ax,ax
add al,[si+0]
add al,[si+1]
add al,[si+2]
mov bl,03h
div bl
mov [si+0],al
mov [si+1],al
mov [si+2],al
add si,3
loop entry
This is the literal (r + g + b) / 3 grayscale transform. It is not a table
lookup; it spends the divide because the operation happens per transition, not
per pixel.
Palette Fade In And Fade Out
At UP000.EXE+0x35da6, BL ramps from 0 to 0x80. Each DAC component is:
scaled = (component * BL) >> 7
The third component is delayed until the display-status bit reaches the desired
phase, which stretches the visible fade. The fade-out at +0x35de2 uses the
same math with BL descending from 0x81 to zero. The fade-out uses seven
single-bit shifts instead of shr ax,7, a common 286-compatible style.
Palette Morph
At UP000.EXE+0x35e1a, the part blends two palettes:
out = src + ((src - dst) * step) / 128
BL is the step. The loop visits all 0x300 DAC bytes and calls a status wait
inside the byte loop, making the morph deliberately slow and smooth.
Mode X Setup
At UP000.EXE+0x36486:
mov ax,0013h
int 10h
; sequencer and graphics bits rewritten
; CRTC offset register 13h = 0a0h
mov ax,0a000h
mov es,ax
xor di,di
mov cx,8000h
xor ax,ax
rep stosw
The 0x8000 word clear spans 128 KB of the VGA aperture across the unchained
planes. That is larger than a single 64 KB mode 13h frame and matches the use
of hidden pages.
Page Swap
At UP000.EXE+0x3679b..0x367ea, the part toggles display base state:
wait_vretrace
mov dx,03d4h
mov al,0dh
out dx,al
inc dx
mov al,00h or 0a0h
out dx,al
It also swaps internal base offsets stored near cs:0e65 and cs:09bd, so
the draw code writes to the nonvisible page while the CRTC shows the other one.
Raw Chunky-To-Planar Blitter
At UP000.EXE+0x36816, the part copies a 320 by 200 chunky source into VGA
planes:
mov es,0a000h
mask = 1
for plane in 0..3:
out 03c4h, 0200h | mask
for y in 0..199:
for xbyte in 0..79:
al = *si
si += 4
if al != 0fh:
es:[di] = al
di++
di += 320 - 80
mask <<= 1
The lodsb followed by add si,3 is the giveaway: the source is laid out as
interleaved chunky pixels, and each pass extracts one of the four VGA planes.
Color 0x0f is treated as transparent.
Textured Span Kernel
The most interesting early inner loop is at
UP000.EXE+0x366a0..0x36767. It draws stepped horizontal spans in planar VGA:
di = (y / 2) * 320 + (x >> 2) + page_base
mask = plane_table[x & 3]
Then each plane is drawn by writing Sequencer Map Mask index 2:
mov dx,03c4h
mov al,02h
mov ah,mask
out dx,ax
The inner sampler uses a fixed-point accumulator:
for each byte column:
bx = dx
bx &= 7fffh
bx >>= 6
bl = [bx + si]
es:[di] = bl
di++
dx += bp
When the plane mask moves past 8, it wraps to 1 and the base byte offset is
advanced. This is a classic real-mode VGA texture/span loop: one accumulator,
one source table, direct plane selection, and no per-pixel BIOS calls.
Part 2: UNLPOWER.001
UNLPOWER.001 is a plain MZ executable. It contains the sound setup menu and a
polygon/object section using Mode X pages.
Startup And Setup Menu
The entry offset is 0x2e86. Early code checks CPU capability and exits with
a short message if the CPU is too old. It then shrinks its DOS memory block
with int 21h, ah=4ah.
The menu is text-mode based. At UNLPOWER.001+0x1c42:
mov es,0b800h
mov cx,07d0h
rep movsw
0x7d0 words is an 80 by 25 text page. The menu highlight routine at
+0x1c4f computes:
text_offset = row * 0xa0 + 0x500 + centered_x * 2
Then it walks character cells, preserves the character byte and low attribute nibble, and ORs a new high-nibble color. It is a clean text-mode attribute writer, not a redraw of the whole menu.
16-Color Palette Fade
The setup screen uses only 16 colors. At +0x1b64, the code writes 0x30
bytes to the DAC. Fade-in and fade-out at +0x1b80 and +0x1ba9 multiply
each of the 48 channel bytes by a ramp in BL. This is the same math as the
full 256-color fades, just limited to the text/menu palette.
Page Setup
At +0x1f4c, the part configures planar writes, selects all four planes, and
fills part of A000:
mov es,0a000h
mov di,2c10h
mov cx,69f0h
mov ax,0ffffh
rep stosw
Then it sets the CRTC start registers from a variable near 0x2c10. The page
swap routine at +0x1f8b swaps two offsets, derives an A000 segment from
offset >> 4, waits for display status, and writes CRTC registers 0ch and
0dh.
Mask/Polygon Fill
At +0x1ffb..0x2092, the part reads records containing y and x extents,
clips them, converts x coordinates to byte columns with shr 3, and fills
planar mask bytes:
for each span:
byte_x0 = x0 >> 3
byte_x1 = x1 >> 3
width = byte_x1 - byte_x0
di = page + y * 50h + byte_x0
al = 0ffh
rep stosb
One byte represents eight pixels in this specific mask buffer. The later VGA state determines which color/plane logic turns those bits into visible pixels.
3D Transform And Visibility
At +0x2d6a..0x2df7, vertices are transformed by a 3x3 fixed-point matrix.
The code repeatedly does signed imul, takes the high word as the scaled
result, and stores projected screen pairs:
screen_x = 0x140 + (x * 0x02bc) / z
screen_y = 0x00aa + (y * 0x02bc) / z
At +0x2df8..0x2e3f, each face is culled by the signed area of three screen
points. Nonvisible faces are skipped by advancing SI over the polygon
record. Visible faces are copied with rep movsw into the draw list.
The main loop around +0x2f06 is:
flip visible page
clear or prepare draw page
transform vertices
cull faces
draw visible records
poll port 60h for ESC
repeat
Part 3: UP003.EXE
UNLPOWER.003 expands to a large MZ image. It loads UNLPOWER.004 and uses
the same GoldPlay timing model, but visually it is a more table-driven logo and
strip section than a full polygon part.
Entry And Mode Setup
The entry at UP003.EXE+0x6ac88 starts by shrinking memory, saving the
previous video mode, reading audio/timer handoff fields, and optionally setting
a PIT reload when no handoff exists. Then it hooks keyboard IRQ 9, enters mode
13h, and unchains VGA:
mov ax,0013h
int 10h
; sequencer memory mode rewrite
; graphics mode and misc register rewrite
; CRTC underline/word mode bits
mov es,0a000h
xor di,di
mov cx,8000h
xor ax,ax
rep stosw
mov dx,03d4h
mov al,13h
mov ah,0a0h
out dx,ax
That is the same 128 KB planar clear and 160-byte CRTC offset strategy as
UP000.
Four-Plane Strip Copier
The core copier begins at UP003.EXE+0x6a3d3. It stores source/destination
parameters in cs:0309..0311, selects A000, and then writes each plane
separately:
mov ax,0a000h
mov es,ax
mov dx,03c4h
mov al,02h
mov ah,01h
out dx,ax
For the first plane it derives:
si = table_1[source_index] + source_segment_base
di = table_a[destination_index] + page_offset + local_offset
Then each row copies every fourth byte:
row:
cx = width >> 2
copy:
movsb
add si,3
loop copy
si += 0140h - width
di += 0140h - (width >> 2)
The same block repeats for masks 2, 4, and 8, using different table
bases. In other words, the source is chunky or interleaved, but the destination
is planar; four passes extract the four pixel phases.
Palette And Timing Loop
At +0x6a852..0x6a8d1, the code fades a 768-byte palette down one unit at a
time:
for each active channel byte:
if [si] != 0:
dec byte [si]
changed = 1
upload 0x300 DAC bytes
if changed:
repeat
Before the decrement pass it waits through two retrace cycles. After each pass
it writes the full palette to 03c8h/03c9h.
Timed Slide/Page Sequence
At +0x6a900..0x6a9c6, the part waits until a GoldPlay/PIT-derived count
reaches a threshold, then draws 50 rows of 64 bytes:
for row in 0..49:
for col in 0..63:
al = [si]
es:[di] = al
es:[di+0140h] = al
es:[di+0280h] = al
es:[di+03c0h] = al
si++
di++
si += 0100h
di += 04c0h
Each source byte is expanded vertically into four scanlines. CRTC start low
byte toggles between 50h, 00h, a0h, and f0h in nearby code, so the
same data can appear as staged page slices rather than a full-screen redraw.
The larger sequence at +0x6aa1b..0x6ac86 calls the strip copier with several
different source offsets, waits about 20 timing units between phases, checks
ESC through port 60h, and finally clears a 200-row rectangle with
rep stosw.
Part 4: UNLPOWER.005
UNLPOWER.005 is the largest plain executable and looks like the main demo
engine. It loads UNLPOWER.006, contains the longest greeting text, and has
the richest set of geometry and raster loops.
Basic VGA And Palette Helpers
At UNLPOWER.005+0x111e7..0x11208 there are the same four display-status
waits used in the first part. At +0x1120b, the screen is cleared:
mov es,0a000h
mov cx,7d00h
xor di,di
xor ax,ax
rep stosw
Palette support is almost identical to UP000:
+0x11284: upload 768 DAC bytes.+0x112c5: in-place grayscale conversion.+0x112f6: fade in with(component * BL) >> 7.+0x11332: fade out with seven single-bit shifts.+0x1136a: palette morph between two 768-byte buffers.+0x121cb: per-channel step toward a target palette, one byte at a time.
The palette code confirms that each executable is mostly self-contained. It
does not rely on a shared graphics library in LOADER.EXE.
Rotation Kernels
At +0x113d5, +0x11452, and +0x114d7, the part rotates arrays of
six-byte vertices. The tables near 0x303e supply sine/cosine-like values.
The first kernel rotates x/y:
out_x = cos * x - sin * y
out_y = sin * x + cos * y
out_z = z
The multiply results are shifted down by 8 bits:
imul bx
sar ax,8
The other two kernels rotate x/z and y/z using the same fixed-point format.
Direct Line Writer
At +0x1154f..0x11671, the code draws a line directly into planar VGA. It
first maps both endpoints to byte offset plus plane mask:
offset = y * 320 + (x >> 2) + page_base
mask = table[x & 3]
The y multiply is implemented as:
dx = y
cx = y
cx <<= 8
dx <<= 6
cx += dx ; y * 320
The loop is a Bresenham variant. When the x step crosses a pixel phase, the plane mask is shifted and written to Sequencer Map Mask:
mov dx,03c4h
mov al,02h
mov ah,current_mask
out dx,ax
For steep lines it increments or decrements DI by 0x140 per row. For
shallow changes it shifts the mask, wraps from 0x08 to 0x01, and increments
the byte offset. The visible color byte comes from ds:7f80.
Edge Table Builder
At +0x1167a..0x1179f, the part does a second Bresenham pass, but instead of
writing pixels it updates two scanline tables:
left[y] = min(left[y], x)
right[y] = max(right[y], x)
The tables live at 0x7900 and 0x7c20, one word per scanline. This is the
classic polygon fill split:
- Trace polygon edges into left/right row limits.
- Fill each row between those limits.
Mode X Setup
At +0x117b1, the engine sets mode 13h, unchains VGA, clears 128 KB, and
programs:
CRTC maximum scanline register 09h = 01h
CRTC offset register 13h = 0a0h
The maximum scanline tweak is one of the places where the code is using VGA timing/layout registers as part of the look, not just treating mode 13h as a flat linear framebuffer.
Span Filler
The row filler starts around +0x11bdc and reaches the fast path at
+0x11c98..0x11d18. For each active row:
x0 = left[y]
x1 = right[y]
width = x1 - x0
di = y * 320 + (x0 >> 2) + page_base
Very narrow spans are handled by touching only the end planes. Larger spans write the left edge, the right edge, then fill the middle with all planes enabled:
mov dx,03c4h
mov ax,0f02h
out dx,ax
mov al,color
mov ah,al
rep stosw
Because all four planes are enabled for the middle bytes, the loop fills four
pixels per byte position. The end masks come from small lookup tables near
0x7f5e and 0x7f68.
Per-Frame Object Path
The main object loop starts after the entry path around +0x12b6a. It sets up
Mode X, uploads an initial palette, seeds object counts, then runs timed
sections. A representative frame block is:
wait/swap visible page call 0x11f02
advance sine/table offsets ds:7f78, ds:7f7a
rotate vertex set calls 0x114d7 and 0x11452
derive per-object row bands call 0x12570
project/fill polygons call 0x1185d
compute timing value call 0x12532
poll ESC on port 60h
repeat until section counter ends
The projection and fill routine at +0x1185d..0x11d2c is dense. It sorts or
swaps groups of vertex records, projects x/y through z using signed idiv,
does backface tests with cross products, writes the row edge tables, and then
fills spans. The core projection form is:
screen_x = 0xa0 + ((x + camera_x) * scale) / (z + camera_z + scale)
screen_y = 0x64 + ((y + camera_y) * scale) / (z + camera_z + scale)
The constants 0xa0 and 0x64 are the center of a 320 by 200 screen. The
division is real signed 16-bit division, so this is not an affine-only fake;
it is doing perspective per vertex.
Small Projected Particle/Point Layer
At +0x11e19..0x11f00, the part updates 100 small projected points. It first
erases old positions using stored offsets near bp + si + 21aeh, then projects
new x/y with a depth term:
screen_y = 0x64 + x * 0x46 / (z + 0x46)
screen_x = 0xa0 + y * 0x46 / (z + 0x46)
The point is clipped to the 320 by 200 view, mapped to a planar byte and mask,
then plotted with color 0x14 or 0x15 depending on depth. If it falls out of
range, the code reloads a fresh point from a table near 0x2c46.
Page Swap
At +0x11f02 and +0x11f2f, the code alternates CRTC start low byte and draw
page variables:
display offset 00h -> draw page base 0x00a0
display offset a0h -> draw page base 0x0000
The visible page is selected through CRTC register 0dh; the drawing base is
stored in ds:303a, and another small page state goes to ds:303c.
Part 5: UP007.EXE
UNLPOWER.007 expands to a smaller final executable. It loads
UNLPOWER.008, uses UNLPOWER.009 as a data asset, and contains a compact
font/text renderer.
RLE-Style Asset Decoder
At UP007.EXE+0x0ece..0x0ef7, the part decodes a byte stream:
token = *si++
count = token
if count <= 7fh:
count++
bx -= count
rep movsb
else:
value = *si++
count = 0101h - token
bx -= count
repeat count times:
es:[di++] = value
So values 00h..7fh are literal runs of token + 1 bytes, while values above
7fh are repeated-byte runs. The caller passes BX as the number of bytes to
produce.
RLE To Planar Loader
At +0x0ef8..0x0f27, the decoder is called repeatedly while Sequencer Map
Mask steps through 1, 2, 4, 8:
mov ax,0102h ; index 2, map mask 1
for many chunks:
bx = 50h
decode 80 bytes
shl ah,1
if ah == 10h: ah = 1
out 03c4h,ax
The outer count is 0x320, and each decode emits 0x50 bytes. That is a
large planar image stream split into 80-byte scanline chunks.
Full Planar Copy
At +0x0f85..0x0fc0, the code copies a prepared image to A000 plane by plane:
for mask in 1,2,4,8:
out 03c4h,0200h | mask
for y in 0..199:
mov cx,50h
rep movsb
si += 0f0h
The si += 0f0h skip means it copies 80 bytes out of a 320-byte row each
plane pass. This is the same chunky/interleaved-to-planar pattern as in
UP000, but expressed as row copies rather than single-byte lodsb strides.
Font Atlas Builder
At +0x0fee..0x1092, the code rearranges a large source into a compact font
or glyph atlas. The loop shape repeats four times:
for block in 0..9:
for plane_row in 0..3:
for glyph_row in 0..40:
movsb
movsb
movsb
movsb
si += 013ch
The repeated movsb x4 and si += 0x13c show that it is extracting four-byte
wide strips from wider 320-byte rows.
Text Renderer
At +0x1093..0x10d0, each character is mapped through a table, multiplied by
0x290, and copied from the glyph atlas to VGA:
glyph_offset = char_index * 0290h
for each of four planes:
out 03c4h,0200h | mask
for row in 0..40:
movsb x4
di += 4ch
0x290 = 656 bytes per glyph, matching 41 rows times 16 bytes across all
plane material. Spaces simply add four bytes to DI. Carriage returns advance
by 0xcd0 and align back to a 0x50-byte row boundary.
Final Scroll/Text Loop
The entry at +0x11d9 runs the file/module loaders, sets graphics mode, sets
an IRQ/music path, then loops:
wait for retrace edge
draw current text at current page offset
draw same text lower on the page
advance text source offset by 4
advance CRTC start row
wrap row offset at 0x15e
poll ESC
The CRTC start routine at +0x11bf computes:
start = row * 0x50
CRTC 0ch = high(start)
CRTC 0dh = low(start)
That gives a hardware vertical scroll over the prepared planar page. At exit, the code restores text mode, restores the keyboard/mask state, copies a text screen to B800, prints a final message, and returns to DOS.
What Each Part Does
The archive structure and code shape suggest this order:
LOADER.EXE: executes each part and preserves interrupt state.UNLPOWER.000: first Mode X/palette-heavy intro section with planar image and texture/span kernels.UNLPOWER.001: sound setup plus a 3D object/mask section using page-swapped Mode X.UNLPOWER.003: timed logo/strip section with four-plane chunky-to-planar copies and CRTC page slicing.UNLPOWER.005: main vector/effect part, including rotations, projection, scanline polygon fill, point layers, palette animation, and page flips.UNLPOWER.007: final image/text section with RLE asset expansion, glyph atlas conversion, planar text rendering, and hardware vertical scroll.
Why It Matters
Unleashed Power is not as famous as the three PC demos ahead of it at TCC
1993, but it is technically representative of the moment when DOS demos were
leaving simple mode 13h behind without yet moving into protected-mode
frameworks.
The interesting part is how much is done with small real-mode loops:
- Four separate executables all know how to program the VGA directly.
- The visual parts use unchained VGA planes and CRTC start changes instead of copying full screens every frame.
- Palette code is used as an effect system, with full 768-byte DAC fades and morphs.
- The main engine uses proper fixed-point rotations, perspective divides, backface tests, edge tables, and span fills.
- The final part has a practical asset decoder and a hardware-scrolled text renderer rather than brute-force redraw.
That makes it a good companion to the more famous 1993 analyses: it is a smaller production, but its inner loops show the same engineering pressure - make the VGA do as much work as possible, keep memory movement predictable, and spend the CPU on the few loops that create the visible effect.