clic to reload the forum home - Cliquez pour recharger le forum
The homepage Blog in englishLe blog de la page d'accueilVisit the english language forum!Allez directement au forum françaisGo to the gallery! - Allez visiter la galerie !The files to download - textures, softwares, etc.Les fichiers à télécharger : textures, logiciels, etc.3D and 2D challenges!Come and talk together in realtime - Venez tous discuter ensemble !About Polyloop.netA propos de Polyloop.net
Go Back   Polyloop - 3D & 2D Forums > English > Tutorials > Carrara tutorials
Register FAQDonate Image Hosting Members List Calendar Search Today's Posts Mark Forums Read
Carrara tutorials Find all the tutorials for Carrara inside this forum
Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old 16th November 2005, 14:59   #1 (permalink)
Always learning new stuff
 
Thomas's Avatar
 
Join Date: Jul 2002
Location: Merignac, France
Posts: 10,951
My Photos: (198)
Images: 93
Send a message via ICQ to Thomas Send a message via MSN to Thomas
Modeling a candle and creating a realistic wax shader with Carrara 5

With this tutorial, we are going to show how to model a candle in the Carrara 5 Vertex Modeler, set-up appropriate lighting and, more specifically, how to create a realistic wax material thanks to the new Subsurface Scattering.

At the end of this tutorial, you will be able to download a video that summarizes the whole process. Please note that this video has been shortened to be 15 minutes long (real time: 40 minutes), and in doing so some redundant parts of modeling and render tests have been deleted or accelerated.


Part One: Modeling the Candle
 

Let's start by inserting a polygonal object in the scene, in the Assembly Room.


This action opens the Vertex Modeler, in which we are going to build our candle. Since the body of a candle looks like a deformed cylinder, let's insert a Cylinder which we'll find in the Primitives pull-down menu (first left icon in the menu).


Once the element is positioned, we can refine the definition (the quality) of the cylinder, thanks to the +/- keys on the numeric keypad. For this tutorial, a value of 4 is fine. It is now time to change the proportions of the cylinder a bit, to give it a shape more like a candle, so we’ll stretch its height. For that purpose, let's use the Universal Manipulator, by clicking on the small cube on the top of the Z-axis (the blue one).

Left, the original cylinder; right, the modified cylinder by clicking on the small blue cube of the Universal Manipulator. (Surrounded above, and dashed, because it is located inside the 3D volume).

We are now going to work on this cylinder. As you know, the top of a candle is a hollow, because of the heat that makes the wax melt. We are going to use the Dynamic Extrusion Tool to modify the top of the candle and to form a hollow. Let's select the face to extrude (the top cap), then take the Dynamic Extrusion Tool and create an insert toward the center, then to the bottom, then again toward the center.

From left to right, the steps of the extrusion : 1- Face selection / 2- Inset Extrusion / 3- Down Extrusion / 4- Inset Extrusion.

Now, smooth the body of the candle, to work with a result close to the final shape. Caution: some edges are automatically creased, shown in yellow, and visible on the below snapshots. They will generate unwanted breaks when smoothing the shape and we must force them to be smoothed. If the faces of the cylinder are not selected, select them all, then go to the "Model" menu and choose "Smooth Edges". Do not modify the default value, just validate.
To apply smoothing, we go to the Properties panel, on the right of the screen, and we choose, in the Modeling tab (the first one), in the "Subdivision" properties, "Smooth". Define "1" as the value for the Modeling (the smoothing level that is used to display the shape in the 3D working area), and "2" as the value for the Rendering. This value will be used only at rendering time, and will increase the quality (and the number of polygons) of the model only for the image calculation, which saves time during the modeling process.

From left to right, the smoothing steps: 1- Smoothing edges. 2- Validate all smoothed. 3- Smoothing quality. 4- Result.

Let's continue to modify the structure of our candle. The smoothing has "corroded" the angles a bit and we need to refine that part by adding some polygons. The easiest way is to apply a Bevel on the inside and outside contours of the top that we extruded two steps earlier.
Let's select one single edge, and then select the whole contour with the "Loop" selection tool, and repeat the operation on the other top contour and finally, apply the Bevel to this multi-selection, as shown in the below snapshots.

Top: 1- One selected edge then "Loop". 2- The "Loop" selection tool result. 3 - The same operation done on the other contour.
Bottom: 4- The "Bevel" applied. 5- The result.

