Sunday, 15 May 2011

Clock Render/Problems and Solutions

























Here are some screen grabs of the clock close up shot were the clock strikes 12. Initially I thought that rendering this scene was going` to be easy, however the combination of mental ray settings, large textures as well as the resolution of the image combined made the render take much longer than expected. I really don't understand why the render took so long, there were no other files or programs open.

The render itself took two days to complete and this of course slowed down production and prevented me from starting the UV maps for the character. Looking at the animation it, it seems a little too fast. Its too quick on the eye. This will have to be slowed down. I need to find out how to speed up the render if we have to do it again.

Monday, 2 May 2011

Glass/ Dielectric Material

When working on Chris’s scene, which included the glass, I realized the importance of Hdri mapping as well as a sky dome. We tried to render realistic glass using a dielectric material. However, when we initially rendered the scene without a sky dome the glass appeared very dark, almost opaque. This was due to two reasons. The first was the fact that we had not created a sky dome, which would help reflect light back to the glass. In Maya when you render a scene everything outside the scene is rendered as black. So we needed some kind of surface or HDRI, which reflected some colour back. This would solve part of the issue. Another technique was to change the ray tracing values so that they could pass through multiple surfaces allowing the majority of the glass to be illuminated causing refractions of light needed for caustics.

Following some newly acquired tutorials we rectified the problem of the glass appearing opaque. However when we rendered the scene a weird oval shape appeared at the bottom of the glass, which looked very wrong indeed. I suggested that Chris change the camera angle as this issue could have been caused by the refractions within the glass at that particular angle. We rendered the scene again and this seemed to do the trick. There are a few more issues that need addressing as the render is far from perfect. However, I am confident that these minor issues can be dealt with in post. Currently there are strong reflections on the surface of the table that look unrealistic in context with the actual illumination in the scene.

When creating Chris's glass scene we wanted the shot to look as appealing and as realistic as possible. The glass material needed to have that transparent quality, while still allowing refraction to take place. We also wanted to replicate caustics, an effect that occurs in reality when light rays pass through glass and are refracted. Refraction is caused by the change in density between air and glass. This effect also causes patterns to form as the light is reflected and refracted inside the glass. Creating this effect in maya can be achieved, however, I needed some tutorials to point me in the right direction.I found a tutorial that showed me how to create a glass ornament using mia’s dialectric material that simulates the refractive qualities of thick glass which is what Chris wanted.

Although the tutorial dealt with a different shaped glass than the one we wanted to use the principles were still the same. At this point in time I was unaware of what material I should be using to create a glass material. I started out by creating a plane that would form the ground plane. I then create the simple glass ornament that was suspended by a tripod. I began following the tutorial rigorously to create the glass material. Initially I applied a blinn to the object that would eventually be the glass. I then opened up the blinns output settings and changed them to a dielectric material that would simulate glass. I rendered the scene but realised that there was no light and no caustics.

Caustics is a way in which Maya simulates the way in which light passes through a glass object and refracts onto a surface. This can be seen when a glass material is light and forms light patterns beneath the glass. To create this effect I needed to flood the scene with photons, which simulate realistic light rays that will help create the caustics effect. First I created a simple area light that will create my primary and only light source. Once the light was in place I created an additional light that would produce the photons necessary for caustics. I then configured all the necessary render settings to render the glass. I was amazed at the result. The photons simulated real refraction perfectly. If we could get the glass in our scene to look this good it would be an achievement. I did realise that the glass did not seem to reflect the white light source. An object that is reflective should show indications of where the light is coming from as bright highlights. I could not understand why this was happening. But I had an idea.

I proposed to render exactly the same scene but changing the glass material to a reflective metal of some kind. By doing this I could acquire some realistic reflections that I could lay over the glass material in Photoshop by compositing individual layers. I did three passes, which included cpolour, occlusion and reflection. Although the renders collectively consumed one day the results acquire would be more than satisfactory. I have discovered that rendering glass with GI and caustics takes considerable amounts of time to render. This is due to the way in which Maya has to do many calculations in order to simulate real lighting. It has to consider material density, reflection, and refraction as well a bounce light. All these attributed increase render time dramatically. Unfortunately I do not posses a desktop computer, which would have sped up the render process. However, the technique proved to be quite effective and the result was very impressive. I will now apply what I have learnt in this tutorial to our scene and adhering to all the necessary render settings and lighting setup to make this render work.

Below are some glass render tests as well as a render for a shot in Chris's film. I was very happy with the results as I had created some very realistic effects. Considering I had no knowledge in creating glass prior to these tests I think I have shown tremendous determination in overcoming these technical obstacles.





Hat Miss

The images below depict a scene in which Frank throws a playing card into a hat. Chris set up the scene in maya and blocked out the shot. I went in and created area lights in the scene which would illuminate the animation taking place. It was important to get the light levels right as this sequence was more symbolic. The card represents the woman he loves as she escapes from his grasp. The scene represent the forbidden love for a woman that ends up being his next target and is ironic. So the lighting needs to be just right for the viewer to understand the significance of the scene and what it is conveying.

The lighting in the scene was purely fiction and unrealistic but adds to the theatricality of the piece. The animation was fairly straight forward as it was just a case of moving the card into the right position and giving it a little twist to replicate some sort of air resistance. Chris added a nice bit of secondary animation where the hat moves as the card is in contact with the rim. Chris and I both agreed the animation was sufficient for the needs of the shot and I set about rendering the shot ready for Joe to composite.


Exterior Shot

I really enjoyed doing these images. These renders will form the final shot of the film where we see the protagonist exit the apartment and go off into the night. This building will be in the background as the character walks off camera. I had modeled the exterior early in the production but now it was time to light the scene according to Chris's storyboards.

I created some area yellow area lights which would emit the warm glow created by the sodium lamps on the street. I made sure that the light had a linear decay so that it would not cause over exposure. I also made sure that the lights had ray tracing capability so that the light would not pass through objects. This was vital in this scene as the scene would take place at night. Once I had the sodium lights in place I adjusted the intensity so as not to illuminate too much. The scene was supposed to be dark and gloomy as the main character sets off for his next hit. The lighting had to enforce this and describe visually what the character was feeling emotionally.

Chris wanted an extra light source coming from a hotel sign which would help suggest that the character was renting an apartment. The blue tones of the glowing sign would also soften the reds of the brick facades.

The images below show some of the more early light tests using mental ray as well as the positioning of the hotel sign. We decided to move the sign to the left of the image so that it would not be too jarring on the eye. While setting up the scene I was always mindful of the positioning of the camera as well as certain objects in the scene and the way in which the light would interact with the various surfaces. Once I was happy with the layout of the scene as well as the lighting I began to render a colour and occlusion pass.
















































The images below show the finalised exterior shot and composite. I also added a chemist sign which I felt gave some more focus to the shot as well as colour and it looks cool too. I very much enjoyed this process and the results far exceeded my expectations. Plus this shot was completed within a day.





The Sig Sauer Shot

I had modeled the pistol very early on in the production process but I now needed to texture it ready for rendering. Setting up the scene was fairly straight forward as I created a plane, which would depict the wooden table in the film. I would rest the pistol as well as the silencer on that plane. I added some fairly detailed textures to the plane that Chris created using Photoshop. The key to the shot would be decent textures, bump mapping and excellent use of lighting. I applied some basic blinn textures to the gun as I had tried previously to add textures, which had some scratches but looked terrible and would add to render time significantly. I implemented a three-point lighting system that would highlight specific areas of interest within the image. I also brought in a blue rime light to give the still shot a more moody feel that added some dynamism to the image. I frequently rendered the image to see if any areas needed changing and that the lighting and composition were correct.

I realized that the scene needed something else to balance the image. The shot itself is an important one, as Frank feels reluctant to continue his trade. The gun is a symbol of his violent crimes and the victims he has killed. I added some bullets in the scene, which not only help focus the viewer’s attention but also brings a sinister element to the shot. I added a brass and copper blinn to the bullets that would reflect light on the whole scene. Initially I was happy with the scene. However, the gun needed some more detail to make it more believable.

The grip needed a bump and at the start I was concerned how I was going to apply it to a specific part of the gun. I had tried several times before to apply a bump but these attempts failed and just looked struck on. I then had a brain wave and decided to construct the bump using Maya rather than acquiring images from the Internet. There is a specific area where the bump needed to be applied that consisted of small interlocking diamonds that would form the handgrip. To do this I opened a new scene in Maya and created several diamonds and cloned them to form a square lattice. I then applied created a camera, which faced these objects directly. I then rendered the scene in 1080p and imported the image into Photoshop so I could convert it to a jpg file that would be small but detailed enough to create a bump sufficient for the grip.

I then opened the Sig Sauer scene and selected the faces necessary for texturing and planar mapping. By planar mapping the grip area I would ensure that the bump, when applied would not stretch. I was very happy with the results as the bump reflected some of the light created from the area light in the scene. I rendered the scene with shadows and I also rendered an occlusion layer in mental ray that would create some ambient shadows in specific areas. I then imported these renders into Photoshop as psd files and began to composite the image. I realized that the gun needed some scratches and dents to imply that the pistol had been used many times before. At this stage the gun looked too shiny and pristine. I used a variety of brushes to add scratches and imperfections, which would make the whole scene more believable. In the final stages of the composition process I added some sharpen filters that would help define the edges of different surfaces and make the overall image crisper. I was very happy with the final result as well as the visual look of the scene. I paid careful attention to the storyboard and constantly had a vision in my mind of how I wanted the shot to look. By having a goal I was able to create a very specific image that would tell part of the story. The rendering did take a long time but this was worth it as the results far exceeded my expectations and the expectations of the director. It was very important to acquire an emotional aspect to the shot that would help tell the story and reflect the emotional struggle of the main character. During this process I learnt that lighting is extremely important in creating a visually beautiful image as well as good composition. But I suppose the most important thing I gained from this little exercise was the ability to use Maya to create textures. I was able to create accurate textures, which could be applied to my models at a very fast rate. I will use this technique in the future, especially when creating repeating patterns.




Thursday, 7 April 2011

Creating clothing

So here is the progress I have been making with the clothing. So far so good. The geometry when smoothed looks pretty good and matches the form of the character. My only worry is how this will be rigged as it is separate from the character, I'm afraid I don't know enough about character modeling and rigging to know if this will be a problem.

Today I set about crating the vest trousers and jacket. When creating the vest and jacket in maya I realised I could use existing body geometry and alter the mesh to create clothing.
Originally the mesh was only 1 polygon thick but I decided to add a little thickness to the clothes so that it did not look too computer generated. I tried to keep the polygon count low which would reduce memory and frame loss. This should make things easier when animating.

Some of the images show the wireframe which had to be as clean as possible to prevent polygon tearing in the rigging process.

When modeling the trousers I used the same technique of duplicating the body and cutting out the necessary geometry. This technique proved to be highly effective as I was able to create the objects quickly which would save time but would also match the body geometry. I was pleased with the results however, they do appear somewhat flat. Im sure with appropriate textures this will improve this.






The arms and deltoid muscels


I have begun modeling the base mesh for the main character in the short animation I am currently working on and I will admit that I know little about the construction of a character in maya. When I spoke to Clym recently he suggested that I look online for tutorials and images on topology. Topology is necessary for good polygonal flow, which is crucial when trying to rig and animate the character effectively. If there is no edge flow when creating the model this will not simulate muscle and bone structure that is necessary for locomotion. I was pretty pleased with the outcome of the torso region as this represented all the characteristics of the concepts while at the same time maintaining good edge flow. However as I began to model the upper arm or deltoid muscles I noticed that there was no real muscle definition. Clym kindly pointed me in the right direction. In order for the arm to move correctly when animated I need to define the deltoid muscle. He also said that I needed to create a pauldron shape like a piece of armour. This would be ideal when rigging the character as well as bringing out muscle tone in zbrush. In order to create the muscle structure I needed a five-edged star. This would help me redirect the polygon flow to create a spherical mass, which would form the deltoid. The five-edged star would allow polygons to flow in three direction instead two which is necessary for this type of modeling.

I applied this technique to my model, which proved to be successful. When smoothed muscle tone and definition could be observed which was the effect I was looking for.