xanter Posted August 27, 2020 Share Posted August 27, 2020 (edited) Hi! My goal is to have control over volume density with ramp that is 45degree rotated , so to have ability set higher density at areas near corner of the object. I will upload scene file and screenshot , I was trying all day today but without success , I had managed what I wanted but it was done without ramp control , I need ramp control and ramp rotation ability. If you can tell me how to do that without opening that file it is also greatly appreciated , I uploaded scene in case you want to look inside my beginner skills.. thank you in advance ! test.hipnc Edited August 27, 2020 by xanter Quote Link to comment Share on other sites More sharing options...
Aizatulin Posted August 27, 2020 Share Posted August 27, 2020 (edited) Hi, one possible way might be using a curve to capture the u-attribute (with xyzdist() in a volume wrangle for example). Here is an example, using a float ramp (for density control) and an external curve for rotational control. test_capture_curve.hipnc Edited August 27, 2020 by Aizatulin Quote Link to comment Share on other sites More sharing options...
xanter Posted August 27, 2020 Author Share Posted August 27, 2020 (edited) vex vex vex )))) hate it , I mean I'm sure something is possible to do in VOPs without going deeper into coding VOP has tons of nodes and ramp node but I can't and I'm fighting that goal all day today. Thank you a lot for file anyway! meanwhile , I will try VOPs again .. ph... my head is cracking by pieces. I'm new at H so not surprised I'm having a bad day with it ) Edited August 27, 2020 by xanter Quote Link to comment Share on other sites More sharing options...
Aizatulin Posted August 27, 2020 Share Posted August 27, 2020 (edited) You can do the same in VOP, it is only about the xyzdist() function, which is doing all the work in the background. The only thing is, that you need a second input curve. If interested, here is a VOP version. Probably there simpler more straightforward solutions. test_VOP_xyzdist.hipnc Edited August 27, 2020 by Aizatulin 1 Quote Link to comment Share on other sites More sharing options...
xanter Posted August 27, 2020 Author Share Posted August 27, 2020 any chance to do that without including additional object like line? I mean just with ramp node in VOPs and rotate it after custom ramp is done. (I need a custom ramp) The thing is I want ramp over density control becasue it's not 100% gradient from 0 to 1 , I need 1 density till the center of a box and then from center to peak corner it increases to 2 lets say again thank you for help. Quote Link to comment Share on other sites More sharing options...
Aizatulin Posted August 27, 2020 Share Posted August 27, 2020 (edited) The ramp is just a function, which takes a float value. In my version it is the u-value of the position on the curve, where the point has its closest distance to. For example, if this is the center of a line (where the point has its closest distance) the u-value is 0.5, The rotational effect comes from the input value (which comes from the curve) and not from the ramp. Another approach can be just rotating the box (outside) and after this applying the ramp function and then rotate the box back. You can just use the vop from your example. I'm strongly biased to VEX (it is much faster and easier to use - but this just my personal opinion). Here is another file (1 line VEX to capture input and set detail attribute) test_VOP_rotate.hipnc Edited August 27, 2020 by Aizatulin Quote Link to comment Share on other sites More sharing options...
vicvvsh Posted August 28, 2020 Share Posted August 28, 2020 Hi, this is just a concept of how to use ramp for rotation control, but i think a float parameter is more convenient. test_01.hipnc Quote Link to comment Share on other sites More sharing options...
xanter Posted August 28, 2020 Author Share Posted August 28, 2020 (edited) 4 hours ago, vicvvsh said: Hi, this is just a concept of how to use ramp for rotation control, but i think a float parameter is more convenient. test_01.hipnc that is amazing and what I was expecting, we have rotation control , now the thing here is to control the density with ramp. you named second ramp node "density_" , but it has no affect on density of volume . P.S I thought it has no affect to ramp but looks like it's a bug , I'm changinf density in name parrameter and it works so you have to change a name and get it back again in order to see changes in density ramp , I need to report it I guess. Does your houdini version density ramp updates instantly while changing ramp curve ? thank you for your file it solves my task, bless you! Edited August 28, 2020 by xanter Quote Link to comment Share on other sites More sharing options...
vicvvsh Posted August 28, 2020 Share Posted August 28, 2020 1 hour ago, xanter said: you named second ramp node "density_" , but it has no affect on density of volume . I named ramp that i added as "rot_ramp" (actually as "rot_amp" but that was a typo) 1 hour ago, xanter said: Does your houdini version density ramp updates instantly while changing ramp curve ? Yes it does, it works as should be, H 18.0.524 Quote Link to comment Share on other sites More sharing options...
xanter Posted August 28, 2020 Author Share Posted August 28, 2020 what tha hell is wrong with my version then ...((( Im changing ramp and density stays same without changes , I have to rename ramp name to have changes updated in viewport.. damn . 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.