POV-Ray : Newsgroups : povray.text.scene-files : Checkered plane under reflective sphere (see p.b.i.) Server Time
1 Jun 2024 14:48:50 EDT (-0400)
  Checkered plane under reflective sphere (see p.b.i.) (Message 1 to 1 of 1)  
From: Alex Kluchikov
Subject: Checkered plane under reflective sphere (see p.b.i.)
Date: 12 May 2004 08:08:49
Message: <40a213d1@news.povray.org>
// Alex Kluchikov, 2004
// mailto: klk### [at] ukrnet, akl### [at] mailru
// Feel free to modify/use in any form

global_settings
{
noise_generator 3
max_trace_level 4
}


sphere{0,1000
 texture{
  pigment{
   gradient y color_map{
    [0,color rgb <0.8,0.83,1>]
    [1,color rgb <0.4,0.7,1>]
    }scale 2 translate -y}finish{ambient .4 diffuse .8}scale 1000}

texture{
 pigment{average pigment_map{
 #declare gr=.95;
 #declare ge=3/(1+gr+gr);
 #declare t1=.1;
 #declare t2=.9;
 #declare tr1=-.2;
 #declare tr2=.2;
  [1,bozo translate 1*y color_map{
   [t1,color rgbt < 1,gr,gr,tr1>*ge]
   [t2,color rgbt < 0, 0, 0,tr2>*ge]
  }]
  [1,bozo translate 1*z color_map{
   [t1,color rgbt < gr, 1,gr,tr1>*ge/.85]
   [t2,color rgbt <  0, 0, 0,tr2>*ge]
  }]
  [1,bozo translate 1*x color_map{
   [t1,color rgbt < gr,gr, 1,tr1>*ge/.7]
   [t2,color rgbt <  0, 0, 0,tr2>*ge]
  }]

 }}scale 0.25 translate -10 finish{ambient .4 diffuse .8}scale 2500}

 no_shadow
 no_image
 hollow double_illuminate scale 100}

#declare st=texture{pigment{color rgb<0.83,0.82,0.84>*1.2}
  finish{diffuse 0.85 ambient 0
   specular 0.8 roughness 0.02
   phong 2.0 phong_size 300
   brilliance 7.3 metallic .5
   reflection{0.6,1.0 metallic}}
  }

#declare plastic=texture{
   pigment{color rgb 1}
   finish{diffuse .94 ambient 0
    phong 3 phong_size 2000
    specular .3 roughness 0.015
    reflection{.2,.4}
   }
  }

#declare chps=pigment{
 function{(pow(abs(sin(x)),1/4)*select(sin(x),-1,0,1)*
          pow(abs(sin(z)),1/4)*select(sin(z),-1,0,1)
          +1)/2
          }color_map{[0,color rgb 0][1,color rgb 1]}scale 1/2/pi
 }

#declare parf0=
  pigment{
  average pigment_map{
#declare i=0;
#while(i<1)
   [pow(1/2,i/4),chps translate i/2 rotate y*i*45 scale pow(1/2,i/2)]
#declare i=i+1;
#end
  }
 scale 2
 translate 100
 }

#declare terracotta=texture{
 finish{diffuse 1.3 phong .1}
 normal{
  average normal_map{
  [1,bozo .5 rotate 60 scale .02 noise_generator 3
slope_map{[0,<5,-10>][.5,<0,0>]}]
  [1,bozo .5 rotate 60 scale .015 noise_generator 3
slope_map{[0,<5,-10>][.5,<0,0>]}]
  [1,bozo 2 rotate 60 scale .006 noise_generator 3]
  }scale .75
  }
 pigment{
  color rgb .5
  }
 }


#declare parf=function{pigment{parf0}}

#declare parfn1=normal{function{parf(x,y,z).gray}.6
slope_map{[0,<1,1>][.5,<0,-1>][.5,<0,1>][1,<1,-1>]}}

#declare park=texture{
 function{parf(x,y,z).gray}
  texture_map{[.3,st
normal{parfn1}][.4,terracotta][.6,terracotta][.7,plastic normal{parfn1}]}
 }


#declare area=0;
#declare paral=1;
#declare areacount=5;
#declare areadacount=2;
#declare areasize=3;
#declare mul=1;
#declare le=30;
#declare ga=180;

light_source{
 -le*z, color rgb <1.0,0.8,0.6>*0.55*mul
#if(area)
 area_light x*areasize,y*areasize,areacount,areacount jitter adaptive
areadacount circular orient
#else
 #if(paral) parallel #end
#end
 rotate x*35 rotate y*160
 rotate y*ga
 }

light_source{
 -le*z, color rgb <0.6,0.8,1>*0.55*mul
#if(area)
 area_light x*areasize,y*areasize,areacount,areacount jitter adaptive
areadacount circular orient
#else
 #if(paral) parallel #end
#end
 rotate x*45 rotate y*240
 rotate y*ga
 }

light_source{
 -le*z, color rgb 0.35*mul
#if(area)
 area_light x*areasize,y*areasize,areacount,areacount jitter adaptive
areadacount circular orient
#else
 #if(paral) parallel #end
#end
 rotate x*15 rotate y*0
 rotate y*ga
 }

camera{
 location -12*z
 look_at 0
 angle 50
 rotate x*35
 rotate y*35
 translate -y*1.75
 }


sphere{0,1
 texture{st}
}

plane{y,-1
 texture{park scale 2}
 }


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.