|
|
I've been trying to produce a scene with a laser illuminating a solid sample
from above. The laser is focused with a lens onto the sample surface. The laser
itself is implemented as a cylindrical light source with refraction and
reflection on, and scattering turned on in global medium to enable me to see the
laser.
I can see the scattering of the laser up to the lens, but cannot see the laser
afterward - see https://i.imgur.com/bpgSD0t.png. However, I can see the focused
laser spot on the substrate surface, so the photons must be getting through,
they're just not visible. I can solve this by defining a cylinder between the
substrate and the lens which also scatters light, but I'd like not to have to.
If anyone has any suggestions on how to solve this, please let me know! The
scene file is as follows:
#version 3.7;
#include "colors.inc"
#include "glass.inc"
global_settings {
ambient_light rgb<1, 1, 1>
assumed_gamma 1.0
photons {
spacing 0.005
autostop 1
media 200
max_trace_level 200
radius 0.0025
}
}
background{rgbf<1, 1, 1,1>}
camera {
right x*image_width/image_height
location <-5,3.,-5>*1.3
look_at <0, 0, 0>
}
// illuminate scene
light_source{
<-5,3,-5>*1.4
color rgb <1, 1, 1>*2
adaptive 1
jitter
shadowless
}
// enable photon scattering in global medium
media {
scattering {
1,
rgb <0.1, 0.1, 0.1>
extinction 0.0000001
}
samples 100,200
}
// laser
light_source {
<0, 10, 0>
color Green*4
cylinder
point_at <0, 0, 0>
radius .1
falloff .5
tightness .5
photons {
reflection on
refraction on
}
}
// material properties for solid
#declare F_substrate = finish {
phong 0.01
phong_size 1000
specular 0.5
diffuse .4
}
#declare N_substrate = normal {
bumps 0
turbulence 0
scale 1
}
#declare I_substrate = interior {
ior 2.42
caustics 2
dispersion 1.041
dispersion_samples 50
}
#declare M_substrate = material {
texture {
pigment {rgb<0,0.4,0.7> transmit 0.55}
finish {F_substrate}
normal {N_substrate}
}
interior {I_substrate}
}
// bi-convex lens
#declare R = 3;
#declare Over= 0.2;
intersection {
sphere {
<0,0,0>,
R
translate <0,-R+Over,0>
}
sphere {
<0,0,0>,
R
translate <0,R-Over,0>
}
cylinder {
<0,-R,0>
<0,R,0>
0.5
}
texture {
pigment { color rgbf <0.98, 1.0, 0.99, 0.75> }
finish { F_Glass3 }
}
interior { I_Glass3 }
translate <0,3,0>
photons {
target
reflection on
refraction on
}
rotate<0,200,0>
}
// substrate
box {
<-2,-0.2,-4>, <2,0,4>
material { M_substrate }
photons {
target
reflection on
refraction on
}
}
Post a reply to this message
|
|