Jump to content


  • Content count

  • Donations

    0.00 CAD 
  • Joined

  • Last visited

Community Reputation

0 Neutral

About danvenn

  • Rank

Personal Information

  • Name
    Dan Venn
  • Location
  1. Crystals

    This is cool! Could you post a wireframe?
  2. Thanks for the advice. Taken a break this week but this is today's progress. The points behave except for pt[0], and there's an offset starting from pt[1]. I simplified to the code down to this: float offset = ch("dist"); for(int i = 0; i < @numpt; i++) { float point_dist = point(0,"cumuldist",i); // float totaldist = offset + point_dist; //get U on curve using arclength float u_unit = primuvconvert(1, totaldist, 0, 10); // //get position of U on curve vector pos = primuv(1, "P", 0, u_unit); //get tangent vector on curve at U. vector tangent = normalize(primduv(@OpInput2, 0, u_unit, 1, 0)); setpointattrib(0, "P", i, pos, "set"); } This works quite well but is a bit inaccurate because it uses the u-value taken from the arclength. I added a cumulative distance attribute beforehand. I might rewrite the rotation section I took out to a method I understand a bit better.
  3. Yeah that was my intended use case too, with points. It seems like I'm almost there but getting a bit confused. What is primduv used for, aka 'position derivative'? float dist = ch("dist"); for(int i = 0; i < @numpt; i++) //removed group code and simply run this over the input points { float point_dist = point(0,"distance",i) // added interpoint distance as attribute; vector size = set(point_dist,0,0); dist += point_dist; float u_unit = primuvconvert(1, dist, 0, 10); //changed to the 1D form of primuvconvert vector pos = primuv(1, "P", 0, u_unit); vector tangent = normalize(primduv(@OpInput2, 0, u_unit, 1, 0)); matrix mat = matrix(dihedral({1, 0, 0}, tangent)); //changed vector-a to x direction (input points go that way) translate(mat, pos); pos = point(0, "P", i); pos *= mat; setpointattrib(0, "P", i, pos, "set"); } Looks like it's rotated from where it should be: Using Petz' code, a workaround could be converting the input points to spheres with radius `@joint_length` , then replacing the transformed spheres with their center points. But I imagine at that point it's quicker to use the iterative way? geo_along_curve_edited.hipnc
  4. @petz this is great thanks - didn't know about primuvconvert
  5. Thanks, I'll give it a go and report back Was reluctant to do an iterative approach but might be the only way!
  6. Thanks for your reply. Do you know if I would I need to use nearpoints() for this and choose the last item of the array? Or is there a more efficient function to use? Everything seems to allow for a maximum search distance but not a minimum.
  7. Hi I'm trying to make a chain of points follow a curve, maintaining the distance between them. I can achieve this in a rough way by using primuv/ primitive attribute in vops and offseting the U value by the distance. However this doesn't preserve the length L, due to the curvature. How would I find the 'chord' points of the curve along the vector P1P2 ? Another way to think of this would be the intersection of the curve and a sphere of radius L. Are there helper functions already part of Houdini that will allow me to do this? Thanks
  8. Thanks this is perfect - quite involved as you say. Something that can be turned into a HDA though. A good excuse to brush up on my calculus Thanks for this, could you explain a little how this works? Struggling to make sense of it as I'm not often using CHOPs.
  9. Is there a way to distribute points on a line according to a ramp's density? I'm aware of the scatter node's density input , but that uses a random sample which isn't ideal for my use case.
  10. How do you guys deal with assembling a scene in Houdini? For example, say I make a ceiling tile, a floorboard, some wall panels etc. as separate geo nodes. Is there a way to arrange these procedurally on an object level? Or should I be working on one big 'room' SOP with subnets? Is there a general way one should think about piecing nodes together?
  11. I've been playing around with the autorigger, which seems like it could be very useful. However, its set up in a way which likes to flip bones if you push the IK controls to the limit. For example, in a handmade rig if the foot control is dragged lower than the length of the leg, the toes will point downward nicely. Here I'm getting a nasty 180deg turn. What's the cause of this? Has anyone got any advice for preventing bone flips and pops? I don't really want to be adding pole vectors to the foot bone!
  12. Hi, I'm playing around with limiting transform handles on nulls to act as a rigging control surface. I found on these forums a cool hscript snippet that allows this: clamp(cubic(),min,max). Does anyone know the python equivalent? The python clamp doesn't seem to accept a cubic() as a parameter. Also, does anyone know of another method of allowing for manual transform handle input that feeds into an expression? (HScript or Python). I can't wrap my head around why cubic() works! Cheers Dan