haggi Posted January 26, 2016 Share Posted January 26, 2016 Hi, I try to learn how Houdinis crowd simulation tools work. Before I start with a rigged character, I'd like to understand how all the basics work with a very simple setup. Thanks to Atoms nice tutorial ( ), I did a setup for a simple box. The boxes are wandering over a hilly ground. All I want at the moment is that the boxes should be oriented along the normal of the ground, how can I do it? The simple file is attached. crowd.hiplc Quote Link to comment Share on other sites More sharing options...
Atom Posted January 27, 2016 Share Posted January 27, 2016 (edited) Dive into your crowd_sim and select the crowdsolver1 node. Activate the Terrain tab and type /obj/ground/mountain1 into the SOP path. If you have a different named terrain simply use the Browse button to select the terrain mesh directly. Either way you will get a path. You could also just delselect all while at the OBJ level and use the Crowd Terrain shelf tool. Click that and it will invite you to select the terrain object and press ENTER. The tool just populates the Terrain SOP path for you. Edited January 27, 2016 by Atom Quote Link to comment Share on other sites More sharing options...
haggi Posted January 27, 2016 Author Share Posted January 27, 2016 Thanks Atom, my problem is not to use a terrain object, but the orientation of the agents. They follow the profile, but they do not follow the slope of the ground, they are always horizontally oriented. I'd prefer if they bank if they climb a hill. Quote Link to comment Share on other sites More sharing options...
edward Posted February 2, 2016 Share Posted February 2, 2016 The terrain adaptation was designed for characters in mind which don't have such a simple way of following terrain. For something simple like this, the easiest way is as a post process. Append an Attribute Wrangler after the crowd_sim_import SOP and do: (ensure you have Terrain Projection enabled in the Crowd Solver DOP, but Terrain Adaptation DISABLED) p@orient = qmultiply(normalize(dihedral({0,0,1},normalize(v@heading))), normalize(dihedral({0,1,0},normalize(v@terrainnormal)))); Quote Link to comment Share on other sites More sharing options...
bretik Posted February 9, 2016 Share Posted February 9, 2016 Hi, I have same problem, it work with edward solution but just until te agent rotate (heading), and than its rotated in a wrong direction... Quote Link to comment Share on other sites More sharing options...
bretik Posted February 9, 2016 Share Posted February 9, 2016 At start all heading in Z direction.. and so its working.. http://postimg.org/image/ejir4zlcb/ but once they change direction... its not working any more... http://postimg.org/image/bo12kdryj/ Quote Link to comment Share on other sites More sharing options...
edward Posted February 11, 2016 Share Posted February 11, 2016 Ants are supposed to work in H15 with terrain adaptation provided you've done the agent set up correctly specifying all the limbs. Quote Link to comment Share on other sites More sharing options...
bretik Posted February 11, 2016 Share Posted February 11, 2016 Hi, no, Because Im importing it from FBX... is there way to specify limbs in fbx? Quote Link to comment Share on other sites More sharing options...
bretik Posted February 11, 2016 Share Posted February 11, 2016 Yes I see It now.. in agentprep node ..so going to try It.. I will have 6 lower limbs ...rigt? THX! Quote Link to comment Share on other sites More sharing options...
bretik Posted February 11, 2016 Share Posted February 11, 2016 ok Its moving just ankle>toe orientation I need to rotate whole Ant along Surface normal ... ? Quote Link to comment Share on other sites More sharing options...
edward Posted February 14, 2016 Share Posted February 14, 2016 Try setting up the Hips and/or Lower Back in the Agent Prep, those are supposed to tilt as the rig goes up the terrain. Quote Link to comment Share on other sites More sharing options...
bretik Posted February 17, 2016 Share Posted February 17, 2016 (edited) xxx Edited February 19, 2016 by bretik Quote Link to comment Share on other sites More sharing options...
Atom Posted February 17, 2016 Share Posted February 17, 2016 I tried setting up the HIP and Feet on bretik's original file and it does not work. I believe the crowd system has issues with non biped agents. That is why I mentioned the particle approach in the other thread. It is still possible if someone can figure out the math. Basically we need an orientation formula based upon the normal of the terrain. A VEX math wizard. 1 Quote Link to comment Share on other sites More sharing options...
bretik Posted February 18, 2016 Share Posted February 18, 2016 Atom you have some sample file for particle approach please ? Quote Link to comment Share on other sites More sharing options...
Atom Posted February 18, 2016 Share Posted February 18, 2016 Check the links page in my signature. Quote Link to comment Share on other sites More sharing options...
Atom Posted February 21, 2016 Share Posted February 21, 2016 I just noticed this post on Matrix manipulation. Could any of that code help with crowd terrain orientation? http://forums.odforce.net/topic/25160-matrix-in-wrangle-sop/ 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.