default image for post
Replicator to make some Grapes
May 16, 2010  |  by Subhamoy Sengupta  |  Featured, Intermediate, Modeling, Rendering / Lighting, Tutorials

Replicator Grapes

bySubhamoy Sengupta
Hello and welcome to this tutorial. The objective is to make realistic looking bunches of grapes using replicators in Modo.

Other than some basic knowledge of interface and navigation, no prior experience with Modo is required to follow this tutorial.

Tips are in Green. Shortcuts are inRed. Other important highlights are in
Blue.

I have written this tutorial in British English, which is what I am accustomed to. I hope it will pose to trouble to American readers.

So, let’s get started!

Step 01

modoGrapes01b

modoGrapes01

Draw out a stem using the Solid Sketch tool. If you are not well acquainted with it, following are the rules.

  • Just clicking on empty space once creates a new Solid Sketch point.
  • Clicking and dragging on empty space lets you scale the geometry around the new Solid Sketch point.
  • Clicking on an existing Solid Sketch point and dragging lets you move it.
  • RMB dragging on an existing Solid Sketch point lets you scale the geometry around.
  • After drawing stem to a length, if you wish to draw out some branches, just click on the desired intermediate Solid Sketch point and
    draw out and keep drawing.
  • When you are done with that branch, click on the last point on the main solid sketch line and you can continue drawing the main
    stem.

When finished, hit SPACE to deactivate the tool.

Step 02

modoGrapes02

Assign a new UVmap to it.

modoGrapes03

For every branch, select the whole base, a seam from base to tip, and 3 edges around the last quad leaving out any one edge connected to the seam.

modoGrapes04

It’s best to pick seams that will not be easily seen in the final render.

Step 03

modoGrapes05

Switch to UV tab, choose Unwrap Tool, choose a high iteration number and set initial projection to Cylindrical, of course. Then click on viewport to finish unwrapping.

modoGrapes06

In polygon mode, double click on each polygon island and re-orient them. Then pack the UVs with Orient unchecked so that only the size gets normalized and optimized.

modoGrapes08
modoGrapes07

Step 04

Create a few variations and pack all their UVs together.

modoGrapes09

In Photoshop, create a new 2K texture. Fill it up with greenish orange. Take a new layer above it, fill it with white (Ctrl + BACKSPACE if white is background colour). Hit D to set black and foreground and white as background colour. Now go to FILTER > RENDER > CLOUD. Colourize this layer with Hue/Saturation adjustment and give it a darker highly saturated orange. Set the blending mode to Multiply and turn the opacity down a notch.

modoGrapes10

Add a mask to the fibre layer and draw a reflected gradient on the mask to hide the much of the middle portion. Select the fibre layer, hit Ctrl + T for Free Transform. Right click and choose Warp. Warp it a little bit to break the monotony.

Step 05

modoGrapes11

Select the stem mesh item in Item mode (5) and hit M to assign a new material to it. Set Specular to 5%, Fresnel to 100%, Roughness to 100% and Bump to 400%. Drag the texture shown above to the material group and uncheck Antialiasing. Create an instance and change the effect to Bump. If you feel the texture is looking too washed out, make another instance as Diffuse Colour and change Blending Mode to Multiply.

Step 06

modoGrapes12

Using SolidSketch, make some connectors that will connect the grapes to the main stem. Make a simpler few and a more complex few.

modoGrapes13
Delete all bottom polygons, select the bottom edge loops, press Z and click on viewport to Edge Extend. Change Action Center to Local and press R to switch
to Scale Tool. Now scale them all in.

modoGrapes14

Repeat this process and then right click on any of the selected edges and choose Collapse. Now we have a vertex in the middle of each connector base. We will snap the centre there.

Step 07

modoGrapes15
But before we do that, we need to give each connector its separate mesh item. So we will cut (Ctrl + X) and paste (Ctrl
+ V
) them them into separate mesh items. You can also parent them to a group locator by pressing Ctrl+G while they are all selected in item mode.

modoGrapes16

With one of the connectors selected, click and hold the Items button to reveal more options. Choose Centre. Now the global position of the centre of that mesh item will be shown, which is at the origin.

modoGrapes17

Turn on SNAPPING > GEOMETRY. Choose Mode to Vextex and Layers to Active, since the centre object and the geometry are all in the same mesh item. Now select the centre object and move it in place. Repeat this process for the other connector mesh items.

modoGrapes18

