// 1/19/26 // Kenneth Walker #version 3.7; // or 3.8 global_settings { assumed_gamma 1 max_trace_level 5 photons { spacing .005 // .0035 // autostop .01 // [Is this working?] // adc_bailout .1 // [Does not appear to be working, at least in 3.8 beta 1] } } #declare SPOTLIGHT_INSTEAD = off; // Otherwise, a point_light with a special shadow-mask object //------------- background{rgb .02} camera { perspective location <-2.2, .1, -15> //<-2.2, .1, -13> look_at <-3.5, -3, 0> // originally <1.5, 0, 0> right x*image_width/image_height angle 67 } /* // test camera looking down camera { orthographic location <-7, 45, -.8> look_at <-7, 0, -.7999> right x*image_width/image_height angle 35 } */ //-------------- light_source { 0*x color rgb 1 #if(SPOTLIGHT_INSTEAD) spotlight radius 28 falloff 28 tightness 0 point_at <1,-.75,0> #else #end looks_like{ sphere{0,.1 pigment{rgb 1} finish{ambient 1 emission 0 diffuse 0} } } photons { reflection on refraction off } translate <-.1,2.9,-2.1> } //-------------- // SMALL LIGHT-SHADOWING OBJECT UNDER LIGHT (if a spotlight is NOT used above) to block // the 'collector' surfaces from the light_source, so that the *direct* light does not // swamp the photon caustic effects: #if(!SPOTLIGHT_INSTEAD) union{ box{0,1 scale <.7,0.1,4> } box{0,1 scale <.1,3,4> translate <0,0,0>} box{0,1 scale <1.35,3,.1> translate <0,0,4.0>} translate <-.57,2.3,-4.1> pigment{rgb .5} photons{reflection off refraction off collect off} // 'target' is off by default } #else #end //----------- /* // ---for testing the photons{pass_through on/off} flag ---- // an INTERVENING flat box *between* the photon-enabled light_source and the 'target' box{0,1 translate -.5 scale <.1,2.5,6> translate <.3,1.9,-2> texture{ pigment{rgbt <1,1,1,.95>} // or OPAGUE rgb 1-- then pass_through ON does not work finish{ambient .5 emission 0 diffuse .5} } photons{ // 'target' is off by default collect off refraction off reflection off pass_through on // on/off works as expected-- UNLESS you // also use no_shadow; then pass_through OFF does not work, but should. } //no_shadow } */ //------------------ // reflection TARGET, to RIGHT of light_source box { // opague 0,1 translate -.5 scale <.3,5,4.8> rotate -7*z rotate 8*y translate <2.5,.4,-2.2> pigment {rgb <1,0,0>} // RED, as test finish{ambient .05 emission 0 diffuse .2 reflection .75*<0,1,0>} // GREEN REFLECTION normal{bumps scale .3 bump_size .7} photons { target 1.0 reflection on refraction off collect off } // no_shadow // no_image } //------------------- // The UPPER photon 'collector' surface box { 0,1 scale <7,.2,5.5> translate <-4.8,-2.7,-4.9> texture{ pigment {rgb 1} finish{ambient 0 emission 0 diffuse 1} } photons{ //target off // off by default collect on // If no_shadow is used, turn this OFF to prevent **SLOW** render of this box! } // no_shadow // ***SLOWS DOWN*** the render of *this* object; needs 'collect off' to fix that-- or no_image no_image } //------------- // The LOWER 'collector' surface under the above collector, plus walls union{ box{0,1 translate <-.5,0,-.5> scale <60,.1,100> } box{0,1 translate <-.5,0,-.5> scale <.3,20,100> translate -15*x } box{0,1 translate <-.5,0,-.5> scale <32,20,.3> translate <-10,0,15> } translate <-4,-5.0,0> texture{ pigment{cells scale 1.5 color_map{[0 rgb 1][1 rgb 2]}} finish{ambient .03 emission 0 diffuse .97} } photons{ //target off // off by default collect on } }