Jump to content


  • Content count

  • Donations

    0.00 CAD 
  • Joined

  • Last visited

  • Days Won


Everything posted by j00ey

  1. I got this to work in my proper scene but I had to use another workaround - when I switched to a different resolution it was computing the red colour in a few buckets but most of the image was black so what I did in the end was to render out temporary files from the pixel COP then read them back in before the VOP - I thought that wouldn't work inside an HDA but it did... Thanks for the help!
  2. Hi Kim Thanks very much - that's an ingenious solution! I was trying to avoid the pixel COP, it being so slow, but at least it works! I'm amazed that there's no U and V variable that I can use directly on the VOP, it's like not being able to do $PT/($NPT-1) in SOPs. Thank you again
  3. HI I have a problem with a couple of nested foreach SOPs that I can't for the life of me figure out. I have a load of spaghetti-like tubes and I want to add a random number of randomly sized gaps to each. I thought this would be relatively straightforward but it's just not working. I've put down a foreach primitive, and inside that a foreach number - on this one I generate a random maximum number, then inside of that I put down a carve SOP to make the random gaps but it's not behaving as I'd expected. I'm only getting back my first prim, but copied a lot of times [with carves] I've made a simple scene to demonstrate the problem. Can someone tell me what I'm doing wrong? gappy_tubes.hip
  4. foreach problem [H14]

    Yes I just discovered I needed to switch off the merge results. Thanks for the tip regards the for each indices though, I was just trying to figure out why the pattern is otherwise quite uniform
  5. foreach problem [H14]

    Ah I hadn't thought of that but it makes total sense. Thanks very much for the pointer.
  6. VEX problem / while loop

    Hi I'm trying to make an asset that will generate some curved lines with corners so I've written a sort of curving raytracer. It works with most settings but changing some variables I quickly come across settings where houdini just gets stuck. I can ESC out of it without difficulty and I can generate the geometry I need but I'd like to understand what's causing the problem. Attached is the hip. WIth the settings I've left it set at, it's quite happy to do 18 bounces but if you turn it up to 19 it sticks... Thanks for reading. * edit * Maybe I should explain quickly what it's actually supposed to do - for input points : while bounces is less than max bounce : using point normal, find intersection with second input geometry calculate distance between start position and intersection If distance is greater than step size, create a new point at step length away and rotate normal direction. If distance is less than step size, create a point at intersection position and set the normal to the reflection vector between normal and intersection normal curvetracer_v01.hip
  7. VEX problem / while loop

    Ah yes, I never thought I needed to compensate for the bias. Good thinking! Thanks again
  8. VEX problem / while loop

    Thanks very much for that Francois, I'll try it. After your initial I put in a statement to say : if hit_prim == -1 then break which fixed the problem but this is good for debugging...
  9. VEX problem / while loop

    Ah! Great, thanks Francois, you're right. I thought as the point is inside watertight geometry, it would never actually return -1. Do you know why it might be doing that?
  10. Hi I wonder if anyone can give me some pointers. I'm trying to set up a system that will take some polygonal geometry as an input and from all unconnected edges will grow new primitives in a direction governed by a number of forces [surface tangent, curl noise, gravity etc]. It's working up to a point already but I'm having problems getting self intersection testing to work smoothly. My method is to test for self intersection at the stage where I calculate the forces and if there is any, scale down the force, and if it's below a certain threshold set it to zero [ie stop growing]. The problem is that the self intersection can happen in a single timestep, rather than intersecting preexisting geometry it can intersect with a neighbouring new prim. It seems somehow I need to generate the next step's geometry, then branch off a timeshift to go back a step and do the intersection testing there. If anyone has experience with this sort of thing, does that sound like a route worth investigating? Or is there some other method I should look into? In case it's relevant, I'm trying to do as much of it as possible in VEX to keep it running fast. Also I've seen similar work where the geometry is remeshed on each frame but instead of doing that [for speed reasons] I'm looping over the prims and checking all the edge lengths and if any of them is greater than a given threshold I subdivide the prim. Thanks for reading...
  11. I'm sure I've read about this before but I can't find any information about it at the moment. Can anyone tell me if it's possible to render a volume as if it were polygonal geometry? What I'd like to be able to do is use a density threshold and somehow ray march through the volume until hitting the threshold and at that point is the hard surface - much like converting an SDF or VDB to polys but at rendertime. Maybe I imagined that you could do it...
  12. Rendering a volume as a hard surface

    Brilliant, thanks for the pointer Tomas, I will investigate.
  13. 2015 generalist reel

    This is my first reel with Houdini work on it after starting using H a couple of years ago. --> http://50percentgray.com/ There are no spectacular, huge sims or anything but I'd be very interested to hear any comments / criticism. Thanks for watching... *edit* There's a fair amount of other software in there too, a mixture mainly of Maya, Nuke, SFM Toolkit, RGBD Toolkit I'm finding though that I spend less and less time in other programs as I run into far fewer brick walls using H than I used to...
  14. 2015 generalist reel

    Someone brought to my attention that there was a separate setting for mobile and desktop start page on my site and the mobile one was still pointing to my old, non-Houdini reel. Fixed now in case anyone's looking on mobile is interested to see the new one...
  15. 2015 generalist reel

    Thanks Marty. Yes, the brain is an amazing object. I was surprised the reconstruction turned out as well as it did with all the gaps and occlusions, helped though by the complex surface patterning. Thanks by the way to you and all the others on here and sidefx forum whose advice and examples have been such a great help learning and exploring Houdini. The community here really is the best I have ever encountered.
  16. In case anyone is looking for the answer to this, have a look at this thread - http://forums.odforce.net/topic/20023-reading-voxel-by-index-in-dops/?p=119988
  17. VOPs don't have multiple outputs in the way you're talking about. The only thing difference though between your two inputs is the airresist so what Sadhu is suggesting sounds the right way to go to me.
  18. AOVs in VEX shaders

    Hi This is probably a dumb question, and makes me realise how little I really know about SHOPs. I have a scene with various shaders that I built myself with material shader builder nodes and I'm exporting a few AOVs inside. I just attached a constant shader to something though and realised I have no idea how to get it to output my additional image planes, and also I don't really know what this type of shader is and why it has a Surface Shader output... The only thing I can attach it to seems to be an Output Shaders node but I can't figure out what else I can plug into that to get my AOVs. Does anyone have a couple of minutes to explain A - what they are [the shaders with the stripy baseball icon - VEX shaders?] and B -how to get them to write extra planes? I know I can go in the type properties and see the code but I'm uncertain whether that's the way to go about it or if I'm missing something obvious... I hope someone can enlighten me...
  19. AOVs in VEX shaders

    Thanks Dany. I will look into that. By the way I haven't had chance to try your layered PBR shader on my new machine yet in case that clears up the errors. I'll do that soon as I get chance, after the weekend probably.
  20. AOVs in VEX shaders

    Hi Thanks for the reply. Good old Peter Quint! I had a quick scrub through those and I may be missing something but they appear to be about VOP materials, it's the ones that you can't dive inside and edit that I'm a bit confused about, see pic. I know how to edit VOPs and get my AOVs out of there but how would I go about getting say an ID pass out of something with Gingham Checks applied?
  21. Apologies if this is answered somewhere, I searched here and google and couldn't find the answer. I'm trying to figure out how to switch shaders based on whether a ray is a refraction or reflection - is there some way of doing that? I know there's Ray Bounce Level VOP but I'd like to differentiate further, something like Mental Ray's RayType switch. Thanks in advance.
  22. Thanks Eetu, I will dig into that and figure it out in that case.
  23. python setExpression problems

    I'm fairly new to python and I've written some code that generates a load of nodes, wires them up and so on and also a load of mantra ROPs. I'm now trying to write a custom prerender script that varies for each according to a couple of variables. That part is working fine but I can't figure out how to set the expression language to python. Here's the relevant code - prerender=mantraRop.parm('prerender') prerender.setExpression('metalswitch=hou.node(\'/obj/metalGeo/switch_metal_materials\')\ninput=metalswitch.parm(\'input\')\ninput.set(%s)'%int(metalnum)) from the help: To change the expression language, use hou.Parm.setExpression and explicitly specify the language: parm.setExpression(parm.expression(), language). so I've tried putting all sorts before the closing brackets [with a comma between] - 'python', python, Python, 'Python,0,1 Nothing works! Can someone help? Thanks very much
  24. python setExpression problems

    Took me a little while to figure out but I got it working. Thanks again both for your help though Graham, your advice is a bit over my head for the moment. I will come back to it once I'm more familiar with Python. In case anyone else comes across the same problem, this is a working version : prerender.setExpression('metalswitch=hou.node(\'/obj/metalGeo/switch_metal_materials\')\ninput=metalswitch.parm(\'input\')\ninput.set(%s)'%int(metalnum),hou.exprLanguage.Python) simplified to: prerender.setExpression('myExpression',hou.exprLanguage.Python) One other question - I need to continue writing the expression for another few lines, is there any way of putting in a line break in the code so in my editor it doesn't just run on for ever?
  25. python setExpression problems

    Hi Thanks very much for the input. Ayidi - I will look into that tomorrow but you are saying it is possible to set the language with exprLanguage? Graham - without being able to try it out that's a bit beyond me. I need the interface itself not to be displayed, or that is to say I don't want to have to display each interface but I might need to do for some reason or other. How do you put a string in without setExpression()? I did try just setting the value to a string but it wanted an int. Or am I getting mixed up? It certainly wouldn't let me set a switchSop input parm to a string without setExpression(). I'm not able to look at anything today any more but I will try again over the weekend. Thanks again