For future needs, we are going to modify the working plane positioning mode. As you certainly know, in Carrara the 3D creation and manipulations are performed according to a defined plane: front, left or top, that can be toggled by clicking on the corresponding faces of the Working Plane icon: The default mode is often the best, but in the case of quick vertex modeling of visual editing, this may not be the most convenient way to work. Carrara 5 now has an automatic mode, which defines the working plane as the most perpendicular to the view. Let's activate it by opening the "View" top menu, then "Most Ortho Plane Mode". Note: In the video, this mode is activate from the beginning.


It is now time to give a more natural style to our candle, by moving several faces and vertices, utilizing the "Universal Manipulator". The action mode is very easy: with the Manipulator, directly drag-and-drop the chosen face, edge or point. This will move your selection according to the most perpendicular plane. You can, of course, use the Manipulator to perform constrained displacements.
The snapshots below show different steps of the model edition.


Finally, the last big step of modeling is the creation of the wax that has flowed along the candle's body. We are going to explain this step only once, which you will then replicate several times.
Let's first select a vertical edge, near the top cap, then two or three other edges that form a prolongation of the edge toward the bottom: this will form the path of the wax. Thanks to the "Extract Around" Tool , we are getting a set of edges surrounding what was selected. Let's re-select the original edges, and move them toward the outside to create an extrusion of the material. We can quickly see that it looks more like a peak rather than wax running down. Let's apply a Bevel to these edges in order to round this part. Now we have just to adjust the location of some vertices to get something more natural and to refine the shape. Let's do this using the "Universal Manipulator" . Let's do this again as many times as wanted.

From left to right: 1- Selected edges. 2- "Extract Around" applied. 3 - Initial edges moved. 4- "Bevel" applied.

And this is the result, after several operations like described above: Vertical edges selection, "Extract Around" , "Bevel" , and by-hand refinement by moving some edges:

Attached Images
 
__________________
Polyloop owner & Administrator - no support by PM or email.
Polyloop.net
[EN/FR]
- Meuuh.net [FR +16 ans] - Totyo.com [FR] - Pixologic.eu [JOB] - La3dpourlesnuls.com [FR]
Thomas is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 16th November 2005, 15:02   #2 (permalink)
Always learning new stuff
 
Thomas's Avatar
 
Join Date: Jul 2002
Location: Merignac, France
Posts: 10,951
My Photos: (198)
Images: 93
Send a message via ICQ to Thomas Send a message via MSN to Thomas
Part Two: Modeling the wick.
 

What would be a candle without a wick? Not a candle! So, we are going to model one. Let's go back to the Assembly Room and insert a new polygonal object, which opens the Vertex Modeler. Like before, let's select a Cylinder and let's define its quality to 5. Let's stretch it to make it tall and slim.
You should get something like below:

 


We could eventually stop here but let's try to go a bit further: we’ll create a twisted wick, composed of simplified strands. We are going to select a vertical edge, then select all its parallel edges, using the "Ring" selection tool, and finally select edges that are in their prolongation, using the "Loop" selection tool, which we used previously.

From left to right: 1- The selected edge. 2- "Ring". 3 - "Loop".

We are now going to "Extract around" this selection , re-select the initial edges (thus selecting one on three now, displayed in blue), then do a "Loop" selection to get the entire row, then, using the "Scale" tool, scale down the selection by clicking on the small Cubes representing a "Scale along a plane" action (surrounded below).

tool, scale down the selection by clicking on the small Cubes representing a "Scale along a plane" action (surrounded below).
 

A quick "Free Extrusion" is performed on the top of the wick to change its shape a bit. Then, we are going to smoothly twist our wick. Let's define a Soft Selection (located in the Properties Panel, "Modeling" tab, "Manipulator" section), with a significantly large radius. Let's then use the "Universal Manipulator" to globally deform the wick. Note that the Soft Selection can be used with the Rotation Manipulator, but the easiest way is to use the Universal Manipulator , since you can combine rotations with displacements for a more global control.

From left to right: 1- The dynamic extrusion applied to the top. 2- the "Soft Selection" enabled. 3- A rotation using the Universal Manipulator twists the shape. 4- A second twist and small displacements to tweak the final shape.
 

We new just have to come back into the Assembly Room in order to position the wick onto the candle to finish the 3D scene. It's the perfect time to add a plane (not necessarily infinite) under the candle. Note: if needed, use "Collision Detection" to position your plane precisely under the candle. Caution: when you modified the global shape of your candle, it is possible that you made the base of your candle non-planar. If that is the case, it may happen that because of the Collision Detection, your candle seems to "fly" a bit above your plane. Be careful of this potential issue.
Below, the result of the created assembly:

