// Last edited on 2019-07-17 03:15:30 by stolfilocal // Processed by remove-cam-lights background{ color rgb < 0.5, 0.5, 0.85 > } #declare cor_bola = texture{ pigment{ color rgb < 0.50, 0.60, 0.40 > } finish{ diffuse 0.9 ambient 0.1 } } #declare passos = 100; #declare vet = array[12]; #macro interpolin(t0, v0, t1, v1, tt) #local r = (tt-t0)/(t1-t0); #local s = 1-r; #local vv = s*v0 + r*v1; vv #end #macro arcobezier(t0, t1, A, B, C, D, tt) #local AB = interpolin(t0, A, t1, B, tt); #local BC = interpolin(t0, B, t1, C, tt); #local CD = interpolin(t0, C, t1, D, tt); #local ABC = interpolin(t0, AB, t1, BC, tt); #local BCD = interpolin(t0, BC, t1, CD, tt); #local ACBD = interpolin(t0, ABC, t1, BCD, tt); ACBD #end #macro curva(p0, p1, v0, v1) #local i = 0; #while(i <= passos) #local p = arcobezier(0, passos, p0, v0, v1, p1, i); sphere{ p, 0.5 texture{cor_bola}} #declare i = i+1; #end #end union{ curva(<0.5, 5, 0>, <13.5, 9.5, 0>, <3.5, 7, 0>, <11.5, 7, 0>) curva(<13.5, 9.5, 0>, <8.5, 6, 0>, <13, 11, 0>, <8, 9.5, 0>) curva(<8.5, 6, 0>, <6.5, 11, 0>, <7.5, 0, 0>, <6, 2, 0>) curva(<6.5, 11, 0>, <0.5, 5, 0>, <11, 8, 0>, <4, 0.5, 0>) } #include "eixos.inc" // object{eixos(10)} #include "camlight.inc" #declare centro_cena = < 8.00, 8.00, 0.00 >; #declare raio_cena = 7.0; #declare dir_camera = < 7.00, 7.00, 5.0 >; #declare dist_camera = 5*raio_cena; #declare intens_luz = 1.20; camlight(centro_cena, raio_cena, dir_camera, dist_camera , z, intens_luz)