If dragging it all the way from the origin seems to be a tedious task, you can select the mesh item, set the centre to the bottom of its bounding box and then do the snapping.

modoGrapes19

With each item selected, zero its transformations. Now if you accidentally move, scale or rotate any of them, simply doing a Reset All will revert all the changes made. This is important, because we will use these mesh items as both replicator proxies and point sources. Any change of position may affect the final look of the result.

Step 08

modoGrapes20

The grape is nothing but a sphere whose top polygons have been bevelled in a few times.

modoGrapes21
modoGrapes22

Select the seams like shown above. Range selection can come in handy here.

For range selection, select the first edge of the seam, and then the last edge while holding down Shift, and finally press Shift + G to select all edges in between.

Before range selection, make sure all whole loops are already selected. Selecting ranges first and loops later will also complete the whole loop of the range selections, which we don’t want.

Step 09

modoGrapes24b

modoGrapes24

Create a few duplicates and sculpt on them with low offset. Grapes should be fairly smooth, so keep brush size large and smooth often.

Brush size can be adjusted by RMB dragging.

Smooth brush can be temporarily activated by holding down Shift.

Step 10

modoGrapes25

Rotate the grapes by 180 degrees, because the body of a grape is supposed to be away from the connector’s tip. Set the centres to bounding box bottom. Pull them up a bit.

modoGrapes26

