Mzigaib Posted June 10, 2010 Share Posted June 10, 2010 (edited) How can I make my reflection falloff on distance? I have a control for attenuation density for interior color, but not for reflection. Edited June 11, 2010 by Mzigaib Quote Link to comment Share on other sites More sharing options...
Mzigaib Posted June 12, 2010 Author Share Posted June 12, 2010 No one? isn't there a way to make my reflection fade according to distance? Quote Link to comment Share on other sites More sharing options...
petz Posted June 13, 2010 Share Posted June 13, 2010 quick example file attached! petz reflection.hipnc Quote Link to comment Share on other sites More sharing options...
Mzigaib Posted June 14, 2010 Author Share Posted June 14, 2010 Thank you very much for the file, that´s exactly the result what I was looking for. But isn't there a way to achieve this result through VOP nodes without having to write a code? I am just asking that because I know very little about shading writing and I was wondering if I could do it myself without have to write any code. Again I really appreciate the help that you gave me and I know that learning hoe to write would be part of the job, but it doesn't hurt to ask. Cheers! Quote Link to comment Share on other sites More sharing options...
petz Posted June 14, 2010 Share Posted June 14, 2010 Thank you very much for the file, that´s exactly the result what I was looking for. But isn't there a way to achieve this result through VOP nodes without having to write a code? I am just asking that because I know very little about shading writing and I was wondering if I could do it myself without have to write any code. Again I really appreciate the help that you gave me and I know that learning hoe to write would be part of the job, but it doesn't hurt to ask. Cheers! same in vops. hth. petz reflection_vops.hipnc 1 Quote Link to comment Share on other sites More sharing options...
Mzigaib Posted June 14, 2010 Author Share Posted June 14, 2010 Thanks you very much, this will really help, though this one seems more complicated than the one with the inline code. Can you give an advice where can I start to learn vex shader writing? Again thanks for the help. Quote Link to comment Share on other sites More sharing options...
Mzigaib Posted June 14, 2010 Author Share Posted June 14, 2010 Hi, it's me again. Isn't there a way to make this effect on the reflective material on houdini gallery? There I have all the things that I need I just need to add this effect, I tried to use your vops on it but I wasn't successful,I was thinking in a way just to modify the nodes before the reflect VOP inside the reflective material but my knowlege is limited to do it. Anyway thanks for the help. Quote Link to comment Share on other sites More sharing options...
Mzigaib Posted June 15, 2010 Author Share Posted June 15, 2010 same in vops. hth. petz Even being a newbie on making shaders, I did get to do what I wanted with your code even don't understanding all of it, using it to just modify the reflective material, so I would like to know what you think since you helped me to build it. But if theres a better or simpler way to do it let me know. Thanks again. reflectiveAttenuation.hipnc Quote Link to comment Share on other sites More sharing options...
petz Posted June 18, 2010 Share Posted June 18, 2010 (edited) Even being a newbie on making shaders, I did get to do what I wanted with your code even don't understanding all of it, using it to just modify the reflective material, so I would like to know what you think since you helped me to build it. But if theres a better or simpler way to do it let me know. Thanks again. in your example you are using gather() for measuring the raylength and the trace-vop for the reflection. since the trace-vop internally also uses gather() you force mantra to do the same job twice. to avoid this overhead you can do two things: - replace the trace-vop completely by the gather-vop or use gather() inside an inline-vop for computing the reflection and raylength - modify outer and inner code of voplib.h under $HH/vex/include and the trace-vop so that the raylength will be returned. but i would suggest to let the header files untouched exept you know exactly what you are doing. assumed you don´t need glossy aka. blurry reflections it´s easy. rayhittest() or the rayhit-vop returns the raylength which you can use for the reflection-falloff. hth. petz Edited June 18, 2010 by petz Quote Link to comment Share on other sites More sharing options...
Mzigaib Posted June 18, 2010 Author Share Posted June 18, 2010 - replace the trace-vop completely by the gather-vop or use gather() inside an inline-vop for computing the reflection and raylength - modify outer and inner code of voplib.h under $HH/vex/include and the trace-vop so that the raylength will be returned. If I just replace The Trace-Vop for the Gather-Vop will it do the trick? I am asking this because replacing codes it's too advanced for me at the moment. But anyway thanks for the tip. Quote Link to comment Share on other sites More sharing options...
Mzigaib Posted June 18, 2010 Author Share Posted June 18, 2010 (edited) Is there a way to to do the same thing that you did with the gather vop but instead use the trace vop? Edited June 18, 2010 by Mzigaib Quote Link to comment Share on other sites More sharing options...
Mzigaib Posted June 30, 2010 Author Share Posted June 30, 2010 (edited) I think I got it! See what you think about my try to use trace vop and rayhit to add falloff to my reflection. Now I got what you meant about the blurry reflections, with this technique I can´t use it, if I want it in conjunction with reflection falloff the gather vop is the only way right? Since I am using the gather VOP I would like to add all the features that the trace vop has for reflections, so I didn't figure out how to put jitter and the backgound color options, any tips would be nice. Anyway thanks again. reflex_falloff_with_trace_vop.hipnc Edited June 30, 2010 by Mzigaib Quote Link to comment Share on other sites More sharing options...
petz Posted July 1, 2010 Share Posted July 1, 2010 I think I got it! See what you think about my try to use trace vop and rayhit to add falloff to my reflection. Now I got what you meant about the blurry reflections, with this technique I can´t use it, if I want it in conjunction with reflection falloff the gather vop is the only way right? Since I am using the gather VOP I would like to add all the features that the trace vop has for reflections, so I didn't figure out how to put jitter and the backgound color options, any tips would be nice. Anyway thanks again. you are on the right track! attached is a file with a modified trace-vop that should do what you want. its coded but it shouldn´t be too hard rebuilding it with vops. btw. dont forget to load the otl trace_refl_falloff.rar Quote Link to comment Share on other sites More sharing options...
Mzigaib Posted July 4, 2010 Author Share Posted July 4, 2010 Man I can´t thank enough for the help Your otl would give me just what I want, what I need now it´s just to understand how it works for learning purposes. My Code skills are still in the very beginning in fact until now I just worked with the Visual Vex which is awesome, I also need to study more about the gather VOP, which by what I saw that it can give you a great amount of freedom to build cool stuff with reflection rays maybe more. Man, I really feel a little ashamed to ask but if isn't much trouble would be really great to have your OTL coded on VOPs. Anyway thank you very much for the help. 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.