__________________
Polyloop owner & Administrator - no support by PM or email.
Polyloop.net
[EN/FR]
- Meuuh.net [FR +16 ans] - Totyo.com [FR] - Pixologic.eu [JOB] - La3dpourlesnuls.com [FR]
Thomas is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 16th November 2005, 15:03   #3 (permalink)
Always learning new stuff
 
Thomas's Avatar
 
Join Date: Jul 2002
Location: Merignac, France
Posts: 10,951
My Photos: (198)
Images: 93
Send a message via ICQ to Thomas Send a message via MSN to Thomas
Part Three: setting-up the lighting.

To light our scene, we will use a single light source, which will simulate the light emitted by the flame of the candle. Note that by default, Carrara has created a "Distant Light" (as shown on the previous snapshot), that we will turn into a "Bulb" type light source, and that we will position above the wick.


Since we are in the light parameters, let's change the light falloff, by modifying its brightness: from 400 inches by default to 40 inches, and its falloff range that we'll set to approx. 50%. The result will be a light that will not illuminate very far and that will fall off progressively.

A first render with the defined light parameters.

As you can see, the shadow of the candle that is projected by the light on the floor is very sharp, and does not look very natural. In the Properties Panel of the Bulb light source, on the "Effects" tab, we will check "Enable Soft Shadows" (using the default parameters). Just do another render: it looks much better already!

Soft Shadows on.

The last detail to tweak: if we look at the previous render, we can see that the plane and the black environment background are not perfectly blended. This is due to the ambient light of Carrara, set by default to 20%. We just need to suppress it. Let's click on "Scene" in the Scene Tree, and then open the "Ambient" pull-down menu by clicking in the small triangle to the left of the title. Let's then input the "Brightness" value to 0 (zero). Our lighting is now ready.

Ambient light deactivated. In most scenes, it's better to set this value to zero.
__________________
Polyloop owner & Administrator - no support by PM or email.
Polyloop.net
[EN/FR]
- Meuuh.net [FR +16 ans] - Totyo.com [FR] - Pixologic.eu [JOB] - La3dpourlesnuls.com [FR]
Thomas is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 16th November 2005, 15:03   #4 (permalink)
Always learning new stuff
 
Thomas's Avatar
 
Join Date: Jul 2002
Location: Merignac, France
Posts: 10,951
My Photos: (198)
Images: 93
Send a message via ICQ to Thomas Send a message via MSN to Thomas
Part Four: Materials

Now we are going to apply materials, in order to get a more realistic - and much nicer - scene.
Let's start with the floor. The easiest way here is to use a material from the Carrara Wizards. Let's take the "Stratified Wood" and drag-and-drop it directly on the floor plane. Note that we can activate the material preview in the 3D working area, as well, by clicking on the corresponding icon located on the top right corner of every 3D window.

On the bottom, the wood material to apply and on the top, the Material Preview icon activation surrounded. Right: a preview render. Note that the brightness of the bulb has been increased (up to 140)

It is now time to work on the material of our candle. Caution: this part is a bit CPU-intensive. The Subsurface Scattering (SSS) requires significant calculations, so it is recommended that you deactivate the automatic preview of materials in order to improve the performance.
Let's select our candle and go into the Material Room. Change the color of the "Color" layer to a beige-yellow color. Then, let's go to the Subsurface Scattering layer. Of course, do not forget to enable it by checking the appropriate checkbox.
We will pay attention to three parameters:

  • The Color, which defines the hue the object will appear at the light scattering level.
  • The Translucency, which allows you to make this hue more or less translucent.
  • The Refraction index, which controls how strong the light absorption effect will appear. (this is the main parameter)

Let's start by modifying some of these parameters: First, let's decrease the Refraction index value, to make our wax more "absorbent" and define the absorption color. The orange color looks pretty good. Feel of course free to choose the color that best fits your taste! Then, increase a bit the default translucency.

The different starting parameters of our wax material.

A first render creates the result shown on the left below. We effectively see an "SSS" effect, but it is far from perfect. A second render, with some adjusted values (higher refraction index, etc.) gives the result shown on the right below. It looks better, but the effect is now too bright. Is there a special trick you need to know?

Two render tries. Left, the effect is too light; Right, it is too strong.

Yes, there is a "trick"! To get a much more realistic effect, we just need to activate, in the Rendering parameters, the Indirect Lighting (or "Global Illumination"). Let's launch a new render and see the difference:

