doc Posted January 23, 2008 Share Posted January 23, 2008 so I'm trying to snap my points to the edge of my SDF. The way I figure it, if I normalize the gradient of the volume and multiply that by the volumes value at the specified point, my point should snap to the edge of the SDF (where it's value equals 0). but the results seem to fall short. I've attached a file which shows my failed attempt, if anyone is able to point me in the right direction it would be greatly appreciated Many thanks L levelsetTest.hip Quote Link to comment Share on other sites More sharing options...
rjpieke Posted January 24, 2008 Share Posted January 24, 2008 I've attached a file which shows my failed attempt, if anyone is able to point me in the right direction it would be greatly appreciated In your point2 node, try changing: abs(volumesample("../isooffset1",0,$TX,$TY,$TZ))*-1*$NX To: $TX+abs(volumesample("../isooffset1",0,$TX,$TY,$TZ))*$NX For extra accuracy, link a few of these "adjustment chains" together, to refine your solution. See attached levelsetTest2.hip Quote Link to comment Share on other sites More sharing options...
doc Posted January 24, 2008 Author Share Posted January 24, 2008 Doh! Totally forgot to add the points original position, thanks Rob! 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.