|
 |
A cylindrical beam does not refract through media unless the light
source is inside the media container. In the attached frame 1, the
light source is below the media container, just outside the bottom of
the image. In frame 2, the light source is inside the media container.
---%<-----%<-----%<-----%<---[BEGIN CODE]---%<-----%<-----%<-----%<---
#version max (3.7, min (3.8, version));
global_settings
{ assumed_gamma 1
max_trace_level 50
photons { spacing 0.05 autostop 0 media 100 }
}
#declare HALFH = 5;
#declare HALFW = HALFH * 4/3;
#declare DCAM = 25;
camera
{ location vrotate (-DCAM * z, -6 * x)
look_at 0
right 4/3 * x
angle 2 * degrees (atan2 (HALFW, DCAM))
}
box
{ <-HALFW, -HALFH, -6.01>, <HALFW, HALFH, 0.01>
hollow
pigment { rgbt 1 }
interior
{ media
{ scattering { 1, 1 extinction 0 }
method 3
intervals 1
samples 3, 3
aa_level 2
}
}
}
light_source
{ <0, frame_number * 2 - 3 - HALFH, -3>, rgb 1
cylinder radius 0.4 falloff 0.4
parallel point_at <0, 0, -3>
}
prism
{ 0, 6, 4,
<-1, 0>, <1, 1>, <1, -1>, <-1, 0>
hollow
rotate -90 * x
scale <1.5, 1.5, 1>
texture
{ pigment { rgbf 1 }
finish { reflection { 1 fresnel } conserve_energy }
}
interior { ior 1.5 }
photons { target collect off reflection on refraction on }
}
--->%----->%----->%----->%----[END CODE]---->%----->%----->%----->%---
Post a reply to this message
Attachments:
Download 'media_refraction1.jpg' (6 KB)
Download 'media_refraction2.jpg' (7 KB)
Preview of image 'media_refraction1.jpg'

Preview of image 'media_refraction2.jpg'

|
 |