The website of »Generative Gestaltung« (first edition) is no longer maintained and has been archived.

Code M_5_1_01

M_5_1_01
Méthodes Complexes –  M.5 Diagrammes en arbre –  M.5.1 Récursivité –  M_5_1_01

Pages


  • 414 - 415

Comments

  • 2014-04-27 @ 7:26 pm   |  Comment by Massimo Franceschet

    I think the test

     

    if (level > 0)

     

    should be moved at the beginning of the drawBranch function to avoid the drawing of 0-level branchings.

     

     

    Moreover the block

    int k = int(key)-49;if (k>=0 && k<9) {recursionLevel = k;}

     

    should be rewritten as:

     

    int k = int(key)-48;if (k>=0 && k<=9) {recursionLevel = k;}

     

     

     

     

  • 2014-04-27 @ 7:48 pm   |  Comment by Massimo Franceschet

    The sketch is great, anyway!

Leave a Comment

   (required)

  

Please enable JavaScript to post a comment.

(.zip, max. 1MB)  

Proof that you are human!
Please paste the snippet below in an empty Processing sketch!
What number does the Processing console show?

randomSeed(37209);
println(int(random(100000)));

  (required)