jumper Posted February 7, 2011 Share Posted February 7, 2011 Hi, I was taking a look at the thread over on the sidefx forum .... http://www.sidefx.com/index.php?option=com_forum&Itemid=172&page=viewtopic&t=15077&postdays=0&postorder=asc&start=25 haikalle had a example of a vector displacemnt shader that worked in h10 then stopped working with H11 ... The problem seemed to be the vex function.. vop_computeTangents($tanU, $tanV, normalize(N), $uv, 2); which is in the inline code vop... In the thread rafal suggests using vop_computeTangentsOld instead. This seemed to work for haikalle ... I tried to simply change the function to vop_computeTangentsOld myself but I was still getting the errors "/tmp/vop_VEX/displacement50280.vfl" line 110 ERROR (1023) Invalid number/types of arguments used to call "vop_computeTangentsOld" vop_computeTangentsOld(tanU, tanV, normalize(N), uv, 2); ^ "/tmp/vop_VEX/displacement50280.vfl" line 113 WARNING (2003) Write only or uninitialized variable "tanU" used as argument 2 for "normalize" nvec1 = normalize(tanU); ^ "/tmp/vop_VEX/displacement50280.vfl" line 119 WARNING (2003) Write only or uninitialized variable "tanV" used as argument 2 for "normalize" nvec2 = normalize(tanV); Looking at $HFS/houdini/vex/include/voplib.h the function signature for vop_computeTangentsOld() - I noticed the function needed some extra parameters - in_tanu, in_tanv so I added vectors {0,0,0} to the function... vop_computeTangentsOld($tanU, $tanV, normalize(N), $uv, {0,0,0}, {0,0,0}, 2); That stopped it erroring but I am not sure this is correct. Any help will be much appreciated! Thanks Stephen vectorDisp2.hipnc Quote Link to comment Share on other sites More sharing options...
bhaveshpandey Posted February 7, 2011 Share Posted February 7, 2011 (edited) you could use Compute Tangents operator instead of an inline if your not sure about it.. or you could just create a Compute Tangents operator in an empty SHOP net and check if your code is correct (by viewing it as VEX code).. I guess you also need to include voplib.h to use vop_foo functions inside an inline code operator.. hope this helps.. cheers. Edited February 7, 2011 by bhaveshpandey Quote Link to comment Share on other sites More sharing options...
jumper Posted February 9, 2011 Author Share Posted February 9, 2011 you could use Compute Tangents operator instead of an inline if your not sure about it.. or you could just create a Compute Tangents operator in an empty SHOP net and check if your code is correct (by viewing it as VEX code).. I guess you also need to include voplib.h to use vop_foo functions inside an inline code operator.. hope this helps.. cheers. Hey, Thanks for your help I'll take a look at the Compute Tangents operator. Cheers! s Quote Link to comment Share on other sites More sharing options...
smaugthewyrm Posted April 18, 2011 Share Posted April 18, 2011 (edited) this example of a vector displacement in mudbox really, really caught my eye. now that mudbox can paint ptex, and with houdini's support of ptex, then vector displacement support in houdini is even more attractive. Vector displacement and Ptex go hand in hand apparently. amazing detail can be added to very low poly base meshes with a mudbox / houdini workflow. amazing ear vector displacement Pixar Ptex Vector Displacement Mudbox (see timecode 3:22 if nothing else) 1000 poly base mesh. wow. (timecode 28:30) Edited April 18, 2011 by smaugthewyrm 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.