#version unofficial MegaPov 0.5; /* A brilliant cut diamond There are four divisions along the axis at which facets have their endpoints The third from bottom up is the girdle; below and above the girdle is the crown and the pavilion respectively, each divided in two by CrownShape and PavilionShape Sigmund Kyrre Ås 2000 */ $TotalHeight = 1.5; $GirdleHeight = .35; $CrownShape = .35; // percent of GirdleHeight $PavilionShape = .60; // percent of pavilion height $Facets = 8; $Radius = 1; $Photon = 0; $Radiosity = 0; $Filter=1; global_settings { #if(Photon) photons { count 9000 autostop 0 max_trace_level 4} #end max_trace_level 9 } #macro Light(Colour) light_source { 0, Colour looks_like { sphere { 0, 1 pigment { rgb 1 } finish { ambient 1 } photons{pass_through}} } } #end #macro AreaLight(Colour) light_source { 0 color rgb Colour area_light <2, 0, 0> <0, 0, 2> 4, 4 adaptive 1 jitter circular orient looks_like { sphere { 0, 1 pigment { rgb 1 } finish { ambient 1 } photons{pass_through}}} } #end #macro Colour(vect) #local vect=vect*<1,1,1>/255; color rgb vect #end $Lpos=<-20,30,20>*.7; object { AreaLight(1.1) translate Lpos } cylinder {Lpos*2, Lpos*.2, 2.1*sqrt(2) open pigment {rgb 1} } camera { location <-.2 , 1 ,2.4>*4 look_at y*.5-x*.8 angle 24 } $Diamant_mat=material{ texture { pigment {color rgbf<.81,.81,.8,0.8*Filter>} finish { ambient 0.01 diffuse 0.4 reflection_min 0.06 reflection_max 0.8 reflection_falloff .5 } } interior { caustics 1 ior 2.417 // dispersion 1.08 disp_nelems 50 fade_color z*.1 fade_power 1200 fade_distance 20 } } $ant1=Facets; $R3=Radius; $Y2=CrownShape*GirdleHeight; $Y3=GirdleHeight; $R1=.46*R3; $W=2*pi/ant1; $R2=(R3*Y2-R1*(Y2-Y3))/Y3 * (1+2*sqr(sin(W/4))); $Y5=TotalHeight; $Y4=Y3+(Y5-Y3)*PavilionShape; $R4=(Y5-Y4)*R3/(Y5-Y3) * (1+2*sqr(sin(W/4))) ; $P=array[4][ant1*2+1] $i=0; #while (i,rotate y*360*(i/ant1+1/2/ant1)); $P[1][i]=vtransform(,rotate y*360*i/ant1); $P[3][i]=vtransform(,rotate y*360*(i/ant1+1/2/ant1)); $i=i+1; #end $i=0;$ant2=ant1*2; #while (i,rotate y*360*i/ant2); $i=i+1; #end $Diamond= mesh { $j=0; #while (j)] [.1 Colour(<195,213,238>)] [.3 Colour(<173,199,231>)] [1 Colour(<232,239,249>)] } turbulence .1 scale 6 } finish {diffuse 1 ambient .5} no_shadow } plane {y,-.001 pigment {Colour(<95,5,160>)} finish{diffuse .6 brilliance 1.2 reflection 0.6*0 specular .1 roughness .15} #if (0) photons{ target 1 refraction off reflection on } #end } #if(Radiosity) global_settings { ini_option "+QR" ini_option "Preview_Start_Size=16" ini_option "Preview_End_Size=8" radiosity{ count 25 nearest_count 4 error_bound 2.5 recursion_limit 2 low_error_factor .5 gray_threshold 0.0 minimum_reuse 0.015 brightness 1 adc_bailout 0.01/(18*2) } } #end