fr:mmj:104

Ce code est différent du programme par défaut de Thérion (plus de symboles argile dans la topo, et des symboles plus petits).

   def a_clay (expr p) =
     T:=identity;
     pickup PenC;
     path q, qq; q = bbox p;
     picture tmp_pic; 
     tmp_pic := image(
     for i = xpart llcorner q step 0.7u until xpart urcorner q:
       for j = ypart llcorner q step 0.7u until ypart urcorner q:
         qq := ((-.20u,0){up}..origin{down}..{up}(0.20u,0)) randomized (u/15)
         shifted ((i,j) randomized 0.6u);
         if xpart (p intersectiontimes qq) < 0:
           thdraw qq;
         fi;
       endfor;  
    endfor;
    );
    clip tmp_pic to p;
    draw tmp_pic;
  enddef;

Les valeurs par défaut sont :

    for i = xpart llcorner q step 1.5u until xpart urcorner q:
      for j = ypart llcorner q step 1.5u until ypart urcorner q:
        qq := ((-.25u,0){up}..origin{down}..{up}(0.25u,0)) randomized (u/15)
             shifted ((i,j) randomized 1.3u);
  • fr/mmj/104.txt
  • Last modified: 16 years ago
  • by 127.0.0.1