Monday 31 May 2010

Rendering and Animating AT-ST

Rendering:

With my UV map laid out and exported at a tiff image I was able to render the AT-ST model, the colour of the original AT-ST is a modest grey which is very similar to the default material colour in Maya. I changed the colour to have a hint of green to distinguish it.

To make the model look more interesting I added rust patches to the model. I achieved this by downloading a large picture of rust from Google images. Then with Photoshop, I used the magic wand tool to select specific parts of the rust image and transfer it onto the AT-ST UV map. I also used the warp tool to place the rust as if it were coming from the black detail of the model.
I added black detail to the model as it was a substitute for using polygons, the black detail represents where there was meant to be an extruded face in the model, making it look more mechanical. I also added rivets on the UV map as I drew in one of the conceptual drawings. I did this to add more detail to the model as it previously looked bland.

With the UV map, I was also able to make a bump map to make the rivets and black detail appear raised on the model when rendered. I also made a specula colour map, which affected which parts of the model reflected or absorbed light. I made it so the rust absorbed the light and the metallic grey, reflect the light.
Both the specula colour and bump map work on a grey scale. The varying amount of black or white changes the amount of map effect. I created several versions of the bump map as the raised affect was difficult to get right. I am still not happy with the rivets in particular. If I were to redo the project I would have a gradient on each rivet going from white on the outside to black on the inside, this would give a gradual raised affect like real rivets. However due to time constraints, this was not possible on the actual model.

Below is the final rendered AT-ST model


Animating:

After rendering the AT-ST model, I inserted it into the downloaded CGsphere scene. I found that the only way I could fit the spherical head of the model into the same space as the reference sphere without the legs going through the floor, was to have the model in a crashed position with the head on the floor. I originally wanted to have the model in a resting position, and then animate it walking. To overcome this problem I animated the model walking onto the scene, it then gets lifted up by “the force” and smashed on the ground by a Jedi (which is the perspective camera).

To make the scene look more dramatic, I added a green ambient light and 2 spot lights which were animated to follow the model. This produced dramatic shadows on the back wall of the scene.

To enhance the spherical head I used the reference sphere, deleted half the faces, and added a glow to the material with the sphere image turned off. I then animated it from being out of shot of the perspective camera to being where the head was when it hit the ground within 1 frame.
If I had managed my time in a more effective way, I would have liked to have made some rolling logs out of cylinders which would have made the AT-ST walker trip up like in the film, “The Return of the Jedi”.

Below is the final rendered frame of the AT-ST animation, which is what I hope to send to CGsphere.com



Lighting and texture experiments

This picture bellow shows an ambient occurtion experiment I did in preparation of the bowls.

This picture bellow shows a wodden 3D texture and spotlight experiment.

This picture bellow shows a marble 3D texture experiment and light and shadow experiments, using colours on the opposite side of the spectrum, red and blue. Notice how the shadow also diffuses as it gets further away from the light source.

Sunday 30 May 2010

Bowl UV and Rendering

Putting patterns on the bowls was an easy process as I had already gone through the UV mapping process for the ATST model.

Harry had designed several patterns that he wanted on the main part of the bowls. He only wanted the pattern to be on the main part of the bowls, and a white colour for the lid and label.

I used cylindrical UV mapping to transfer the tiff pattern onto the bowl. It worked quite well as the bowl is basically a modified cylinder. Harry liked the way the pattern stretched near the bottom of the bowl and I only needed to fine tune the top of the pattern to make it look un-stretched.

As the bowls were for a product design, Harry wanted large, high definition tiff images. He wanted the images to look realistic. Therefore I used ambient occursion to shade the images in a realistic way. I also created a cube around the bowl to make it look like a room.

Rendering the different patterns took a long time as there was a lot of fine tuning to get the perspective camera in the correct place. And the number of different patterns added to the time it took to render. Rendering 3 bowls took over 30 minutes to complete.

Below is one of the final images I will submit with the AT-ST walker modelling and animation. The Other pictures are high quality tiffs.

Saturday 29 May 2010

UV Mapping AT-ST

UV mapping is the process of turning the outside of a 3D model into a 2D image. The 2D UV map is able to be exported to other programs like Photoshop, where it can be used to create the colour of the model. The UV map can also be used to create bump maps and specula colour maps to name but a few.

A good analogy to explain UV mapping is to compare it to tailoring a suit. The tailor has to map out on a flat piece of material where the different parts of the suit are going to be, the end product usually contains complicated shapes. The same process is applied to UV mapping but in reverse, you have the 3D product, but you need to make the flattened out version.

You should only really start to UV map when the modelling has been finished. Otherwise you may need to re-map.

The first part of UV mapping is to assign a checker pattern to each object of the model. The checker pattern will usually look stretched or compressed in some places. It wholly depends on what you are modelling.

