On May 31, 2009, at 5:11 PM, Eduardo Cavazos wrote:

As some of you know, one of my projects is an implementation of
Context Free Art in Scheme.

Abdulaziz Ghuloum wrote:

Context Free is Awesome!  Glad we have it in Scheme!  Here are some
early experiments of mine:
  http://www.contextfreeart.org/gallery/view.php?by=aghuloum

Below is your 'aghuloum_tree'. :-)

When I did a direct conversion, the branches would show up, but they never turned green.

There are a few places where you issue a brightness adjustment twice in the same adjustments list. For example:

    SEED1 {y 1. x -0.5 s 0.7 r 30 b -0.5 flip 90 brightness 0.1}

By my understanding of the 'adjustments' formula, that will approach 0.181818... given a starting value of '0'. I wonder if the main CF implementation only takes the last adjustment if there are duplicates? Anywho, I kept the latter adjustment in each case and this provided some chlorophyll. But things still weren't green enough... Other tweaks which helped were raising the branch weights and cranking up the 'brightness' adjustments.

Finally, the result isn't as crisp as the CF version. On a picture like this, there's a lot of fine detail and the rendering system you use makes a huge difference in the output. It's hard for OpenGL to keep up with Anti Grain for stuff like this.

Ed

----------------------------------------------------------------------
(import (rnrs) (cfdg) (cfdg-rule) (cfdg-abbreviations))

(rule seed-1

      (1 (square (sat 0.6) (hue 120))
         (seed-1 (y 1.2) (size 0.99) (rotate 1.5)))

      (0.09 (seed-1 (flip 90)))

      (0.09 (seed-1 (r -5) (b 0.01))
            (seed-1 (y 1.0) (x -0.5) (s 0.7) (r  30) (f 90) (b 0.1))
            (seed-1 (y 1.0) (x  0.5) (s 0.7) (r -30) (f 90) (b 0.05))))

(background (lambda () #t))

(viewport '(-50 100 0 100))

(start-shape seed-1)

(threshold 0.1)

(run-model)
----------------------------------------------------------------------

Reply via email to