Left, with no Global Illumination. Right, with.

The effect now looks more convincing, but is still too bright. Below are the parameters used for the final image. Caution: they might be not exactly the same for your own model. The Subsurface Scattering is sensitive to the size of the objects (that is why there is a Scale Factor in the material parameters).


Before getting to the flame creation, think about creating a dark black material with a very tiny specular intensity for the wick. This part being pretty easy, it is not described in this tutorial.

__________________
Polyloop owner & Administrator - no support by PM or email.
Polyloop.net
[EN/FR]
- Meuuh.net [FR +16 ans] - Totyo.com [FR] - Pixologic.eu [JOB] - La3dpourlesnuls.com [FR]
Thomas is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 16th November 2005, 15:04   #5 (permalink)
Always learning new stuff
 
Thomas's Avatar
 
Join Date: Jul 2002
Location: Merignac, France
Posts: 10,951
My Photos: (198)
Images: 93
Send a message via ICQ to Thomas Send a message via MSN to Thomas
Part Five: creating the flame and doing the final render

Now that we have the wax material we are looking for, we need to create the flame. If you wish, you can use the "Fire" primitive in Carrara 5, but it could be difficult to easily get a single flame like that of a candle, as this primitive has been primarily designed for creating large fires. We are going to use a trick common in 3D and use a real flame photograph (note: a quick royalty-free image search on the web will give you numerous results).

Now let's take a quick tour in an image editing program, like Adobe® Photoshop® for example, to create our flame texture, and particularly the opacity texture, needed to get the correct transparency mask to support our 3D image (a simple plane). Please make sure to get a photograph where the flame is on a background that is perfectly black (this is very important). If needed, edit the photo you have (suppress the wick if any, contrasts, etc.).
Create a new channel in the Photoshop Channels, and paste your image (which will turn into black and white), do a CTRL (Command on a Mac)+click to get the transparency selection, go back to your color image, copy (CTRL/Command+C) the image according to this selection, create a new layer and paste. Result: your flame is here, alone, without the black background and furthermore semi-transparent.
Below, a summary in snapshots:

1- Copy the layer content. 2- Create a new Alpha channel. 3- Paste in this new channel.
 
4- CTRL+click on the Alpha Channel thumbnail to extract the selection. 5- Copy the content of the original layer. 6- Create a new layer. 7- Paste in this new layer to get the flame alone.

Let's save this image in PNG 24 format, taking care to keep the transparency. Back to Carrara, in the Assembly Room. Let's insert a simple plane, which will be the 3D support of our flame image. Let's edit the Material of this plane.
In the Color channel, choose "Texture Map" and let's open the saved PNG file. Once loaded, we can see that the support plane disappears: Carrara 5 has taken the texture transparency into account. Last point on this Material: copy the Texture Map in to the "Glow" channel to make the flame even brighter at render time. To do that, we just have to drag-and-drop the texture map, while holding the CTRL key down, from the Color channel onto the Glow channel.

The Material parameters and the texture copy.

Let's come back to the Assembly Room and position our plane along the wick. Be careful to dimension your plane so it has the same proportions than the image of the flame. Last important detail: in the plane Properties, think to uncheck the two parameters, "Casts shadows" and "Receive shadows", to avoid your flame projecting an unwanted shadow onto your scene.

The two parameters to deactivate.

Finally, we just have now to position our camera according to the best view angle, and generate the render! Of course, you can still continue refining, tweaking and enhancing your model, its textures and the lighting. Do not hesitate to download and watch the video below!

My final result!

Download the video of this tutorial
Below two links, providing the access to the same video, in two different formats:

__________________
Polyloop owner & Administrator - no support by PM or email.
Polyloop.net
[EN/FR]
- Meuuh.net [FR +16 ans] - Totyo.com [FR] - Pixologic.eu [JOB] - La3dpourlesnuls.com [FR]

Last edited by Thomas : 22nd July 2006 at 12:13.
Thomas is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 17th November 2005, 22:40   #6 (permalink)
Vertex
 
conman's Avatar
 
Join Date: Nov 2005
Posts: 2
My Photos: (0)
I guess I must be blind because I cannot locate the "Bevel" icon.
conman is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 17th November 2005, 23:06   #7 (permalink)
Booh!
 
Piem's Avatar
 
Join Date: May 2003
Location: Rennes/fr
Posts: 6,528
My Photos: (15)
Send a message via MSN to Piem
bevel or also called "quick filet" in theCS5 VertexModeler
Piem is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 18th November 2005, 01:00   #8 (permalink)
Vertex
 