Maya has several types of read- made UV map modes, Spherical, cylindrical, planar etc. They are very useful if your model contains polygon primitive shapes, like spheres or cylinders. Automatic mapping allows you to fine tune how many faces there are on the UV map. This can be very useful for simple shapes, the more complicated the shapes, for example a mixture of curves and planar surfaces, the more difficult the UV mapping.

For a more complicated model, it may be useful to select a set of faces you want to have as a face on the UV map. Then using the UV editor, manipulate the UV vertices to try and get the checker pattern have a similar amount of the same aspect ratio as possible. This will ensure that images and texture doesn’t look stretched or compressed.

When trying to achieve a similar aspect ratio to the checker pattern, it is advisable to change the scale of the UV’s on the UV editor to make the checkers smaller; with smaller checkers it is possible to identify a finer degree of deformation in the checker pattern.

Due to the nature of UV mapping it is very rare to achieve a perfect aspect ratio to the checker pattern, as long as the checker pattern as a close enough aspect ratio to each other, the textures and/patterns on the model shouldn’t look too distorted.

Modelling my ATST walker was a mixture of easy and difficult UV mapping. The legs for the most part are rectangular; therefore I used automatic 6 sided mapping. The problems occurred in mapping the head and feet sections of the model as they contained both planar and curved surfaces. I selected the faces of each part of the model that I wanted as a section on the UV map, and then used planar mapping. Then on the UV editor I arranged each set of UV faces so I could sew some of the edges of the map together, this ensures that a whole texture will stay on the UV map even if the texture is placed over the edge of 2 UV faces. The shape of my UV map meant I could only sew together a few edges, I ensured that the edges that were sewed were ones most likely to be visible.

Below is the final UV mapped AT-ST model with checker pattern.


Sunday 23 May 2010

Bowls

In the early stages of the project, my friend Harry Cox in 3rd year graphic design approached me to ask if I could produce a set of bowls of his design in a 3D program. The bowls were to have different patterns and lighting affects to make them look like a real product. The products he was designing were Thai soup bowls that you put in the microwave. The pattern on the bowl changes colour when the soup is at the right temperature. The bowls were for his end of degree show and final project. I agreed to make the bowls as I thought it would give me an opportunity to become familiar with Maya, the software in which my current project was based in. Little did I know the amount of time and effort the bowls would take.
The first stage of making the bowls was modelling them, at first I didn’t know how to make as complicated an item as a bowl, I had only experimented with primitive polygons. I watched a Video tutorial on Youtube about how to make a vase; I applied the same principles but implemented them to a bowl shape. They are fundamentally made in the same way.

The bowl started off as a cylinder primitive object, the first stage is to make the base of the bowl very thin, with the top circle of the cylinder far larger than the bottom circle to create a shallow angle. The next stage is to repeat the process of extruding the top circle upwards and increasing the size of the circle, this creates an outwards curve. The middle part of the bowl is relatively vertical so the only thing different in the creating process is not to enlarge the circle after extruding and moving upwards.
To create the lip at the top of the bowl, the circle size is made smaller. As the pictures required for Harry’s product didn’t include the inside of the bowl it didn’t need to be modelled. So the top of the bowl is the top circle of the cylinder. The bowl is in essence a modified cylinder.When creating the bowl I used a set of images Harry made of the bowls on Photoshop.

To create the lid of the bowl I used exactly the same process as the main body of the bowl. The only difference is that the bottom circle of the cylinder is the largest and it sits on the top of the bowl, then the extrusions are made and the top circle is scaled in, to create an inwards curve.
There was a happy accident when creating the lid of the bowl. I was in a rush to get it finished before Harry came to see it. I was supposed to make the lid in a smooth inward curve. What I had made was a lid with two separate curves which created a ridge in the middle of the lid. I decided I would fine tune the centre of the lid after Harry’s visit. However, Harry liked the lid as it resembled a Thai building roof. Therefore it was left the same.
While making the curves of the bowl and the lid, I ensured that there were more vertices to create the look of a smooth curve; the straighter parts of the curve require fewer vertices.

Another way I could have created the bowl was by using a NURBS curve. I could have created the curve of one half of the bowl, then joined the curve at the centre of a primitive cube and extruded the face out along the curve. The next stage would have been to modify the number of subdivisions of the extrusion to make the curve of the cube smooth. Then to create the rest of the bowl using the edge of the curve as the centre pivot point.I used the method of extruding a face of a cube along a NURBS curve to create the piece of card that runs from the lid of the bowl to the base, the card is to display the type of soup, cooking instructions and ingredients of the soup. I found this method useful as it was easy to fine tune and adjust the vertices of the curve and therefore the piece of card.

