| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Name | Name | Last commit date | ||
|---|---|---|---|---|
A 386/486 demo featuring 3D vector balls, keyframe animation, a starfield, and palette-controlled fade effects. Should work on a 386 as well.
Written in C for DOS Mode 13h (320x200, 256-color VGA). Compiled with Borland Turbo C++ 3.1, targeting a 486 with no FPU co-processor.
The pre-compiled BALLS.EXE is included in the Releases section. It is a 16-bit DOS executable and requires a DOS or DOS emulated environment to run. It has been tested in DOSBox.
mount c c:\path\to\your\folder c:
balls
Any DOS-compatible emulator that supports Mode 13h VGA graphics will work. Mount the directory containing BALLS.EXE and sprites.dat, then run BALLS. sprites.dat needs to be in the same folder as BALLS.EXE.
Building requires Borland Turbo C++ 3.1 (BCC.EXE) and Borland Turbo Assembler (TASM.EXE) running inside DOSBox. Both are 16-bit DOS programs and cannot run on a modern OS directly.
build
TASM /ml gfx13.asm,gfx13.obj BCC -ml -1 main.c starfld.c vecballs.c gfx13.obj
| Flag | Purpose |
|---|---|
| -ml | Large memory model (required for far pointers and 64 KB+ buffers) |
| -1 | Enable 80186+ instructions (required for OUTSB in inline assembly) |
balls ├─ src Self-contained: source, build scripts, data, and executable │ ├─ main.c Entry point, keyboard interrupt handler, palette control │ ├─ gfx13.h Mode 13h graphics library. Type definitions and prototypes │ ├─ gfx13.asm Mode 13h graphics library (TASM). Drawing, blitting, palette, VSync │ ├─ graphics.h Shared demo header. Includes gfx13.h, globals, prototypes │ ├─ starfld.c 3D starfield initialization and rendering │ ├─ vecballs.c Ball sprites, keyframe morphing, 3D transform, animation loop │ ├─ sprites.dat Binary sprite data (36 ball frames with metadata) │ ├─ build.bat Build script (assembles + compiles, outputs BALLS.EXE) │ ├─ clean.bat Removes build artifacts │ └─ BALLS.EXE Pre-compiled DOS executable (build + run here) │ ├─ README.md This file │ ├─ LICENSE MIT License │ └─ images └─ capture Screenshots and animated capture
All graphics go through a Mode 13h (VGA 320x200, 256 colors) rendering pipeline implemented in gfx13.asm:
The main animation loop in vecballs.c performs:
Released under the MIT License — Copyright © 1991 Rohin Gosling.
| Back | FazBrowse Home | New Git URL |