Select the top polygons and keep pressing Shift + UP until the whole outside skin is covered. Assign a material to it. Then press [ to invert selection and assign a different material to it. (the image shows inverted view)

Step 11

modoGrapes27

We want only one grape to attach to one tip of a connector. To ensure this, we have to take advantage of vertex maps. But the connector tips are single polygons. So select each of them and press D to subdivide them once in faceted mode. Now every
tip polygon will be split in 4 so there will be a vertex in the middle. Now we can make vertex maps on them.

Step 12

modoGrapes28

Lay out the connector UVs in same way as before. It is not essential though, because unless camera is in extreme close up, connector texture will hardly be visible. We will just assign a dark brown material to it with no or very little specular highlight.

Step 13

modoGrapes29

Go to the group tab and use the Ctrl + 3 pie menu shortcut to open another temporary Item List panel on the screen.

modoGrapes30

Make a new group and drag the grape meshes to that group. This group will serve as the instance source.

Step 14

modoGrapes31

Add a Surface Generator to each of the connector materials.

modoGrapes32

With a connector mesh item selected, make a new weight map. Switch to Vertex Map shading mode and select the tip vertices. Press Shift + W and click on the viewport to activate the tool. Set the value to 100%.

modoGrapes33

Under the connector’s material group, add a Weight Map Texture.

modoGrapes34

Give the vertex map an object specific name. In the Weight Map Texture’s properties, choose the right vertex map. Change the texture’s effect to Surface Particle Density. This means, replicators will spawn only on selected vertices, i.e., the tip vertices.

Step 15

modoGrapes35

Finally, take new Replicator item. Prototype is the instance source. Set that to the group of grapes we created earlier. Point Source is the base mesh on which the replicators will spawn. Set that to the connector’s material’s surface generator. As soon as we do that, we get this:

Since surface generator is scale dependent, the result may not always look like this by default. The surface generator properties may have to be tweaked a bit in that case. For every object, Minimum and Average Spacing may have to be adjusted.

Another thing to keep in mind is, unlike some other popular softwares like Softimage, Modo smoothes the maps when we switch to SubD. So, before adjusting, make sure you are already in SubD, or you will have to do the adjusting later again.

Doing the same thing on the other connectors, this is what we get:

modoGrapes37

If you are not happy with the size of the grapes, do not try to scale up the actual grape mesh items. Use the Scale Factor of the Surface Generators.

Step 16

modoGrapes38

Make every replicator a child of the corresponding connector, so that when we use the connectors as point source, the replicators under them are also replicated.

modoGrapes39

Assign a surface generator to the stem.

modoGrapes40

Just like before, create a group with the connector mesh items. Make sure the child replicators are not in this group.

modoGrapes41

Create a new replicator for the stem and make sure the Include Child Items option is checked.

modoGrapes42

At this stage, it will look somewhat disorganized. Grapes have grown everywhere, even where we do not want them to. Moreover, they are all of the same size and colour. Looks very unnatural.

Step 17

modoGrapes43
modoGrapes44

Add a new colour texture to the stem material group. Set it to white. This will later be used to drive replication distribution. White all over means the result will be same as before. Now we need to paint with black where we do not want grapes.

modoGrapes45

Now grapes will not grow in those places.

modoGrapes46

And this is another map, drawn similarly in Modo. This map will drive the size of the connectors/grapes.

modoGrapes47

As you have noticed, I have not drawn the density map with pure black. If you feel it is not having the desired effect, you can create an instance and change the blending mode to multiply.

modoGrapes48

Here the distribution looks relatively natural. Let us pay a little bit of attention to shading. So far the grapes only had a basic green material without specular or anything else.

Step 18

modoGrapes49

With the grape’s outer skin material selected, add a Gradient. Set Input Parameter to Particle ID and check “Edit Gradient“. That will bring up the Gradient Editor.

modoGrapes50

On the horizontal scale, the range 0 to 1 addresses all particles. As they are instanced, they get a number. If the lowest number is assumed 0, then then highest number is assumed 1 and every other particle number falls somewhere in between. Grapes do not have a definite order colourwise. Sometimes bigger grapes are reddish, sometimes smaller ones. So we will simply make the colour vary.

modoGrapes51

Step 19

Make an instance of this gradient and change the effect to Transparent Colour. However, it will not work until the material’s transparency attribute has a positive value. The value being big or small does not affect the gradient.

modoGrapes52

Delete the default directional light and set two low intensity directional lights to highlight the profile of the grapes. Put a relatively higher intensity directional light behind the grapes that points straight ahead.

modoGrapes54

Duplicate the diffuse colour gradient 3 times and change the effects to Transparent Colour, Subsurface Colour and Specular Colour. Set Subsurface Colour and Specular Colour opacities much lower than 100%.

A little bit of specular, 100% Fresnel and high roughness will highlight the profile and the grapes will not look flat or one dimensional.

modoGrapes55
Setting the front weighting low will better pronounce back scattering, which we want. However, unless the camera is real close to the grapes, SSS is probably not even necessary in this case. Some blurry refraction will be necessary for a hint of the flesh inside. That blurry refraction will spoil the subtle contribution of SSS mostly anyway. The attribute that really should have done the job is translucency. In Modo, SSS with zero scattering distance is equivalent to translucency. However, that will only penetrate one level of polygons. In other words, it will work for objects like lanterns where the light source is inside the mesh and it has only one level of polygons to penetrate in any given direction. Since here the light source is quite a bit far behind the grapes, translucency, as Modo perceives it, will not work.

Step 20

modoGrapes57
modoGrapes58

There is no reflection going on in this scene. Refraction trace depth can also be set pretty low, since the effect is subtle and should not work if one grape is in front of another. Ambient intensity should be set to zero and environment contribution should also be set pretty low, since the major light contribution we want to come from the directional light behind. Keeping the environment at its default intensity will overpower the back scattering effect.

modoGrapes56
modoGrapes59

Change the Environment Type to Physically-based Daylight.

Hitting the render button (F9) at this point will produce the
following result.

modoGrapes53

Additional Remarks

modoGrapes60

To gain further control, we can add a render output under the grape skin material group and change the effect to transparent shading.

modoGrapes61

This will isolate only grape transparency in this separate pass with its own alpha channel. This pass can later be used in Photoshop or any other compositing software to enhance back scattering effect, change transparency colour, add a subtle glow, and more.

Also, so add more natural look, you can duplicate every grape mesh item once or twice and pack all grape UVs and use a procedural noise or dirt bitmap texture on it as specular/transparency mask. Also, it can be used on top of diffuse colour gradient to show actual dirt or stain on grape skin. In such cases, we only want the dark areas to affect the calculations, but we do not want the bright areas of the map to make specular, diffuse or transparency go way high. So these maps will have to be used in multiply blending mode.

That concludes this tutorial. For any questions or comments, feel free to write to shushens@gmail.com

  • Subscribe to our Modo RSS Feed to receive our latest articles and education from Modo Cookie. Become a Citizen

  • 2 Comments


    1. thanks for the article..
      here is the same thing i tried in last month ..

      http://img60.imageshack.us/i/grapesss.png/

      difference is i used replicaters for water drops and not for grapes ..
      but the your technique is simple and effective ..
      thanks again

    2. Hi Nikhil. I really appreciate your response :) The grapes you made really look wet and yummy. Congratulations for that!

    Leave a Reply

    Spam Protection by WP-SpamFree