top | item 6109198

(no title)

nottwo | 12 years ago

Another fun toy is Forth Haiku at http://forthsalon.appspot.com/

  A Forth Haiku is an attempt to mix mathematics, art, and the
  Forth programming language. It resembles a texture shader,
  however, the emphasis is on direct expression in the
  resulting image.

  The Forth program describing each Haiku is run once per pixel
  over a square image. Forth cells are floating point.
  Conditions return 1 instead of -1. The position is available
  from the words x and y, which range from 0 to 1, which the
  origin in the lower left hand corner. The haiku returns the
  desired color in (red, green, blue, alpha), with alpha being
  topmost on the stack. If the stack has less than 4 items
  default values are assumed: red:0, green:0, blue:0, alpha:1.

  Like a traditional haiku, an ideal Forth Haiku has 3 lines
  of 5, 7, 5 words. Compositions which don't fit the haiku form
  are either 'short' (less than 140), or 'long'.

discuss

order

No comments yet.