POV-Ray : Newsgroups : povray.text.scene-files : Sphere made of Cubes : Sphere made of Cubes Server Time
1 Jul 2024 03:07:34 EDT (-0400)
  Sphere made of Cubes  
From: Quietman
Date: 5 Aug 2002 17:06:12
Message: <3d4ee8c4@news.povray.org>
/*
  Blocks Shape
  (c) 2002 D.A.Jackson
*/

#include "colors.inc"

global_settings {
  assumed_gamma 1.0
  max_trace_level 255
}

// camera

camera {
  location <49, 53, 65>
  look_at <0, 21, 0>
  angle 40
}

// lights

light_source {
  <1000, 1000, 100>
  color White
  parallel
}

// sky

sky_sphere {
  pigment {
    color Gray50
  }
}

// ground

plane {
  y, 0
  pigment {
    granite
    turbulence 1
    color_map {
      [ 0 color Gray40 ]
      [ 1 color Gray60 ]
    }
    scale 5
  }
  normal {
    granite 1/5
    scale 5
  }
}

// object

#declare r = seed(1);
#declare r2 = seed(2);

#declare zloop = -20;
#while (zloop < 21)
  #declare yloop = -20;
  #while (yloop < 21)
    #declare xloop = -20;
    #while (xloop < 21)
      #declare s = cos(abs(xloop)/20) + cos(abs(yloop)/20) +
cos(abs(zloop)/20);
      #if ((s > 2.54) & (s < 2.58))
        box {
          -0.45, 0.45
          pigment {
            color White
          }
          finish {
            specular 1
            roughness 1/200
            reflection 1/4
          }
          rotate <rand(r2)*90, rand(r2)*90, rand(r2)*90>
          translate <xloop, yloop + 21, zloop>
        }
      #end
      #declare xloop = xloop + 1;
    #end
    #declare yloop = yloop + 1;
  #end
  #declare zloop = zloop + 1;
#end




---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.380 / Virus Database: 213 - Release Date: 24/07/2002


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.