rob Posted April 14, 2008 Share Posted April 14, 2008 (edited) Hi All , The default glass shader in 9.1 only seems to have a solid alpha ! theres no fall off at all in the alpha for use in compositing. I did some digging around and found a node in the shader that alters the alpha called AF_1 which you can lower but again it does not apply any fresnel effect to the alpha. I have enclosed a simple test scene and I am hoping that there is something simple I can add / alter to get the fresnel effect on the alpha aswell. rs_glasstest.hipnc Edited April 14, 2008 by rob Quote Link to comment Share on other sites More sharing options...
anamous Posted April 14, 2008 Share Posted April 14, 2008 Actually, this is the physically correct behaviour, since real life glass is refractive, which means that it is non-transparent. sounds funny but that's the way it is. But this isn't going to help you, and obviously one has come to expect a different output from other renderers. one way is to write a shader that outputs the fresnel as opacity (3 vops ) and set up an "alpha" pass where you assign that shader to all glass things and use the resulting mask in compositing. Quote Link to comment Share on other sites More sharing options...
Jason Posted April 14, 2008 Share Posted April 14, 2008 Actually, this is the physically correct behaviour, since real life glass is refractive, which means that it is non-transparent. sounds funny but that's the way it is. But this isn't going to help you, and obviously one has come to expect a different output from other renderers.one way is to write a shader that outputs the fresnel as opacity (3 vops ) and set up an "alpha" pass where you assign that shader to all glass things and use the resulting mask in compositing. If you set the ETA/IOR to 1.0 the shader might switch into a simple transparency mode and give you non-refractive glass with the Alpha you'd expect. It doesn't look much like solid glass anymore though. (The older glass shader did this, the new one might ALWAYS trace out the back of even non-refractive glass - I haven't tried it) Quote Link to comment Share on other sites More sharing options...
rob Posted April 14, 2008 Author Share Posted April 14, 2008 This is the physically correct behaviour, Thanks for the words guys. If this is physically correct , surely you then are limited when it comes to comping the various layers. Quote Link to comment Share on other sites More sharing options...
Jason Posted April 15, 2008 Share Posted April 15, 2008 Thanks for the words guys. If this is physically correct , surely you then are limited when it comes to comping the various layers. Yes, refraction does not make a simple composite. However, I wouldn't use the term "limited" because you can break all the components out using the DeepRaster capabilities and perform essentially the final computations of the shader in composite instead. I'm talking about splitting out the reflection result, the refraction result and the fresnel weight into separate layers and then doing the (simple) weighted blend in comp. Quote Link to comment Share on other sites More sharing options...
rob Posted April 15, 2008 Author Share Posted April 15, 2008 Dam it.I peel away one layer and you reveal another. I have been having such a hard time with the shaders in this application , Thanks Jason for giving me another thing to look at Quote Link to comment Share on other sites More sharing options...
anamous Posted April 15, 2008 Share Posted April 15, 2008 what jason describes is the most elegant way, check the attached file for a primitive extension of the default glass shader that has a toggle making it behave like glass shaders in some other renderers. hit render and check the alpha channel to see what i mean. cheers glass_alpha.hipnc Quote Link to comment Share on other sites More sharing options...
rob Posted April 15, 2008 Author Share Posted April 15, 2008 Anamous , your file is fantasitc. Not that I understand the vops fully, it would be doubtfull if I could of achieved your effeort without some expert knowledge. Thats whats causing me the most difficulty ! As theres not a lot of information out there to get me started ! Thanks R Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.