POV-Ray : Newsgroups : povray.general : location dependant refractive index : Re: location dependant refractive index Server Time
30 Jul 2024 16:15:28 EDT (-0400)
  Re: location dependant refractive index  
From: feestje
Date: 2 Nov 2008 07:30:01
Message: <web.490d9c83a1a1577518112fe00@news.povray.org>
hi all,

thank you for your responses! I thought of the stacked box methos myself but I
hoped ther ewould be something much more easier! well anyway: he is what I
accomplished so far:

 #include  "colors.inc"




sphere {   // IOR < 1
     <0,0,0> ,1.5
     pigment {
          color Black
     }
   }

plane{
     < 0, -1, 0>,           2
     pigment {
          color White

     }
     finish {
          ambient 0.7
          diffuse 0.7
     }
}










             box {
     < -20, -2, 15 >,
     < 20, -1.9,    -15 >
          pigment {
          color White filter 1
     }
     finish {
          phong 1
          refraction 1.0
     }
     interior {
          ior        1.1
                     }}

                                      box {
     < -20, -1.9, 15 >,
     < 20, -1.8,    -15 >
          pigment {
          color White filter 1
     }
     finish {
          phong 1
          refraction 1.0
     }
     interior {
          ior        1.2
                     }}


             box {
     < -20, -1.8, 15 >,
     < 20, -1.7,    -15 >
          pigment {
          color White filter 1
     }
     finish {
          phong 1
          refraction 1.0
     }
     interior {
          ior        1.3
                     }}


             box {
     < -20, -1.7, 15 >,
     < 20, -1.6,    -15 >
          pigment {
          color White filter 1
     }
     finish {
          phong 1
          refraction 1.0
     }
     interior {
          ior        1.4
                     }}


             box {
     < -20, -1.6, 15 >,
     < 20, -1.5,    -15 >
          pigment {
             color White filter 1
     }
     finish {
          phong 1
          refraction 1.0
     }
     interior {
          ior        1.5





                   }     }
              box {
     < -20, -1.5, 15 >,
     < 20, 100,    -15 >
          pigment {
          color White filter 1
     }
     finish {
          phong 1
          refraction 1.0
     }
     interior {
          ior        1.6
                     }}



                     background {
     color  SkyBlue
}





camera {
     location  -1.5*y - 20*z
     direction 1.3*z
     up        y
     right 4/3*x
     look_at   0*x
}


light_source {
    20*z
     color White
}



------------------------------------------
I know it doesn't look pretty yet! :(I'll keep trying to improve it. especially
the lighting; is there a trick for making a diffuse light source? If someone
has any suggestions I would appriciate it!


Post a reply to this message

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