View Full Version : Black parts on glass when using dielectric material
09 September 2007, 08:48 AM
I tried to render a simple glass with a liquid inside. I gave both elements a dielectric material (mental ray node). The only thing I changed was the color and IOR for the liquid material.
Now when I render my glass it's strangly dark on the top and at the bottom. Is there a way to get rid of it and achieve a more realistic result? Please see the attached image. I checked all my normals and I think the topology should also be fine.
09 September 2007, 12:44 PM
I think you need to increase the number of Reflections / Refractions / Max Trace Depth in your mental ray rendering. These settings define how many "surfaces" the light can pass through before it just gives up and makes it black. So, they should be at least 6, though you'll probably have to make them higher until you get the look that you want.
09 September 2007, 12:55 PM
I don't think that that's the problem. my ref/refrac/trace settings are 8/8/16 right now, but I also tested it with 30/30/60 and it didn't change. I have no idea what it could be.
09 September 2007, 01:03 PM
Okay, the only other reason I can think of is that it is refracting something that is black... eg: your camera's background colour.
I'm assuming you have this glass against just an L-shaped plane for the background, but everything outside of the camera view is probably black. If you're just using the perspective, go to your outliner and click on "persp", then scroll down to environment, and make sure it's white.
If that's not it, then I have no clue.
09 September 2007, 06:21 PM
Also check the surfaces normals. When they point into to wrong direction you also get black parts.
09 September 2007, 05:06 AM
The glass is inside a sphere with a standard white lambert material. Even if I crank up Incandescence to 1, I still get the black parts. The normals of the sphere are pointing inwards. I also doublechecked the normals of my glass and my liquid and they are pointing to the right directions. Any more ideas? :shrug:
09 September 2007, 10:27 AM
What's your IOR? That's the only thing I can think of... you've got the normals hammered, it's in a white sphere, got me.
09 September 2007, 10:40 AM
Yeah, I also don't know what it is and running out of ideas. I checked my IORs a million times (like anything else in the scene). For the water I use 1.33, for the glass I tried 1.4, 1.5 and 1.6, all giving my similar results when it comes to the black parts.
Even when I just render the glass without the water I get those black parts. I rebuilt the scene several times now, allways with the same unsatisfying results. :sad:
09 September 2007, 10:59 AM
Did you try different glass materials? (l_glass, mia)
I had some similar problems before and couldn't solve them.
Maybe you can upload the scene, so people can have a look at it.
I'm also very curious as to what causes this behaviour...
09 September 2007, 12:26 PM
Sure. When I can try to upload the scene tomorrow. I hope somebody is able to figure out what I'm doing wrong.
09 September 2007, 02:28 AM
here's the scene file for anybody interested in figuring out the problem. I tried all sorts of setting but was never able to achieve a convincing glass/water look without the black parts and that strange horizontal line in the middle of the water.
09 September 2007, 01:48 PM
There were some problems with the geometry.
First, there was a little intersection between the water and the glass. That was what was causing the bright stripe. I rescaled the vertices of the bottom half of the water and it was gone.
Then, your normals looked fine, but they weren't, actually. The selected loops showing in the following image were soft, so the normals were interpolated, causing those black parts on the top part of the glass.
After the geometry corrections:
I also raised de reflections and refractions limits. It makes a little difference, but it's not that much important in your scene.
09 September 2007, 02:00 PM
Forgot to advise you that maybe you should use another approach when using more than one dielectric media. It's better if you don't use overlapping geometry. The mia_material guide has a nice explanation about it. ;)
09 September 2007, 02:58 AM
thank you for analyzing my scene and fixing the issues! :thumbsup:
Also thanks for pointing to the mia_material documentation. It explains really well why I shouldn't model the glass and the liquid in the way I did. I will use this approach the next time.
thanks again - and everybody else trying to help me out in this thread,
09 September 2007, 02:58 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.