ItsMeLucifer

Karta

May 9th, 2019 (edited)
376
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include "colors.inc" // Pliki zawieraja predefiniowane elementy sceny
  2. #include "stones.inc"
  3. #include "textures.inc"
  4. #include "shapes.inc"
  5. #include "glass.inc"
  6. #include "metals.inc"
  7. #include "woods.inc"
  8. camera {location <-1, 20, -7>
  9.     look_at <0, 0.5, 0>
  10.    
  11. }
  12. light_source {<20, 25, -20> color White}
  13. light_source {<-20, 25, -20> color White}
  14. plane { y, -2 pigment{hexagon color Black, color White, color Grey}}
  15. sky_sphere {
  16.     pigment {
  17.       gradient y
  18.       color_map {
  19.         [ 0.5  color Black]
  20.         [ 1.0  color Red ]
  21.       }
  22.       scale 2
  23.       translate -1
  24.     }
  25.   }  
  26. //UNION:
  27. #declare karta =
  28.  union{
  29. polygon{
  30.   4,
  31.  <0,0>,<1,0>,<1,1>,<0,1>
  32.  pigment
  33. { image_map
  34.   { png "karta2.png"
  35.     map_type 0
  36.   }
  37. }
  38. scale<1,1.6,1>
  39. rotate<90,30,0>
  40. translate<0,-1.94,0>
  41. }
  42. #declare Rnd_1 = seed (1153);                            
  43. }
  44. object {karta
  45.  
  46. }
  47. #declare i=0;
  48. //----------------------------------
  49. #for (i, 1, 3000 ,3)
  50.         object {karta
  51.          translate<23*rand(Rnd_1),0.15*rand(Rnd_1),23*rand(Rnd_1)>
  52.          rotate<0,i,0>
  53.         }
  54.   //... do something
  55.   // depending on value of Identifier.
  56. #end // ------------- end of loop --
  57. //----------------------------------
RAW Paste Data