Chaos Corona Forum

Chaos Corona for 3ds Max => [Max] I need help! => Topic started by: jop on 2015-11-24, 14:44:40

Title: RefractionIOR below 1.0
Post by: jop on 2015-11-24, 14:44:40
Hi,

I try to render air bubbles under sea surface, so I have to set the refract IOR below 1.
Corona mtl don't allow this, so I tried with a corona color map plugged into the IOR slot, but I got weird results compared to what V-Ray does.

Do you have any idea ?

Thanks,
Jérôme
Title: Re: RefractionIOR below 1.0
Post by: maru on 2015-11-24, 15:38:38
If you are rendering bubbles in water seen from above - set their IOR to 1.

If you want your camera to be under water and seeing air bubbles, it's a bit tricky... I was only able to achieve this by placing a plane in front of camera (remember about position and orientation!), assigning a 1,33 refraction IOR to that plane, and then IOR 1 to the bubbles.
Title: Re: RefractionIOR below 1.0
Post by: romullus on 2015-11-24, 15:45:04
Corona mtl don't allow this, so I tried with a corona color map plugged into the IOR slot, but I got weird results compared to what V-Ray does.

If you're using Corona version prior to v1.3, then plugging 0-1 ranged map into IOR doesn't make much sense. In v1.3 however it should behave same as Vray, AFAIK.
Title: Re: RefractionIOR below 1.0
Post by: maru on 2015-11-24, 16:05:44
Corona mtl don't allow this, so I tried with a corona color map plugged into the IOR slot, but I got weird results compared to what V-Ray does.

If you're using Corona version prior to v1.3, then plugging 0-1 ranged map into IOR doesn't make much sense. In v1.3 however it should behave same as Vray, AFAIK.
I am not sure what Vray does, but Corona does something strange indeed. A lens with IOR below 1 should not flip what is behind it upside down, and it does in Corona. I think setting it to 1/1,33=~0,75 does the same as setting it to 1,33.
Title: Re: RefractionIOR below 1.0
Post by: jop on 2015-11-24, 16:16:42
Corona mtl don't allow this, so I tried with a corona color map plugged into the IOR slot, but I got weird results compared to what V-Ray does.

If you're using Corona version prior to v1.3, then plugging 0-1 ranged map into IOR doesn't make much sense. In v1.3 however it should behave same as Vray, AFAIK.
I am not sure what Vray does, but Corona does something strange indeed. A lens with IOR below 1 should not flip what is behind it upside down, and it does in Corona. I think setting it to 1/1,33=~0,75 does the same as setting it to 1,33.
I agree with you maru, that's exactly what I tried and it gave me same result as 1.33.

I use version 1.3
Title: Re: RefractionIOR below 1.0
Post by: romullus on 2015-11-24, 17:03:43
Quote from: 1.3 feature list
IOR value lower than 1 in textures will now render as 1/value, so you can use LDR maps without using output manipulation. This is to improve compatibility with applications such as Substance Painter.

Isn't the same what Vray does?
Title: Re: RefractionIOR below 1.0
Post by: jop on 2015-11-24, 20:37:08
Quote from: 1.3 feature list
IOR value lower than 1 in textures will now render as 1/value, so you can use LDR maps without using output manipulation. This is to improve compatibility with applications such as Substance Painter.

Isn't the same what Vray does?
I don't know what's V-Ray behaviour with textures as IOR, cause I only used to input direct values below 1.
Title: Re: RefractionIOR below 1.0
Post by: jop on 2015-11-25, 17:18:29
Do you think it is possible do allow values bellow 0 romullus ?
Title: Re: RefractionIOR below 1.0
Post by: romullus on 2015-11-25, 19:03:17
You'd better ask developers about this to be sure, but AFAIK Corona doesn't support IOR <1.
Title: Re: RefractionIOR below 1.0
Post by: maru on 2015-11-26, 13:24:54
IOR lower than 1 is not supported and it looks like there is no need for it.

Answer from the developers:

you can also assign the water material (fully transparent, refraction 1,33 - no other parameters are required) to the global volume material in render setup > scene, and then assign a material with 1.0 IOR to the bubbles

Title: Re: RefractionIOR below 1.0
Post by: romullus on 2015-11-26, 13:33:22
That is interesting! So if i want to render underwater scene with visible water surface, i should model air volume above, instead of water volume where the camera is located, right? That's need to be tested :]
Title: Re: RefractionIOR below 1.0
Post by: dubcat on 2015-11-26, 14:40:57
you can also assign the water material (fully transparent, refraction 1,33 - no other parameters are required) to the global volume material in render setup > scene, and then assign a material with 1.0 IOR to the bubbles

Cool. I've always made a sphere around my camera with water material on. Need to try this method next time :)
Title: Re: RefractionIOR below 1.0
Post by: maru on 2015-11-26, 14:54:50
At least it looks correct. I just put a plane with IOR 1 as the water surface.
Title: Re: RefractionIOR below 1.0
Post by: romullus on 2015-11-26, 14:59:59
Awesome!