Refraction affecting alpha channel incorrectly

Hi there,

So I have been having this issue for a long time now and haven’t tried to look for a solution until now.

I often find that I get unexpected and unwanted semi transparent areas in my alpha channels (mainly vehicles) around the headlights, or anywhere where there is shaders with refraction assigned. See the images below for a few examples.

As you can see, the alpha channel, which should have a reading of 1.000 has a mid grey value closer to 0.5000 which obviously gives incorrect results when compositing.

Would be good to hear if there is a solution to this.

Thanks,

Vray 3.4 Maya 2016 SP6




Maybe the problem is with the alpha settings for reflections in your refractive materials. If you go to reflection settings of the material what have you picked in the “Affect Channels” dropdown? I think you’ve picked “Color+alpha” or “All channels”. Set it to “Color only” and it should be fixed.

Hi there,

Thanks for the suggestion.

My refraction alpha settings are set to affect ‘All Channels’ but the reflection setting are actually all set to ‘Color Only’.

It should help if you set the refraction to “color only”. It should make refractive objects not affect the alpha channel and it should save a (tiny) bit of render time too.

The main reason that the refraction is set to affect all channels is so we can generate material ID’s / mattes for what lies behind refractive services. How can I achieve that, and fix the issue listed above at the same time?

Thanks

Ah, I don’t think it’s possible to not affect the alpha but affect the other channels at the same time, at least not at the moment - we don’t support that.
So unfortunately you’ll have to render a separate pass for just your IDs. You can render once with your refractive material set to “only affect color” and without the matte render elements. Then render again only the mattes and set the refraction to affect all channels, only for that second render you can disable everything except displacement, i.e. you can disable lighting and GI. Will that work for you?

Hey, yeah that works fine, and is pretty much how I am getting round the issue anyway, thanks.

I think the main thing here is that the fact the alpha is being affected in the example above is clearly a bug / error / issue as there are many objects behind the refracted pieces there that should cause the alpha to be solid white.

I understand that say if I had a glass object with no other objects behind it the alpha would be affected but if there was a blocker object behind the glass object then I would expect that to be opaque?

Thanks again

We’ll have a look at that.

Seems that we have this already logged, but we haven’t fixed it yet.
Another idea came to mind - you can avoid rendering a second pass and instead just use the multimatte mask (or any other kind of masks) of those objects and add it to the alpha channel in compositing. In theory it should save you a bit of time.

A common way would be to render without the headlights main glas. So you’ll get your objects behind for free. And then render the glas seperatly opaque. And finally comp it.
But - 1+ to get this issue fixed :slight_smile:

Hi,

Just wondering if this has this been fixed at all? I am experiencing the exact same issue but in 3ds Max almost 3 years later :frowning:

I’m afraid no. And this is just wow…

A year on and still having this issue. Has this been looked at yet?

This issue has been around for years. Ironically it does seem to come up most when dealing with car lights (that’s when I’ve had it too). It would be great to get this fixed as having to do a whole separate render just to pull ID mattes can be a pretty costly workaround.

It’s happening on an RGB layer for me, so it’s a real pain. The refractive object is sitting in front of a solid but it’s creating an alpha all the way through. I guess I can set the refractive object to not have an alpha. But since it’s an animation, there are times when it doesn’t appear in front of a solid and I actually need an alpha. It seems such a silly bug

We mostly render the outer glass as separate pass, but in cases where this is not necessary we also get such issues.

Would love to hear how the progress on that issue is on Choas side?