This picture bellow shows my first attempt at creating a set of bowls; this was before I received the reference pictures from Harry and before I knew he only wanted profile shots of the bowls. That is why I modelled the inside of the bowls. It is more difficult to model the inside of the bowl as you cannot see inside it. If you model in wire frame mode, you cannot see the perspective of the bowl so you cannot know how thick or thin you are making the bowl.
This picture bellow shows the final shape of the bowl complete with “card” label and lid. Once the Model was made, the next stage was to put the patterns designed by Harry on the Bowls via UV mapping. Luckily the day after I finished modelling the bowl was the lesson on textures and UV mapping for the GAD4 project.

Rigging the ATST model

Rigging is putting joints and bones into a model to enable it to animate in a desired way. It enables you to choose at what point the model pivots and/or contorts from.
As my model is a mechanical machine, ideally I didn’t want any contortion of the extremities as they are supposed to be made out of metal.

Skinning does what it sounds like, it turns the outside of the model into a skin, which bends and stretches around the joints and bones. This is better suited to organic things like arms and legs. I tried it on my model but the movement didn’t look mechanical.

The solution to the skinning problem was quite simple, just not to do it. Instead I parented the joints to the models limbs; to achieve this I had to merge the upper knee joint to the middle leg section as they previously shared one joint between them which made a proper leg rotation imposable. With each leg section having one joint, animation was made possible by animating the rotation transforms. The parenting insured the leg always stayed together.

Saturday 22 May 2010

ATST Modelling

Creating the part-spherical head for the ATST was a long process of trial and error. I did some drawings to see which sides could be spherical as well as be recognisable as the Star Wars walker.

The difficulty was the approach to the shape. I tried making a primitive polygon sphere and then modelled the vertices by hand to create the spherical shape. However, this was time consuming, difficult and the fact it was a polygon primitive meant there would be tri’s that are preferably avoidable.

I also experimented with a smoothed cube. The benefit would be an instantly round shape with no tri’s. The smoothed cube was abandoned as I had difficulty modelling the planar sides. The shape of the head is also difficult to model with a smoothed cube as there is an extremity at the bottom of the head, bellow where the laser cannons are. I was working as if the head was a cube, the sides of the head have six sides which need to be included if the shape is to be recognisable as a Star Wars walker.

The way I eventually modelled the head part was by starting off with a cube and making the shape of the head by extruding faces, until a pre-spherical version was made.

The picture bellow was an attempt to make the head by cutting most of the faces of a polygon primitive sphere, leaving the top and bottom section, then connecting them together by extruding the edges. This did not work as there were more edges on the top then there were at the bottom. To make them connect I would have had to have made tri’s which I wanted to avoid as much as possible.

This picture shows how far I took this head attempt. Also notice how there was no way to get planer sides of the head, without changing some of the polygon sphere vertices.

This shows one of the ways I tried to model the spherical part of the head with a lattice. I used the lattice to pull several vertices up at once to get the spherical part of the head. I hardened the edges of where the head normally ends so it would be visible on a render. In retrospect, I should have continued using the lattice. I gave up on it as when I found that moving the model did not move the lattice also. The lattice would stay still and have transform information on the vertices, making them pull in an undesired way. I now know that if I merely parented the lattice to the head, the lattice would take its transform information from the head and so would have not been a problem when the models transforms were changed.

This shows an undivided version of the head model with most of the edges softened. It was an experiment to see how many subdivisions would look acceptable. This was a very early experiment.

This picture shows how I used a semi-transparent sphere as a reference. It enabled me to move the vertices individually to align the head with the sphere. If you look closely you can see some edges poking out of the sphere as the corners are a lighter shade of grey. The change in shade enabled me to know when the vertices were outside of the semi-transparent sphere.

This is shows the way I modelled the body and legs. As the model is completely symmetrical, I only needed to model one half and then mirror and merge the vertices to complete it. This cuts the modelling time in half if done correctly. However I copped the half of the model several times when having problems with parented joints and UV’s.

This is one version of the finished subdivided model. I experimented with hardening and softening edges to be able to distinguish between the original shape of the ATST and the spherical version I had made. However I felt that people should still be able to recognise the shape without the hardened edges. The hardened edges ended up on the top edge of the model, this looked the most “realistic”.

This is another experiment with different hardened edges. It changes the spherical shape of the head greatly. This version gives the impression of a sphere that has been cut into, which I feel looks more affective.
I subdivided the head again and aligned the vertices by hand to make it look even smoother. I should have used the “smooth” tool as you are able to modify the roundness and where the hard edges are. It would also have been better to smooth the head part out, because if I wanted to fine tune the smoothing later, it would have been available in a “Node”. The way I modelled it by hand, made fine tuning it very time consuming.