conman's Avatar
 
Join Date: Nov 2005
Posts: 2
My Photos: (0)
Thanks. That explains it. I do not have the "PRO" version.
conman is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 18th November 2005, 09:42   #9 (permalink)
Pixar want to hire me!
 
JuST's Avatar
 
Join Date: Jul 2005
Location: Braunschweig, Germany
Posts: 500
My Photos: (1)
Images: 5
Send a message via ICQ to JuST
I'm not able to watch the video after downloading it. I always got a masage that there is a bad public movie atom. Does anyone know what I did wrong? (I'm talking about the High resolution movie)
JuST is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 18th November 2005, 10:18   #10 (permalink)
Moderator
 
Grendel's Avatar
 
Join Date: Jul 2005
Location: Houston, Texas
Posts: 1,172
My Photos: (25)
Images: 23
Great tutorial Thomas, can we hope for an english translation of Georgette? The google translator sometimes is not so accurate.
Grendel is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 18th November 2005, 11:28   #11 (permalink)
Always learning new stuff
 
Thomas's Avatar
 
Join Date: Jul 2002
Location: Merignac, France
Posts: 10,951
My Photos: (198)
Images: 93
Send a message via ICQ to Thomas Send a message via MSN to Thomas
JusT : you need Quicktime 7 to read the High resolution.
Grendel : yes, georgette tutorial will be translated, but I'm currently working on Carrara tutorials.
__________________
Polyloop owner & Administrator - no support by PM or email.
Polyloop.net
[EN/FR]
- Meuuh.net [FR +16 ans] - Totyo.com [FR] - Pixologic.eu [JOB] - La3dpourlesnuls.com [FR]
Thomas is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 18th November 2005, 15:03   #12 (permalink)
Box modeling
 
AWBenson's Avatar
 
Join Date: Jun 2005
Location: Miami, FL
Posts: 292
My Photos: (0)
Send a message via Yahoo to AWBenson
A very nice tutorial :-). Keep up the excellent work.

AWBenson
AWBenson is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 19th November 2005, 04:25   #13 (permalink)
Pixar want to hire me!
 
tonytrout's Avatar
 
Join Date: Aug 2005
Location: Aotearoa Land of the long white cloud.
Posts: 576
My Photos: (3)
Nice- good tute
thanks
Tony
tonytrout is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 19th November 2005, 21:25   #14 (permalink)
Vertex
 
seedydeedee's Avatar
 
Join Date: Nov 2005
Location: UK
Posts: 1
My Photos: (0)
Send a message via MSN to seedydeedee Send a message via Yahoo to seedydeedee
Absolutely great! I learned a lot following this tutorial, although I did find I had to use use a .psd file rather than a .png for the candle flame. Gotta love the SSS ;) :D
seedydeedee is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 21st November 2005, 08:41   #15 (permalink)
Moderator
 
Nichod's Avatar
 
Join Date: Apr 2005
Posts: 611
My Photos: (0)
Images: 1
As a little addition. You could apply a point at modifier to the plane that the candle flame is on and designate the camera as a target. Position the plane's hotpoint at the point where the flame meets the wick to prevent odd rotation. Of course extreme movements won't work, but this will allow limited camera movement.
__________________
Email Me. Visit my blog!
Get hundreds of shader presets! Get Art of Shaders! And a preview for Art of Skin is now available.

AMD Turion(TM) 64 ML-40 (2.2GHz/1MB L2 Cache) 1280 MB DDR 333mHz RAM 128MB ATI RADEON(R) XPRESS 200M w/Hypermemory(TM) 60 GB 4200 RPM Hard Drive DVD+/-RW/R & CD-RW Combo w/Double Layer Support 15.4" WXGA BrightView Widescreen (1280x800)

I use.
Nichod is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Old 21st November 2005, 12:30   #16 (permalink)
Always learning new stuff
 
Thomas's Avatar
 
Join Date: Jul 2002
Location: Merignac, France
Posts: 10,951
My Photos: (198)
Images: 93
Send a message via ICQ to Thomas Send a message via MSN to Thomas
a more refined plane can be also used and animated with some bones to make the light move ;)
__________________
Polyloop owner & Administrator - no support by PM or email.
Polyloop.net
[EN/FR]
- Meuuh.net [FR +16 ans] - Totyo.com [FR] - Pixologic.eu [JOB] - La3dpourlesnuls.com [FR]
Thomas is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in Technorati