ZBrushCentral

Tutorial: Transparency And Shadows

Hi :slight_smile:

There are several methods that can be used in order to achieve transparency effect. Some have been described in this thread.
Below is one more method…

Getting transparency and shadows at the same time may seem difficult at first, some of the methods will required you to turn off the ‘Flatten Layers’ option in the RENDER panel, but I usually prefer to keep using the flatten layer because it has several advantages over the “un flatten” mode. The most important advantage would be speed, when using the ‘flatten layers’ mode, your image will be rendered in the same amount of time whether you have 2 layers, or 16 (the other mode will requires every layer to be rendered separately therefore increasing the render time as you add layers). Other advantages are that all layers can cast shadows and glow effects. So, here is a method that I like because it allows you to achieve the effect you want in one step and it allows your artistic creativity to simulate the transparency effect and achieve the exact look that you want. Even tough the transparency effect can be achieved in one step; I will include all the steps required for this image.

:small_blue_diamond:We first create the base layer that will be ‘seen thru’ a transparent object in other layers. In this case I simply used the Plane3D tool with a default ZBrush texture (Txtr30) and FastShader as the materials. I have set the Plane3D.MODIFIERS.TEXURE.HRepeat and VRepeat to 8, and drawn the Plane3D to fill the canvas area.

:small_blue_diamond:We now need to create a new layer (LAYER :small_orange_diamond:CREATE) and draw the ‘transparent’ objects in that layer. In this example I have simply selected the Sphere3D tool with a ‘Txtr01’ (A typical sky/ground reflection) and with GelShderA as the material. I have drawn several spheres within the canvas.

:small_blue_diamond:We activate the Shadow in the RENDER palette and do a test render.

We can see that we now have proper shadow, but we are still need to add the transparency effect.

:small_blue_diamond:To create the illusion of transparency we can simply use the Clone tool. While in layer 2, select the Clone tool and change its modifiers by turning on the Clone :small_orange_diamond:Modifiers :small_orange_diamond:Layers mode and turning off the Clone :small_orange_diamond:Modifiers :small_orange_diamond:RetainCenter.
By turning on the ‘Layers mode’ we allow the clone brush to copy color and/or depth information from the other visible layers into the active layers. In this case we only want to ‘copy’ some of the colors from layer 1 into the spheres in layer 2 which allow us create the illusion of transparency. To do that, we need to turn off the ‘ZADD’ draw option (we don’t want to copy depth information, only color),turn on the RGB draw option (we don’t want to copy Material information, only color) and set the RGB intensity to a low value (such as 6). Now we use the clone brush to ‘paint’ within each sphere. This action will transfer some of the colors from layer 1 into layer 2. The more we copy, the more the spheres will become ‘transparent’…

Now we have Simple reflection, transparency and shadows. We can stop here and call it a day, or continue and make it a bit more interesting…

Let’s continue…

What is refraction :question:
Transparent objects have a property that referred to as ‘refraction’. When light passes thru transparent object it will change direction (being refracted) and continue in a different direction. The amount that direction of the light is changed is measured and specified as a refraction index .( Refraction is the reason that a spoon in a glass of water may look ‘broken’ )

Now Back to ZBrush and a quick method of simulating refraction…

:small_blue_diamond:In order to simulate refraction we need to displace and distort the image that you ‘see’ thru the spheres. When distorting the image, you are trying to ‘push’ colors in the direction that the surface of the sphere is facing; this can be done by using the ‘BumpBrush’, which does exactly what we need. When we use the bump brush, we may elect to only distort the colors within the spheres without changing the shape of the spheres (this is done by turning off the ZADD/ZSUB options) or we may choose to modify colors and shape at the same time. In this example I wanted to modify both (colors and shape), so I have activated ZADD and MRGB option, increased the RGB and Z intensity to 100, reduce BumpBrush :small_orange_diamond:Modifiers :small_orange_diamond:ColorBlend to zero,increased BumpBrush :small_orange_diamond:Modifiers :small_orange_diamond:SampleSize to 8 (in order to get smoother surface) and reduced DRAW :small_orange_diamond:DEPTH to about 10%(we want to slightly modify the shape of the spheres, not create mountains :slight_smile: ). Now by drawing over the sphere I was able to distort the shape of the sphere in order to get the following…

:small_blue_diamond:Applying some smoothing (by using the Blur Brush with ZADD on and MRGB off), material tweaking, adding local light and there we have it…

:small_blue_diamond:A variation of the same process…

I hope that you’ll find this helpful :slight_smile:
If you try this tutorial, please post your image and findings.

-Pixolator

