POV-Ray : Newsgroups : povray.advanced-users : caustics and fog (photon mapping with scattering media) : caustics and fog (photon mapping with scattering media) Server Time
1 Jul 2024 06:10:17 EDT (-0400)
  caustics and fog (photon mapping with scattering media)  
From: ghostch
Date: 2 Feb 2010 14:55:01
Message: <web.4b688106814e79f9129802db0@news.povray.org>
Hi!
What I want to do is having a glass- sphere with refraction-interior to focus
light rays emitted by a simple point light. The refraction is causing
nice caustics on the ground below the sphere. Now I wanted to add "ground fog"
to the scene in order to make the focussed light beam visible. I am using a box
as containing object placed somewhere around the area where the caustics
appeared.
However, when the fog is there, it does not seem to interact with the photons in
any way. There is only the shadow cast by the sphere. I am completely missing
the caustics on the floor also.
Hope anyone can explain.. Here is my code.


global_settings{
   photons{
        spacing 0.1
     radius  0.5
     //autostop 0
     media 100

 }
   max_trace_level 16 // increase value to avoid black spots
}

#include "textures.inc"

#declare cam_pos = <-100, 50, 100>;
#declare cam_look_at = <50, 50, 100>;
#declare cam_sky = <0, 1, 0>;

#declare FreeSurfaceTexture = texture{
    pigment{
        rgbt 1
        }
    finish {
        ambient 0.05
        diffuse 0.25
        brilliance 6.0
        phong 0.8
        phong_size 120
        reflection { 0.01, 0.7 }
    }
}

#declare WaterInterior = interior{
   ior 1.35
   dispersion 1.03
   media {
     absorption 0.001
   }
}

camera{
location cam_pos
look_at cam_look_at
sky cam_sky
}

// the ground
plane {
   <0,1,0>, 0
         texture{Polished_Chrome
              pigment{ color rgb 0.7*<0.7,1,0.7>}
              normal { crackle 0.75 turbulence 0.25 scale 0.25}
              finish { diffuse 0.9}
       scale 40
 }
}

// a wall
box {
    <0,0,200>,<100,100,210>

    texture {
       Red_Marble
       scale 8
    }
    normal {
       agate
       scale 8
    }
}


// the sphere
sphere{
<50,50,100>,33
texture {
   FreeSurfaceTexture
}interior{
 WaterInterior
}
photons{
 target
 reflection on
 refraction on
 collect off
}
hollow
}

// the fog
box{
 <1,1,99>,<99,15,199>
 pigment { rgbf 1 }
 hollow
 photons { pass_through  }

 interior{
  media{
     scattering {
      1, 0.01
 extinction 0.01
     }
  }
 }
}


light_source{
   <0,120,0>, color rgbf 0.9
   adaptive 1
}


Post a reply to this message

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