LumosQuad - A Lightning Generator, v0.1

Theodore Kim and Ming Lin,

General Usage

The binary download contains an executable LumosQuad.exe, and the source distribution builds a file of the same name. The simplest usage of this executable is:

  • LumosQuad input.ppm output.exr
First let's look at the input PPM file. Several example inputs are included in the distributions, in the ./examples subdirectories. If you can't open and edit PPM files, GIMP is a free program that can do both.

The following is the input file ./examples/spine.ppm:

The colors in this image have the following meaning to the simulation:
  • Black - Allow lightning to grow here.
  • Green - Do not allow lightning to grow here.
  • White - If the lightning hits this pixel, stop the simulation and render.
  • Red - Have lightning growth start here.
  • Blue - If possible, have the lightning pass through here.
In this input file, only one pixel is set to red (the upper left corner of the Z) and one is set to white (the lower right corner of the Z). You may have to look very closely to see the red dot. If you run the command,
  • LumosQuad ./examples/spine.jpg spine.exr
the code will run for a while and eventually two files will be generated, spine.exr, and spine.lightning. If you open spine.exr in Photoshop, you can manipulate the final rendered image. If you don't have Photoshop, a small program EXRManip is enclosed in the binary distribution that also lets you manipulate the final rendering.

> Go to Photoshop instructions
> Go to EXRManip instructions
> Skip ahead to render tweaking