Image Synthesis - Final Project


Samir Roy
sr4z@virginia.edu


Description:
The final image is quite different from my originally planned image. I started off trying to model the original image of Escher holding a glass sphere. I was able to obtain a model of a man. Using Poser, I modelled the man sitting down, holding a glass sphere in his extended hand. I exported the scene into RIB and tried rendering it with LRT, but it couldn't read the RIB file. I also tried exporting it to 3D Studio Max, and then exporting it to RIB using 3D Studio Max, but that did not work either.

Next, I tried using the backup image presented in the proposal. This second image was not only harder to model, but also did not suit itself very well to demonstrating subsurface scattering. Thus, I found another image by Escher, consisting of a leaf with a dew drop (shown below). I wanted to show light bleeding through the leaf due to subsurface scattering. Since I was not able to export 3D Studio Max scenes into LRT, I tried using Moonlight. I modelled the leaf in Moonlight, but was unable to bend the leaf, so it was flat. I was also unable to export texture maps and texture coordinates to RIB files. Also, some of the polygons and nurbs surfaces were rendered incorrectly in LRT, due to degenerate triangles, and the leaf did not look as smooth. Thus, I had to abandon that idea as well.

Thus, after having wasted enormous amounts of time in trying to learn modelling software and trying to model the scenes, I decided to take up something with simple models and concentrate my efforts to the programming part of the assignment. An image by Escher consists of a table with three spheres on it. I decided to use that image (shown below) as it consisted of simple models.

I decided to take two different approaches for subsurface scattering for two different types of materials. I treated materials that are more towards the transparent side than the opaque side different from the ones that are more opaque.

To model the ones that are more transparent, I extended the glass material. You can add three parameters to the glass - subsurface, probability and die. The probability tells you the probability of a particle hitting something inside the surface and deflecting. The subsurface value tells you how much it is deflected by, and the third value, die, tells you the probability that the particle gets absorbed by the surface.

I extended the photonmap integrator in order to do this. Support for image based lighting and caustics was already added to the system during an earlier assignment. In order to add subsurface scattering, I obtained the three parameters from the material and used that to deflect the rays. During the second stage of phtonmapping, i.e. whitted lighting, when a ray bounces off a specular surface, it is deflected by sampling a uniform hemisphere using the subsurface parameter. The photons for photonmapping were also deflected using the same principle.

For the second type of translucent materials, I followed a method similar to Henrik's method described in his photonmapping book. The difference is that in place of depositing photons in the volume of the objects, I project them onto the surface, and the photons get deposited on the surface of the objects. I introduced this hack so as to use the existing integrator, which assumes that the local geometry is flat and thus photons are only deposited on the surfaces and a disk is used to collect them.

In order to define the surface of the table, I added to the brushed metal and matte materials, a brdf which is similar to the specular reflection brdf in the glass material.

Note that translucent objects such as frosted glass are simulated using the second (opaque) type of material by setting the diffuse value low. The first (transparent) type of translucent materials are used for objects such as lemony water, or transparent materials with a opaque particles / particles with different refractive indices in them (like minute air bubbles in water). water)


Results:


A dark translucent object (of type 2), with image based lighting as well as a light behind the sphere. One can see the light bleeding through the side of the sphere and can be seen in front. Also, the other side of the sphere can be seen illuminated in the reflection on the plane. The plane is the modified matte material. The reflection of the sphere and the environment can be seen in it, though it is not completely specular, as shadows can also be seen on it.


A milky glass kind of an effect using subsurface scattering in glass. The white dot in the shadow is because I only shot 10 photons into the scene


A frosted glass type of an effect using opaque type translucent objects and a low diffuse value. The plane on the bottom is the modified brushed metal material.


A glass ball with subsurface scattering as well as specular reflection.


A regular crystal ball


Finally, a glass ball with subsurface scattering.


Code: code.tar.gz


The models that I could not create / could not import into LRT:

leafdew.mlk
leafdew.rib
leaf_thick.mlk
man.3ds
man.pz3
man.rib