brianburke Posted September 29, 2009 Share Posted September 29, 2009 Hi guys. I'm wondering what numbers I should use to tell Houdini "infinity". For example, in a max() function I want to make a number dip as low as possible but never to zero, what number should I use. On the other end, what should I use to set the maxdist of a ray tracing function to the maximum possible? I tend to just put a bunch of zeros or a bunch of nines, but surely there's something more correct to put? Thanks! Quote Link to comment Share on other sites More sharing options...
DanBode Posted September 29, 2009 Share Posted September 29, 2009 Just a guess, I believe that Vex is based on C, so I did a quick search for the maximum and minimum that C can store in floats. This is what I found: http://cplus.about.com/od/learning1/ss/clessonone_6.htm Hope it helps! Dan Quote Link to comment Share on other sites More sharing options...
crunch Posted September 30, 2009 Share Posted September 30, 2009 Hi guys. I'm wondering what numbers I should use to tell Houdini "infinity". For example, in a max() function I want to make a number dip as low as possible but never to zero, what number should I use. On the other end, what should I use to set the maxdist of a ray tracing function to the maximum possible? I tend to just put a bunch of zeros or a bunch of nines, but surely there's something more correct to put? Thanks! I'm pretty sure that for maxdist in ray-tracing functions, if you set it to -1, mantra will choose the maximum distance for you. Otherwise, use the defines in limits.h (the single precision limits would be suitable I think) Quote Link to comment Share on other sites More sharing options...
brianburke Posted October 1, 2009 Author Share Posted October 1, 2009 Otherwise, use the defines in limits.h (the single precision limits would be suitable I think) Hey cool, this is perfect. Thanks! 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.