Jump to content


  • Content count

  • Donations

    0.00 CAD 
  • Joined

  • Last visited

  • Days Won


Everything posted by j00ey

  1. snap viewport image

    I always forget that!
  2. snap viewport image

    You can flipbook a single frame then in MPlay first do Render/New Sequence then go to Windows/Sequence List and you can toggle between multiple flipbooks. I've never actually needed that for stills but I use it all the time for comparing animations. There are various display options for comparison.
  3. Vellum strut setup

    I'm not a vellum expert but if you turn up the bend stiffness on the cloth constraint [as opposed to the struts] to say 50, the behaviour is similar
  4. find points and cut.

    This is a bit of a naive test but see if it helps chop_up_shape.hip
  5. inline vop

    I haven't looked at your scene but in the amended one of mine you've disconnected the enumerate SOP so there's no id attribute to bind, so it will always be zero and the conditions in the inline VOP always evaluate as false
  6. inline vop

    At a guess I'd say your loop isn't executing
  7. inline vop

    Also it's a good idea when you're testing things and figuring out what's going on in your shaders to work at the top level of a material network, not inside a material builder because you can assign anything as a material. What I usually do is make a null, call it 'test' and assign that as a material, then just plug things into that to test
  8. inline vop

    For a start you have id set as a vector output, and you're binding it as a vector too. It's an integer. I haven't really got time to try and unpick the logic of your for loop but it seems to me you're trying to run before you can walk. Houdini is telling you via the colour labels what's an int, float, vector etc. You need to be able to recognize them and know what data types you need to use to get what you're after. Don't overcomplicate with for loops, learn about basic stuff first like setting outputs in your inline VOP, writing to them, reading in geometry attributes, manipulating them and then outputting them.
  9. inline vop

    I hadn't actually read your code properly earlier but again you're setting a condition which can never be true. You initialise a variable id as zero, then you say if it's between 2 and 10 set the Cd variable, but it's always zero. For the id workflow I mentioned you need to read in the id from the geometry, in your sample scene you've set it as an output, and as a vector. Attached is a sample scene. inline_colour_by_id.hip
  10. inline vop

    Can you upload your scene and I'll have a look?
  11. inline vop

    Yes that should work. A good way to check what variables you have access to for free, put down a globals VOP and look at the list. If you want to use primnum, just give your geometry an attribute that mirrors it, eg id. You can do that with an enumerate SOP, or manually in a wrangle just put for instance: i@id = @primnum; then you can bind that in your shader and use it
  12. inline vop

    There are a few issues with this. Firstly, I don't think you have access to primnum inside a shading context. You can use something like id and bind that to do the same thing. But assuming you did that, it would be an integer, not a float. And this condition can never be true - a float can't be greater then 0.5 and also less than 0.45. ($primnum > 0.5 && $primnum < 0.45) Regards the declaration thing, you can actually write f@value=1; f@value = 2; because that's setting the value of a geometry attribute but you can't declare it twice - replacing f@ with float will throw an error.
  13. inline vop

    From what I can see in that screengrab it looks like you've got an output called pntList, in which case your line should read : $pntList = set(1,1,1); if you put 'vector' before it you are declaring it, and it's already declared. [Anything you put in your list of outputs is declared automatically]. Just like in a wrangle in SOPs if you write : float value = 1; float value = 2; you'll get an error, that should be float value = 1; value = 2; By the way, if you're setting a vector with constants you don't need to use set(). You can just write $pntList = {1,1,1}; Use set() if you need to set it with other variables, eg: float valueA = 1; float valueB = 2; vector values = set(valueA, valueB, 0);
  14. inline vop

    You can't make an output variable called pntColorList AND declare it in the body of your code. If you add the output and then change the line vector $pntColorList; to $pntColorList = 1; it won't error. Same goes for $pngList
  15. inline vop

    You can name your variables however you want to, you just have to make sure they match up if you want to export something for use outside the Inline VOP [but in the same VOPnet]. There's no @ syntax in Inline VOPs so @Cd will throw an eror. $Cd is fine. Can you put up a sample scene with your error in it and I'll take a look at it?
  16. inline vop

    There's no @ syntax in inline VOPs. If you want to export Cd, add it to the output section as a vector, then in your code you can refer to it - $Cd.r = $sUV; Presumably dPdt is declared somewhere above your snippet..? If not that will throw an error too. You don't have to use the $ prefix for variables that are only used internally in the Inline VOP but if you don't and you have more than one Inline in the same network using the same variable name, you'll get errors too.
  17. Understanding rand()

    It's not usually desirable to have a random number that changes every time it's evaluated, in general you want the same result every time you feed the function the same seed [in your case $F]. What I usually do is as merlino suggests, but I usually add 'seed', 'min' & 'max' parameters to the node [or a control null somewhere] and reference them, eg : fit01(rand($F + ch("seed")), ch("min"), ch("max")) If you do really want a different result every time you could write a python expression in the seed field to, for example, return the time.
  18. Yes that's right. From the docs : 'Calculates the area under a channel’s graph, which is the same as calculating the integral of a channel, or integrating the channel.' The slope CHOP does the reverse, they're both very useful.
  19. I would fetch the revolutions per second channel in CHOPs and use an area CHOP to accumulate the animation. Then you can export that to the z rotation parameter [or look it up with an expression]
  20. I'm perhaps misunderstanding the question but if you lookup the point number of a point in another geometry using @ptnum, it's always just going to give you the same value back, no? You're basically saying 'what is the point number of the point numbered @ptnum' *edit* Besides, I don't think you can look up point number. You could give the geo in input 1 an id attribute to mirror the point number and look that up, but still if you say 'what's the id of the point with number 3' it's just going to return 3.
  21. Can someone tell me what I'm doing wrong in this scene? It's a dummy scene with the same problem I ran in to and can't fix. I have a load of geometries which are pretty heavy and I want to instance them onto some moving and spinning points as packed disk prims. I'm setting the rotation just by picking a random axis and an angle based on the frame number and setting orient. I'm using the same vector and floats to set 'w' in order that I can get correct motion blur but it's not correct - it seems that the geo is rotating around the wrong pivot. [In this scene it's not actually hugely obvious that it's wrong because the scale is small but my actual scene is in the thousands of units and it's very obvious]. If I copy and pack with a copy SOP it appears to be correct but not instancing. I suspect I need to edit some primintrinsics, eg pivot, but everything I've tried so far doesn't work and I can't spot any difference in the intrinsics for either method. Any ideas welcome... Thanks for reading angular_velocity.hiplc
  22. TB Geo Locator HDA

    I recently worked on a job where I had to export scenes with hundereds of objects that all had to have their own animated transforms and no vertex animation. I couldn't use any of the usual copy to points workflows but positioning so many nulls at object level by hand wasn't practical. I made an asset to do some of the donkey work - it basically reads attributes from points and uses them for transforms. Rotation is calculated from a vector attrib [by default N], translation and scale are just looked up from the points. It defaults to using the digits in the operator string so you can just copy and paste it over and over and it will keep looking up the next point. In case it's of use to anyone, here it is. It's pretty straightforward but there is a help card and a quick demo video... TB__geo_locator.hdalc
  23. HDA - Rope Maker

    No problem - I hope it's useful
  24. HDA - Rope Maker

    In case it's useful to anyone, here's an asset I made a little while ago and finally got round to documenting. It takes one or m ore curves and generates 3 levels of braided curves - first level coiled around the input, second coiled around the first and the third around the second. Additionally it can make a final level of 'hairs'. It supports animated inputs, and will transfer velocity onto the output but in many cases it's probably better to use a timeshift to generate the rope on 1 frame and use a point deform or similar. This also avoids texture jumping problems if using the supplied 'pattern' colour method. There's a fairly comprehensive help card with it and below is a demo video. If anyone finds bugs or problems, please let me know and I'll try and fix them when I have time... I'd be very interested to see anything anyone makes with it... TB__RopeMaker_1_0.hda
  25. This will do it points_from_vector_array.hiplc