Hello, I’m looking for some tips how to achieve the following:
Imagine I have a glass on a table with simple clear outside but a bumpy structure on the inside. In different software, I would split the NURBS object into outside facing part and inside facing part, assign a clear glass material + bumpy glass material and render.
If I do this, V-Ray gets confused because although the whole glass would be watertight, it’s two separate open objects. So it renders an error, e.g. total dark.
One idea I have is to do proper UV unwrap, but that would be very time consuming / impossible in some cases.
I experimented with the scene a little and you are correct - V-Ray does something funny when two different materials are used.
The fix I was able to apply involves UV manipulation and a single material with a slightly more complex bump/normal map.
Here’s what I did:
1. Ensure that the UVs of the inside and the ones of the outside are separated in the 0 to 1 UV square:
Ok, I see the issue now.
It is exactly the same as a problem I posted a long time ago, where I was wanting to use a bump for the back faces of a rear car
brake lamp. I never got any response to that, so used other methods.
Indeed, having to unwrap it does work but requires custom maps to split the surface, though is a good enough workaround for the
simpler though seemingly unachievable 2 materials approach.
Thank you for your answer, I tried your workaround before on a project and it didn’t work, I didn’t manage to get the mapping right and I got all desperate. Hopefully it was just some random glitch.
It would be awesome if V-ray could render this correctly without UV mapping. I believed that IOR and refraction are properties of an interface between volumes, not of the volume itself, so I thought, why not, it should render properly, the rays bounce through as if it was a solid. But I guess it’s not a random bug but a more complicated physics thing.
After an internal discussion it became clear that using two separate materials would never work.
The reason is V-Ray only calculates the correct IOR when the ray enters and exits the same exact material.
I also want to note that there is one alternative to the solution I showed earlier, one which does not require UV manipulation.
Here’s the idea:
Split the interior surface
Assign Object ID (1 for example) from the V-Ray’s object properties panel
Use a Multi-sub texture in the material’s bump slot
Add two textures
Set the default bump/normal color in slot 0
Add the interior normal map in the second slot (ensure that the Transfer Function of the bitmap is set correctly)
Apply the material to both the exterior and the interior of the glass
Wow, thank you Konstantin for the new solution, this one sounds really cool.
So in case of refraction, two materials are a no-no, but the object doesnt have to be one watertight object, it can be split in two and each of them can have different object ID. Will note it down.
Hello @konstantin_chaos , I was sure it worked before but now I’m trying it again, using RTX rendering and my good old RTX 2070 and multisub texture containing normal maps doesn’t work. Only for CPU rendering.
Is this a known limitation? Does multisub not work at all with RTX or only in some cases / with some textures?
Also, second thing:
For lowering normal map texture intensity using RTX rendering and Mix textures, I had to create a neutral normal map texture, because mixing a normal map texture with a neutral color in the second slot doesn’t work.
I think that what you’ve described is a limitation of the GPU engine.
I’ll log the multi-sub texture thing for sure and test the second issue you’ve described a little more.
Thanks for bringing this to my attention,
Konstantin