Rendering Effects Created by Ray Tracing

    In order to examine a number of effects that can be created using ray tracing,  it will be helpful to disccus the topic in terms of a specific example.  Suppose we were to create a scene to raytrace consisting of a single room.  The room is empty except for a single table positioned in the center of the room.  As our light source we introduce one bare 100-watt light bulb which is fixed on the ceiling directly above the center of the table.


    It is easy to see that the ceiling, the walls, and the surface top of the table would be directly illuminated by the light emitted by the bulb.  The majority of the floor in our room would also be "lit" by the bulb, but what about the area directly underneath the table.  There is no ray of light that has a direct path from the bulb to the area below the table, yet we know that if this model were real, the area under the table would still be visible.  Every illuminated surface in the room (in our scene, the ceiling, walls, table top, and the rest of the floor) reflects a portion of the light it receives.  As we trace the paths of these rays about the room, we see that many of the rays eventually illuminate the floor space that is under the table.  The floor space is, as a result, shadowed, but not completely black.  The ray tracing model takes this real-world  effect into account and is capable of rendering images that incorporate realistic shadows.




    Now suppose we add a  highly  reflective surface into our scene.  We can lay a mirror on top of the table.  Now, a much larger portion of the light that directly and indirectly illuminates the table top will be reflected back into the room.  In viewing the room we would notice the reflected images of the walls, ceiling, and bulb appearing in the mirror.  The illumaination effects in the rest of the room, including the area under the table, would also be affected by our addition.






    Transparent objects produce both reflected and transmitted light.  If we were to place a transparent drinking glass on top of a cleared table in our scene, and we  then set a small plastic toy on two sides of the glass, we would notice several things.  Viewing from one side of the glass we would be able to see light transmitted from the object behind the glass. We would also see a reflection in the glass of the object that is on our side of the glass.  We might also notice light transmission and relection of the walls, ceiling, and table top.

A transparent "bubble" enclosed by four colored blocks



    Imagine if we placed a prism onto our table.  (The glass and toys have been removed.)  Much of the light from the bulb would be transmitted through the prism.  The light would be bent at different angles according to its frequency, and the result would be a rainbow effect.  This is an example of refraction.
    Refraction must be considered in order to model realistic transparency effects.  When a ray of light intersects the surface of an object that has some degree of transparency, part of the light is reflected and part is refracted.  This means that instead of "bouncing" off the surface, some of the light continues through the material.  The speed of light differs in different materials, so the path of refracted light is a function of each material and the direction of incident light.  The light is bent, and the image is a distorted view of what we would otherwise expect.  

Table of Contents