// Last edited on DATE TIME by USER // Processed by remove-cam-lights background{ color rgb < 0.75, 0.80, 0.85 > } #declare tx_joint = texture{ pigment{ color rgb < 1, 0.5, 0 > } finish{ diffuse 0.8 ambient 0.2 specular 0.5 roughness 0.005 } } #declare tx_red = texture{ pigment{ color rgb < 1, 0, 0 > } finish{ diffuse 0.8 ambient 0.2 specular 0.5 roughness 0.005 } } #declare tx_green = texture{ pigment{ color rgb < 0, 1, 0 > } finish{ diffuse 0.8 ambient 0.2 specular 0.5 roughness 0.005 } } #declare tx_blue = texture{ pigment{ color rgb < 0, 0, 1 > } finish{ diffuse 0.8 ambient 0.2 specular 0.5 roughness 0.005 } } #declare tx_vidro = texture{ pigment{ color rgb < 0.85, 0.95, 1.00 > filter 0.70 } finish{ diffuse 0.03 reflection 0.25 ambient 0.02 specular 0.25 roughness 0.005 } } #declare tx_espelho = texture{ pigment{ color rgb < 1.00, 0.50, 0.50 > } finish{ diffuse 0.4 reflection 0.5*< 1.00, 1.00, 1.00 > ambient 0.1 } } #declare tx_xadrez = texture{ pigment{ checker color rgb < 1.0, 1.0, 1.0 >, color rgb < 0.0, 0.0, 0.0 > } finish{ diffuse 0.9 ambient 0.1 } scale 2.5 } #declare wall_width = 0.5; #declare base = union{ box { // wall right <0, 2.5, 0>, texture {tx_joint} } box { // wall bottom , <5.5, 2.5 + wall_width, 1.0> texture{tx_joint} } box { // wall left <5.5, 2.5, 0>, <5.5 + wall_width, -2.5, 1.0> texture{tx_joint} } box { // wall top <5.5, -2.5, 0>, <0.5, -2.5 -wall_width, 1.0> texture{tx_joint} } box { // tower1 <0, 2.5, 0>, texture {tx_vidro} } box { // tower2 <0, -2.5, 0>, texture {tx_vidro} } box { // tower3 <5.5, 2.5, 0>, <5.5 +wall_width, 2.5 +wall_width, 1.5> texture {tx_vidro} } box { // tower4 <5.5, -2.5, 0>, <5.5 + wall_width, -2.5 -wall_width, 1.5> texture {tx_vidro} } } #declare chao = box{ <-20,-20,-1>, <+20,+20,0> } #macro castelo(p, tr, scal, tipo) #local t1 = tr + <0, 0, 1>; #local p1 = p + 1; #if (mod(tipo,2) = 0) #local s1 = 1.22*scal; #else #local s1 = 1.1*scal; #end #if (p < 4) object{base translate tr scale scal} castelo(p1, t1, s1, tipo) #else object{base translate tr scale s1} #end #end #include "eixos.inc" union{ object{ eixos(20.00) } object{ chao translate < 0,0,-5 > texture{ tx_xadrez } } #declare roleta = seed(12345); #declare s = rand(roleta); #local n = int(5*s); castelo(0,<0,0,0>,0.25, n) } #include "camlight.inc" #declare centro_cena = < 2.50, 0.00, 2.50 >; #declare raio_cena = 6.0; #declare dir_camera = < 4, -7, 4 >; #declare dist_camera = 16; #declare intens_luz = 1.00; camlight(centro_cena, raio_cena, dir_camera, dist_camera , z, intens_luz)