Transparency - multiple render layers

Hi

I’m working on a scene for an artist. He wants a sculpture with a lot of glass layers on some images.

When I render it with the shadow only material setting, the refraction in the glass is black. So I try to do the shadows in another render layer, but the artifact still shows up.

Suggestions is welcome!

Here is the blend file:
font4_m_kirke-3.blend (1.57 MB)

And an image:



The reason its so white is that I tried to combine with a clay render layer.

It is not clear to me, looking at the image, precisely what “your problem” consists of. Please explain. (For instance, I don’t see any “glass layers” here!)

“As a great-big rule of thumb,” here’s my practical suggestion: “If you want to create a fancy, multi-layered effect, forget about ‘reality.’ Nobody cares about ‘reality’ except the viewer. Focus on what ‘reality’ (whatever it is…) looks like.”

If the final scene that you want to assemble consists of many different components, focus your attention on generating every one of those components in isolation. Then, once you have individual (MultiLayer, of course…) output files containing each one of these things, separately focus your attention upon the task of assembling them into an image that, to your satisfaction, conveys the illusion of (that is to say, the plausible appearance of…) “glass layers” or what-have-you.

It’s much like Alfred Hitchcock’s now-famous acting advice to Ingrid Bergman: “Ingrid, fake it!” :spin:

“Fake it.” … That really is “what it’s all about in the end,” now isn’t it? :eyebrowlift2:

P.S. If you’re now thinking, “but how do I do transparency?” The answer is: “you don’t.”

An object is transparent if: (a) it looks as though it must be a solid thing, and (b) it nevertheless looks as though you can see something, that looks as though it is behind it.

Notice how many times I just said, “it looks as though.” If there is any secret to CG, there it is.

You don’t have to model reality. You just need to create a visual result that “looks as though” it is as “real” as you want it to be. Compositing is your secret friend. Node networks (“noodles”) are what enable you to take separately-produced visual elements, prepared ahead-of-time and stored in MultiLayer files, and to combine them, using an arbitrary network of processing stages.

It’s a two-step process. The first step is to build the elements and capture them. Each one should be isolated, consistent, and “clean.” The next step (or steps) is to composite them, adjusting colors and so on as you go.

Ansel Adams once pointed out that, while a photograph is captured in the camera, it is made in the darkroom. That’s still the case. Very much so. It’s just all digital processing now. (Ansel no doubt would have loved it, and taken to it like a duck in water.)

sundialsvc4 offers good advice for creating the final image. But you also need to make sure that all aspects of your scene setup match those captured in the photo, at least to the extent that the scene can “fake it.”

First, your Blender scene perspective characteristics have to match the perspective of the setting photo or no matter how convincing your other model characteristics, the composite will look false. This involves quite a bit more than matching a few perspective lines to the BG image. The BLenses link in my sig talks about this on page two. I haven’t yet updated BLenses for the changes to 5.7x, but the info is still valid, and you can use the script in 2.49b to get the data you need for camera settings (focal length in particular) in 2.5x.

You also need to consider that a material like polished glass interacts with the environment in many ways beyond refraction, surface reflections also being important. Your file (which did not include the BG image, btw, so it can’t be viewed as you see it) shows a very minimal “stage” for the material to interact with. If you were expecting the glass material to refract the BG image, that doesn’t work. As you have it set up the BGimage is a basically a reference only. What’s being refracted in your object is the small portion of “floor” you’ve set up & the otherwise empty BG. The un-refracted BG is masked by the Render Layer’s alpha, but not that portion refracted in the object. You have to provide something in the scene that the object can refract that imitates what it would refract when placed in that setting – fake it, like s’vc4 says.

The same “add something to fake it” idea is needed for reflections. Simple compositing cannot do this because, as with refraction, the reflections are a property of the material, which needs something in the scene to act on during the render pass.

Your lighting scheme also has to fake the conditions recorded in the photo. You’re using Spots exclusively, probably not the best choice to match the softly diffused illumination from the chapel’s windows and the large amount of light bounced around within that very light-toned room.

So before you start generating the kind of Multi-layer outputs mentioned above (which is a good way to adjust the results for a final image), you also need to address the basic shortcomings in the scene setup.

Thanks for the advice. I have made another attempt with another layer for shadows.

There is supposed to be 84 horizontal layers of glass in the main shape.




Wow, tough subject. Extremely difficult (for me at least) to simply imagine how that might refract – I doubt it’s the same as a solid chunk of glass. Have you actually seen the font? Do you have any pictures that illustrate how things behind it are distorted by those many layers? The edges probably contribute a lot to the look as well.

The lighting looks much better now. You might consider a touch of AO-type shadowing at the base as well to help integrate the point of contact with the floor into the composite. And don’t forget that when you reverse the camera angle the object will appear on the other side.

The “graininess” of the glass volume suggests you might be using an AngMap and Environment Lighting as well as lamps. If so, you need to increase the Gather sampling rate substantially to reduce the grainy result.

I don´t know why, but the ambient occlusion did not really work for me.

I made some clay/ wire renders to clarify the concept:




There are no shadows going on in the glass, (takes too long to render) so I don´t know why it is so “dotted” - maybe just too many layers :-/
But anyway, I will leave it like that for now. I think it is understandable whats going on, if not photo realistic.

I think you are maybe expecting that Blender’s Material properties (like RayTrans) are supposed to act like actual materials such as glass. As mentioned above, they don’t, they are just “tricks” to help imitate reality. So virtual light passing through all those planes/slabs is unlikely to be refracted in the same fashion as real ight through a stack of glass sheets. Plus you have many technical issues such as IOR, Fresnel, and ray depth to consider, some of which are not part of real-world materials but nonetheless affect the appearance in the rendering.

If you don’t mind a suggestion: rather than using actual layered slabs of “glass” meshes, perhaps try a one-piece mesh that takes the overall shape, but is not truly layered. Then use texturing methods to introduce a suggestion of the layering. Textures can even be used to modulate the RayTrans effect to some degree if that helps the overall look. The overall-solid mesh would provide a measure of refraction that a viewer can interpret more easily, even though it may not be 100% accurate. But without knowing how the real font looks and acts in an environment, it will be very hard to create the look out of “whole cloth” so to speak, because it’s mostly just guesswork.

There are engineering- or scientific-type applications that can create solid material simulations based on optical physics and the like, and there may even be some shading systems capable of that in higher-level renderers, but not yet in Blender internal that I know of. But those are also extremely computationally-intensive processes from what I understand of them.