



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
The concepts of shadows, specular reflections, and refractive transmission in the context of ray tracing. It covers the phong illumination model, the importance of recursively tracing rays, and the calculation of refracted directions. The document also discusses the limitations of opengl's support for transparency and the importance of snell's law in refraction.
Typology: Study notes
1 / 6
This page cannot be seen from the preview
Don't miss anything!




diffuse reflection all lights
specular highlight
(^
n )
L^ d
L^ s
L I^
I k
I k
â
n L
r v
n θ
v r Ď
Air
Glass
Air
where
are indices of refraction
sinsin
i^
t ti t^
i
θ
Ρ Ρ
Ρ
θ
Ρ =^
n i θ
θ^^ t
Material
Index of Refraction
vacuum
ice
water
ethyl alcohol
glass
diamond
vector
With a little math, we can derive the transmitted direction
sinsin
i^
t ti t^
i
θ
Ρ Ρ θ
Ρ =^
n i θ
θ^^ t
where
and
(^
cos
i
i
t
c^
c
c Ρ^
Ρ
Ρ^
Ρ
θ
Ρ^
Ρ
2
2
n n I
θ^ i
θ^ t
critical
critical
where
sin
t
i
Ρ i
θ^
θ
θ^
â1 Ρ
eye ray
reflected
ray
shadowray transmitted ray
a lot
of rays
k^ yields
k 2
rays traced per eye ray
not
shadow rays
Consider this example
point x = r(t)rgbColor color = blackfor each light source L if( closest_hit(shadow_ray(x, L)) >= distance(L) )
color += shade_phong(s, x) color += k_specular * trace(reflected_ray(s,r,x))color += k_transmit * trace(transmitted_ray(s,r,x))return color What does this simulate?
nothing
to do with parallel computation over a network
Simulate phenomena by distributing multiple rays