Our inspiration comes from the situation in which the world is right now due to the COVID-19 virus. One thing that affected our student life was the inability to attend our campus, which confined us to our houses. Furthermore, although the presence of mass media helps in spreading information, it also creates a sense of uncertainty and paranoia. In this sense a person can end up suffocating in their own prison which is it’s home. Our project aims to project that feeling, by showing a foggy room with rotten plants and with news of a new quarantine in Saarbrücken (let's hope not). But also it portrays the hope of a better future seen through the window. The gap we need to cross in order to escape is represented by the window ripples. .
We used Blender to model parts of our scene, which were then brought into our renderer and placed appropriately to get the final scene. It all started with our main character “Nathan” who is touching a window. The model was modified in blender to achieve the desired pose. A model of a gas mask is placed on the face of our character to convey the feeling of paranoia. We wanted to create a ripple effect where the hand touched the window. An initial attempt considered a procedural approach, but this was discarded in favor of creating a mesh given that Blender gave us more control over the look of the ripples. We used the canvas/brush tool of blender along with animations to achieve the desired ripples/waves. The animation computation required a very complex mesh which would slow down our renderer, so after getting the desired look we smoothened down the mesh and then reduced the geometry to 5% of the original faces.
We wanted to show rotten and wilting flowers, however we could not find an appropriate 3D model. Therefore, we took a model of blooming flowers and then modified them with the sculpt tool to achieve the desired look. Further we used perlin noise as the bump map as well the color to enhance the wilting effect. Similarly we modified the hygiene mask placed on the table using the sculpt tool to get it into the required pose.
We implemented a glass material for the window in order to make the ripples evident through refraction, show reflection of the character and the view outside. Further, in order to achieve a crude approximation of monte carlo path tracing, we used LambertianMaterials in combination with FuzzyMirrors for the table, cellphone and the newspaper. This allowed our scene to better approximate the contributions from secondary reflective light sources.
To achieve realistic day time lighting, we used a large area light outside the window without a visible solid surface for the source. This gives the illusion that light is being sampled from our environment map. To light up the objects inside the room that are away from the window, we used three area lights to achieve soft shadows and appealing lighting. One light is placed directly above the table, one is placed at the camera and the last one is placed on the wall opposite to the window. The last light allows for our scene to have some false ambient lighting.
We noticed that many areas of our images had very low noise even at low samples. This meant that a lot of computation would go waste if we raised the global sampling count. To combat this, we implemented a variance aware sampling strategy, in which we specify the maximum number of allowed samples and a variance threshold. If the variance of a specific pixel falls below the provided threshold, we can stop sampling that pixel.
Bump mapping was used to give the walls bumps and wrinkles rather than maintaining a smooth surface. Many of our assets (such as the character) did not have height/bump maps, rather only normal maps. Thus, to render these models properly we implemented a primitive NormalMapper which directly modifies the normals of the solid based on a map. Additionally the whole scene is wrapped inside an environment map. In this sense by looking outside through the window we are able to appreciate the image of a landscape
It was used to give texture to the flowers. One type of noise was used for the petals while another type of noise was used to create the texture of the stem. The bump maps for these objects have also been generated through perlin noise.
We used this technique to better approximate the contributions from secondary reflective light sources. This can be observed on the table, as it presents certain reflections. This gives it a look of a polished material.
We wanted to implement a fog effect to empathize with the theme of being locked up as a way of suffocating a person. In order to achieve it we implemented a homogeneous volume, in which light rays could be attenuated and scattered. Besides achieving a fog effect, thanks to the (simulated) scattering of particles the scene achieved more brightness without the need of more lights. This also helped create the effect of shadow rays.
To make full use of the available compute power we parallelized our renderer using std::thread library. Each of the 16 threads was provided a start column offset, and in each iteration the threads increment the loop by 16 instead of 1. Thus effectively we process batches of 16 pixel columns at once.
To effectively incorporate volume rendering a new integrator was implemented. Given that in order to change a light beam either by attenuation or scattering we need to sample distances throughout its direction, a ray marching loop was implemented only when a ray intersects a medium object.
In order to achieve volume rendering a medium primitive was created. This allows a solid to contain inside of it a certain type of medium like fog. Through this interface the integrator could get the transmittance and emission of the particles which helped simulate the scattering and attenuation effect on a light beam.