//Leaf definition file // //Leaves should be about 1 unit wide, and their stem should begin at the origin. //The leaf should #declare maple1 = sphere { 0, 1 scale <2, 1, 1> clipped_by { sphere { <0, 0, -1>, 0.5 } } texture { pigment { image_map { tga "maple1.tga" once } } finish { ambient 0.5 diffuse 0.5 } normal { bump_map { tga "maple1.tga" once bump_size -10 } } translate <-0.5, -0.5, -0.5> } hollow rotate x*50 translate <0, -0.4, 1> } #declare maple2 = sphere { 0, 1 scale <2, 1, 1> clipped_by { sphere { <0, 0, -1>, 0.5 } } texture { pigment { image_map { tga "maple2.tga" once } } finish { ambient 0.5 diffuse 0.5 } normal { bump_map { tga "maple2.tga" once bump_size -10 } } translate <-0.5, -0.5, -0.5> } hollow rotate x*50 translate <0, -0.4, 1> } #declare maple3 = sphere { 0, 1 scale <2, 1, 1> clipped_by { sphere { <0, 0, -1>, 0.5 } } texture { pigment { image_map { tga "maple3.tga" once } } finish { ambient 0.5 diffuse 0.5 } normal { bump_map { tga "maple3.tga" once bump_size -10 } } translate <-0.5, -0.5, -0.5> } hollow rotate x*50 translate <0, -0.4, 1> } #declare fallmaple1 = sphere { 0, 1 scale <2, 1, 1> clipped_by { sphere { <0, 0, -1>, 0.5 } } texture { pigment { image_map { tga "fallmaple1.tga" once } } finish { ambient 0.5 diffuse 0.5 } normal { bump_map { tga "fallmaple1.tga" once bump_size -10 } } translate <-0.5, -0.5, -0.5> } hollow rotate x*50 translate <0, -0.4, 1> } #declare fallmaple2 = sphere { 0, 1 scale <2, 1, 1> clipped_by { sphere { <0, 0, -1>, 0.5 } } texture { pigment { image_map { tga "fallmaple2.tga" once } } finish { ambient 0.5 diffuse 0.5 } normal { bump_map { tga "fallmaple2.tga" once bump_size -10 } } translate <-0.5, -0.5, -0.5> } hollow rotate x*50 translate <0, -0.4, 1> } #declare fallmaple3 = sphere { 0, 1 scale <2, 1, 1> clipped_by { sphere { <0, 0, -1>, 0.5 } } texture { pigment { image_map { tga "fallmaple3.tga" once } } finish { ambient 0.5 diffuse 0.5 } normal { bump_map { tga "fallmaple3.tga" once bump_size -10 } } translate <-0.5, -0.5, -0.5> } hollow rotate x*50 translate <0, -0.4, 1> } #declare melon1 = blob { threshold 0.6 sphere { <0,0.2,0>,0.5,1 } sphere { <0,-0.2,0>,0.2,-1 } sphere { <0,0.6,0>,0.2,-1 } texture { pigment { color rgb <1,0.95,0.5> } finish { ambient 0.5 diffuse 0.5 specular 1 roughness 0.01 } normal { crackle 1 turbulence 0.5 scale 0.1 } } } #declare melon2 = blob { threshold 0.6 sphere { <0,0.2,0>,0.5,1 } sphere { <0,-0.2,0>,0.2,-1 } sphere { <0,0.6,0>,0.2,-1 } texture { pigment { color rgb <0.95,0.97,0.5> } finish { ambient 0.5 diffuse 0.5 specular 1 roughness 0.01 } normal { crackle 1 turbulence 0.5 scale 0.1 } } } #declare pinkpetal = sphere { 0, 0.7 scale <2, 1, 1> clipped_by { sphere { <0, 0, -0.7>, 0.5 } } texture { pigment { image_map { tga "pinkpetal.tga" once } } finish { ambient 0.5 diffuse 0.5 } normal { bump_map { tga "pinkpetal.tga" once bump_size -10 } } translate <-0.5, -0.5, -0.5> } hollow rotate x*100 translate <0, -0.6, 0.4> } #declare pinkflower = union { object { pinkpetal } object { pinkpetal rotate y*90 } object { pinkpetal rotate y*180 } object { pinkpetal rotate y*270 } sphere { <0, 0.1, 0>, 0.1 scale <1, 0.3, 1> pigment { color rgb <0.8, 0.8, 0.8> } finish { ambient 0.5 diffuse 0.5 specular 0.3 roughness 0.1 } normal { granite 0.05 scale 0.1 } } scale 0.4 }