Jump to content

How to best save alpha with glass and reflection


Tim Saunders
 Share

Recommended Posts

I'm not sure if these are some issues that have come up in the last couple releases of v-ray, but I don't ever remember having the issues in the past. When rendering an interior scene, I would like to replace the background in post. I have had best luck by rendering the scene with a black background, and saving as a png. However, for some reason, it isn't actually rendering with black background unless I turn off GI environment, but then the lighting quality is lacking. If I uncheck reflection/refraction environment I get the results in the alpha that I want, but there is no reflection of the environment on my floor and other objects in the scene.

 

GI environment ON / Reflection/refraction environment ON:

Dune%20Deck%201_zpssvsf912w.jpg

 

GI environment ON / Reflection/refraction environment OFF:

Dune%20Deck%202_zpsbuvdpcxz.jpg

 

Even the second option with the r/r environment turned off is not saving the reflection in the alpha. This has never been a problem in the past, but I haven't had projects that have this view/condition in a long time, so I'm not sure what I'm missing to get this to render properly. Any suggestions would be great.

Link to comment
Share on other sites

What version of V Ray are you using? what type of lighting are you using in your scene?

 

If you are using V Ray sun/Sky it is just simple as, set your 3D Max environment to black then move the V Ray sky to the GI environment and Reflection/refraction environment overwrite in V Ray panel.

 

If you are using a dome light, then just check invisible, if you are in V Ray 3 you can also check/un check affect Alpha.

Link to comment
Share on other sites

Weird, that made the glass render properly, but the glass isn't allowing the environment in for reflection on the inside of the glass. Look at the floor.

 

DD%20test%2008_zpsqjgokavi.jpg

 

Below is a reference just so you can see where the glass is positioned. Only the one pane is moved from the door.

 

DD%20test%2006_zpsimex6hfd.jpg

Edited by Timothy Saunders
Link to comment
Share on other sites

After hours of trying every setting I can think of, I have been unsuccessful at figuring out this glass issue.

 

To sum up my needs:

1. black background, so I can replace the background)

2. have reflection saved in the alpha in a rendered png

3. have environment effects apparent in the reflections (floor particularly)

 

If anyone has a spare moment to download my file, I would love it if someone could take a look and let me know what I'm missing. Like I said, I have done this may times in the past, but I haven;t had a similar scene pop up for well over a year, so I'm not sure if there is a new setting I need to be aware of, or what.

 

Here is the scene I have made available.

DD%20test%2010_zpskemowhnd.jpg

Link to comment
Share on other sites

I am pretty busy here, so I'll seat and wait for your answer Juraj, but. even though I totally agree with you about it, I don't have the same problem than Tim is having, I get alpha, reflections no problems. Unless of course I am missing something on his workflow.

I don't think your 40 minutes were wasted if that will help several other people ;)

Link to comment
Share on other sites

That wasn't it :- ( I give up, I didn't use Vray for a year at the moment.

 

But it works as should with simple invisible Domelight.

 

18FQVru.jpg

 

(btw Tim, the .zip package didn't include the specular map from floor for me, so straight away people won't get reflections in any setup because it's only driven by map)

 

 

Ugh, the same behaviour is in Corona too when I converted the scene. Going to Ask Ondra...

 

TQQ2uwr.jpg

Edited by RyderSK
Link to comment
Share on other sites

Ondra explained me it's because of the last interaction the ray goes through, which is refraction that becomes reflection then.

 

Why I never noticed it before or why it's designed like this (obviously in both render engines)...

 

Outside of my solution with invisible Domelight, other solution is changing to thin glass and thus avoiding refraction.

Tested and works in both Vray and Corona.

 

1)Corona: Simply check "Thin" in Material, you can keep original volume geometry. Then simply do Visibility Override, not Refraction Override.

 

2)Vray: Apply Glass material without IOR in Refraction slot to preferably thin geometry and do simple refraction override.

The material needs "LOCK" unchecked next to IOR. It's important the glass still has fresnel 1.6 in reflection, but not in refraction.

 

 

Of course, this solution is visually identical, because you can't see any refraction in glass plane anyway if we're not doing caustics. See attached render : (the left glass has more reflection because I kept original geometry and thin glass thus reflect twice in there)

 

IhjSj1e.jpg

 

QDk531z.jpg

Edited by RyderSK
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...