Jump to content

My Crowds agents are glitching


MasterOldBear

Recommended Posts

Hello magicians,

I've been having this problem for a while. I've been experimenting a lot with crowds and today I feel I've hit a brick wall.

So the problem is rather simple but seems very complicated to me.

Long story short, my crowds have glitches for some reason and they don't loop. With Mixamo animation I feel like they are skipping a frame or something but I can see that the motion is not fluid, like they get stuck one frame.

I have prepared a scene for you, a scene with a situation where the glitch is very obvious. If you open the scene and check out the "Crowds" node, above frame 200 everyone just loses their walk cycle and starts again from another point.

In the same scene, I added my broken Mocapbiped 2 which literally snaps at one point and is not a loop. I just added it to the scene from the shelf and it's not looped. Isn't it suppose to loop? I feel like it should loop, and I messed something up. Why would you have a run cycle that's not looped. I feel like I messed something up but everytime I try to start a new crowd setup, tried all the tutorial and for me it's acting up.

With a mixamo walk cycle, I see the agent being looped correctly but when I start making my crowd it skips a frame.

It's been bugging me for a while and I think you magicians can have a better guess than I do. It's also annoying because the problem is not consistent. In the attached scene it heavily glitches, but with mixamo fbx it's barely visible but it's there.

My guess is that the framerate is not synced with the animation's framerate. Somewhere I have to set up my agent's animation, but I don't see a control for this anywhere.

I'm not necessarily a noob, I've been using it since h15, and the most simple problems humbles me every day. Also I have no one near me using Houdini...


Thanks in advance.

 

Crowd Setup Not Looping.hiplc

Link to comment
Share on other sites

It looks like on the Agent node you have the frame range set to Scene. This means the agent will loop over 1-240 frames or the playbar range. Change it to User Specific and dial in the start and end frames for the loop that matches your animation. In your example file I set the range from 1-24 which causes mocapbiped3 to loop seamlessly.

Edited by Atom
Link to comment
Share on other sites

7 hours ago, Atom said:

It looks like on the Agent node you have the frame range set to Scene. This means the agent will loop over 1-240 frames or the playbar range. Change it to User Specific and dial in the start and end frames for the loop that matches your animation. In your example file I set the range from 1-24 which causes mocapbiped3 to loop seamlessly.

Hello Atom. First I want to say is thank you for opening my humble scene :)

I have tried what you told me and it's still played in a hectic loop. I have attached a small video with the glitch that I have now. One thing I noticed on the Agent Node is that when I moved it to Use Specific the Start/End/Inc was green, animated. I had to Delete Channels to write 1-24, I think that messed him up. Also I feel like the problem is on the actual mocapbiped3 node.

I thought I messed up something and got paranoid, so I started a new scene and just dropped the mocapbiped3, set the first run and I can clearly see that it snaps somewhere at around Frame 16. In the attached scene I set the speed on the mocapbiped3 to 0.1 and I can see the snap from 161 to 162.

Maybe my Mocap Guys are sick, I think the snap was always there cuz I experimented on these guys a lot but now I want it to go smooth. Will try next adding a custom FBX loop and set the frame range properly in the Agent Node.

 

1-24 User Specific.mp4

Crowd Setup Not Looping_2.hiplc

Link to comment
Share on other sites

Each character motion is going to loop at a different time, setting the range is important (the green fields are placeholders that are meant to be deleted). After reviewing mocapbiped3, I have concluded that frame 17 is the loop point for the running animation, not 24. Try that number in your range instead. Also, don't change the speed of the animation on the biped to 0.1, leave it at 1.0. You were effectively time stretching your input, which is not good. Most of the time you want a 1:1 timing relationship with your agents before you submit them for simulation. Use the Gait Speed on the CrowdState node to adjust agent speeds after you have submitted your crowd source to DOPs for simulation.

When you make changes to the character rig or fbx that the Agent node is referencing, don't forget to click the Reload button to forward your new settings down stream.

crowd.gif

Edited by Atom
Link to comment
Share on other sites

On 8/22/2021 at 3:15 PM, Atom said:

Each character motion is going to loop at a different time, setting the range is important (the green fields are placeholders that are meant to be deleted). After reviewing mocapbiped3, I have concluded that frame 17 is the loop point for the running animation, not 24. Try that number in your range instead. Also, don't change the speed of the animation on the biped to 0.1, leave it at 1.0. You were effectively time stretching your input, which is not good. Most of the time you want a 1:1 timing relationship with your agents before you submit them for simulation. Use the Gait Speed on the CrowdState node to adjust agent speeds after you have submitted your crowd source to DOPs for simulation.

When you make changes to the character rig or fbx that the Agent node is referencing, don't forget to click the Reload button to forward your new settings down stream.

crowd.gif

This is great, thanks. In the meantime, I also managed to make FBX agents to loop like you said, using the range option, and I always need to click on reload to make sure everything is loaded properly and in sync. Yes, I will not change the speed there, but rather in the solver or using the Gait Speed.

Thanks for your advice. You are a legend! I understand the situation now and nothing can stand between me and my Agents Smiths :D

Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...