/metal-fireworks

Fireworks Graphics Demo (Swift, Metal, macOS)

Primary LanguageSwift

Fireworks Metal Demo

Overview

This is a graphics demo that shows animated fireworks. I wrote it for two reasons: to see what Swift can do, and for something new and fun (I never do 3D graphics in my day job).

This uses the "Metal" low-level 3D graphics API.

Latest Binary Release

Get a .dmg from the release page

Note
Mac OSX 10.11+ is required, due to Metal

Features

  • 60 FPS (2015 Mac Book)

  • Silky smooth "global time" rendering; no step-based ticks with floating point errors. This also lets you pause and rewind time.

  • Calculates gravity and air drag

  • Uses alpha blending

  • Two kinds of fireworks: twinkle out and plume trail

Keys

Press space to pause time. Press j and k to step time forward and backward by 1/60th of a second.

Screen Shot

screen

(c) 2015 Karl Pickett