mgMake

work by Matt Gordon

fabrication

code

sound

publications

portfolio

Hexagraph

Github

A 4-bit (16 opcode) stack-based VM with a graphical output, and associated assembler. The assembly language handles basic macros of opcodes to extend functionality, goto statements, and function calls. The 'memory' of the machine is presented in grid form as an image, and can be changed with normal memory setting operations or by drawing lines.
Current demos (shown above, alongside a section of their assembly code) include producing elementary cellular automata and the Sierpinski carpet.


Early Screenshots

Previous versions assigned more opcodes to drawing operations, at the expense of having fewer low level operations necessary for general computation.
These versions also used an image as input alonside the program, and an overarching genetic algorithm that would seek to produce programs that could copy this image. This goal was dropped after limits in progress, in favor of using the project for more general education on virtual machines.

These images are products of the environment running a basic genetic algorithm over an initially random program, failing to ever resemble the input image but producing visually interesting results in the meantime. Programs would often produce many variations within a single visual genre.