WOOW, that is really great Pixolator. I don’t know what I would do if I didn’t read you great tutorials, keep up the GREAT work!!

I really appreciate everything you do on this board and for creating Zbrush!

Thanks!

Very nicely done. Thanks again Pixolator. :slight_smile:

:slight_smile: Hi Pixolator…Here’s my contribution to your “Transparency & Shadows” Tutorial. I didn’t follow your tut to the tee, but pretty close. Thanks for this tut as well as all the others, :smiley: & have a good one… :cool: Mark.

Thanks for the tutorial, pretty amazing stuff! Although I’m not clear on why and why not to turn on/off some of the options as I’m not sure what they do.
Any chance of a “ZBrush In Depth” or “ZBrush Bible” coming out soon? :slight_smile:

I got similar results by using 3D Copy (in the Transform palette).

For each of the three glasses above, I used 3D Copy to place the background onto the surface of the glass, then moved it toward the back wall slightly. I also tweaked a Basic Material to get the highlights and other light effects.

In the glass on the left, I first “flattened” the glass 50% by doing this:

  1. I pressed the Rotate button, and put 0 in the Transform:Info:Zcomponent slider (so the front was facing me dead on)
  2. I pressed the Resize button and entered half the size in the Ycomponent slider. In this case the size was 140, so I entered 70.
  3. I pressed 3D Copy (with “S”, or Shaded, highlighted)
  4. I typed the full size (140) in the Ycomponent slider again.

For the middle glass I “flattened” it 25%; for the glass on the right I didn’t flatten at all.

3D Copy makes use of RGB Intensity in the Draw palette; I could have made more opaque glasses by reducing this slider to a number less than 100.

I like this method because I can keep my 3D object active, plus there’s a tiny bit of distortion in some areas depending on the object’s polygon resolution.

Hope it helps.
dave

P.S. I am using a Mac, and I know there are some gamma issues that make images look darker on a PC; can I get a little feedback from PC viewers?

I’m using a PC and the three wine glasses look ok, not too dark.

My moddest addition…

Really cool tut! Thanx! :smiley:

/R

P.S. Yes, I don’t have any imagination so I did a logo for my company… :slight_smile:

I think everyone will agree that pixolator’s and southern’s tutorials are practically professional in their layout.

besides this one being awfully useful in its content.
I am not a lowly worm that should bow before pixolator, however I do! :slight_smile:

oh yeah thank.
just what ive been looking for.

Thank you for showing us this method. Here is one of my experiments:

These are simple pictures, but adding droplets of water can really make a simple picture look much more real.

Jay

awesome! is it only me, or does everyone look at jay’s pic and see a ripe, cool strawberry? :+1: :+1:

Hey, good idea Christos. This was so easy. Throw a texture on a plane in one layer, and throw a sphere in another layer. Then choose gel shader A and place small spheres about the scene. I’m sure you realize how time-consuming or out-right difficult this would be in a 3D app like 3D Studio Max :ex: I didn’t even bother saving the file in ZBrush, since I can make an even better one in about 5 minutes :ex:

I will take your challenge. I will make a mouth-watering, succulent, stawberry. It will be like taking candy from a baby.

:smiley:

Thanks,

Jay

Here’s a discovery I made while playing around with the clone brush tutorial. At first, I was only getting flat-shaded bricks in the water droplets, which didn’t look right. Then I realized, what I could do to both get the transparency and shadows was to duplicate the brick wall layer. I then rendered and baked one of the duplicates, kept that layer active and then used the clone brush on the droplets. Then I de-activated the baked layer and activated the unbaked brick wall layer and then rendered. Now, I could get the transparency with proper shading in the droplets and shadows cast on the wall.

[img]http://www2.zbrushcentral.com/zbc_uploads0/user_image-1008214895yqo.jpg[/img]

here’s one i did on the LEN’S on the Glasses most people use material > jelly bean i used (Gradientsky) and added texture to the object if you look at the LENS it has a zbrush logo as texture ON the object then you can see threw that and see the eye’s http://www.pixolator.com/zbc-bin/ultimatebb.cgi?ubb=get_topic&f=1&t=002664

can you show this discovery in a script winded one… if you want of course… thanks

Nice to see everybody looking at transparency and reflection, and I hope I had some small role in this fun topic! Nice use of transparency, W/O, and fine rendering, crisp and clear!
:+1: :+1: :+1:
This post is for Juandel who sent me a private message that one more post would be 666, my number…How could I possibly disappoint the guy who gave us the Rein-Bats???
But I meant everything I said about your wicked cool image, W/O!!

Thanks for all this information, it looks like a very useful tutorial.
Dave.