Showing posts with label contour. Show all posts
Showing posts with label contour. Show all posts

Sunday, April 29, 2012

The cartoon style render of Iron Giant.


I tried the look of Iron Giant, the masterpiece, using the Mental ray's contour rendering feature.



 Here are the reference images from the movie.






The characteristics of the look in rendering the robot is the cartoonish shading and the ink line rendering.
You can easily achieve these effects.  
I use the Ramp shader for the two tone cartoonish shading and the contour rendering feature for the ink line.


 
I adjusted the color attribute so that I get two tone shading on the surface. Normalized Brightness is used for Color Input. I also turned off the specularity completely for a diffusive look.
Then I turn on Enable Contour Rendering option and set the color and the line width in the ramp shader's shading group node.

 I duplicated this shader a couple of times and tweaked the colors a bit and used them for other parts of the body.
If I render now I get the following look. I used one directional light with the raytraced shadow on.


Next, I move on to the contour rendering feature.


 
With the Between different instances option on only, the render looks like below.


I get lines around the silhouette and between objects.  Now I need lines inside of objects where there are hard edges. For this, I turned on Enable Normal Contrast and set the value to 7.0.
This will reveal more details.


The render result.


 Finished!




Saturday, April 14, 2012

How to make Mental ray's tessellation match Maya's tessellation in Nurbs.

When you use nurbs surface, from time to time, you might want to how its tessellation.
You can simply turn on Display Render Tessellation option under Tessellation section in the attribute editor to see it. But that's for Maya software render and  doesn't necessarily match Mental ray's tessellation.  To be able to mental ray's tessellation, you need to use Mental ray's contour rendering feature.
Here I have two simple nurbs sphere. For comparison,  I turned on Display Render Tessellation option
for the sphere on the right side. And I also turned on Enable Advanced Tessellation. This is to explicitly assign the number of tessellation for each span for the sphere.




 
Next, I will create a new surface shader and assign it to the sphere on the right. This shader is for contour line.  After the shader assignment, select the shader's shading group node and open the attribute editor.