reinforcedcc Posted April 4, 2018 Share Posted April 4, 2018 (edited) "This is necessary for the calculation of internal power in the construction of the roof of the building. (Maxwell-Cremona diagram)" I have several primitives - these are lines. Each next primitive must be placed at the point # 1 of the previous primitive, and so on. I need to automate the process in a loop (and not as I did here - manually ). (The problem is solved correctly if everything closes) desk_21.hip Edited April 4, 2018 by reinforcedcc Quote Link to comment Share on other sites More sharing options...
PlatinumFishy Posted April 7, 2018 Share Posted April 7, 2018 I’m sorry I am a little confused about what you are asking. Are you truant to make a Maxwell Cremona Diagram but in houdini? Quote Link to comment Share on other sites More sharing options...
reinforcedcc Posted April 7, 2018 Author Share Posted April 7, 2018 the diagram is constructed, but for the procedural process I would like to make this block in a loop desk_22.hip Quote Link to comment Share on other sites More sharing options...
PlatinumFishy Posted April 7, 2018 Share Posted April 7, 2018 So, what you need to be using is a for each loop. There are many ways the for each loop can be configured though, making them hard to figure out. Here are some differences key dofferences off the top of my head. A point wrangle (essentially a for loop over points) will do a set of code for each point, it will be able to access information from other points, but it will not actually commit those changes until the end. ex. Say I had 5 points each with an attribute value “value” equal to two. If I said to add the previous points “value” to the current points “value”, the values would all wind up being: 2, 4, 4, 4, 4. Rather than 2, 4, 6, 8, 10. By default, a for each loop will isolate whatever piece it isn’t working on. So if you are working on primitives, it would delete every other primitive except for the current iteration. Then at the end it will merge all the iterations together. The problem with this is that you are unable to access other parts of your geometry. And then there is a mode that will go through each and every piece, but will do it as a whole (meaning it does NOT isolate every piece beforehand) AND it will update the entire geometry before going through the loop again. I am pretty sure this is the type of loop that you want, so do some research into for loops on houdini’s documentation. 1 Quote Link to comment Share on other sites More sharing options...
anim Posted April 8, 2018 Share Posted April 8, 2018 here is an example using for loop to iterate over each primitive, but still assemble in a feedback loop to keep appending primitives desk_22_fix.hip 1 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.