// Sample-1-3.pov // if you run this sample in povray, you will see shadows // don't worry, you are not required to generate any shadows by now #include "shapes.inc" // The #include command is just for the compatibility with // the POV-Ray. By now, consider it as a comment. camera { location <0, 0, 5> look_at <0, 0, 0> right <0, 1.33, 0> up <0, 1, 0> // note that camera coordinate system is scaling, not the world coordinate system scale <2, 2, 2> rotate <0, -35, 0> } // create a regular point light source light_source { <2 ,0, 10> color rgb <1,1,1> // white light } union { // 4 similar boxes only with different rotation box { <-2, -1, -1> <2, 1, 1> scale <0.1, 0.1, 0.1> translate <4, 0, 0> rotate <0, 0, 0> } box { <-2, -1, -1> <2, 1, 1> scale <0.1, 0.1, 0.1> translate <4, 0, 0> rotate <0, 0, 90> } box { <-2, -1, -1> <2, 1, 1> scale <0.1, 0.1, 0.1> translate <4, 0, 0> rotate <0, 0, 180> } box { <-2, -1, -1> <2, 1, 1> scale <0.1, 0.1, 0.1> translate <4, 0, 0> rotate <0, 0, 270> } // color: will be applied to sub objects // because no color has already been specified for them pigment {color rgb <0.7, 1, 0>} // green } cylinder { <0, 0, -1>, <0, 0, -0.3>, 4.5 pigment {color rgb <1, 0.8, 0.7>} // yellow } //----------- The rest is same as sample2 union { cone { <0, 1, 0>, 0.05, <0, 0, 0>, 0.3 pigment {color rgb <1, 0.5, 0>} // brown translate <0, 2, 0> } cylinder { <0, 2, 0>, <0, -1, 0>, 0.1 pigment {color rgb <1, 1, 0>} // yellow } scale <0.5, 1, 1> rotate <0, 0, 40> } // note that the union block below is same as the above // just with differenct transformations union { cone { <0, 1, 0>, 0.05, <0, 0, 0>, 0.3 pigment {color rgb <1, 0.5, 0>} // brown translate <0, 2, 0> } cylinder { <0, 2, 0>, <0, -1, 0>, 0.1 pigment {color rgb <1, 1, 0>} // yellow } scale <0.8, 0.7, 1> rotate <0, 0, -80> // color: will be applied to sub objects // only if no color has already been specified for them pigment {color rgb <1, 1, 1>} } sphere { <0, 0, 0> 0.2 pigment {color rgb <1, 1, 1>} // white }