How to make Rigid Vertex Animation more accurate in UE4

   4557   9   3
User Avatar
Member
40 posts
Joined: June 2017
Offline
Hi,
I'm using the Vertex Animation Tool to export a large destruction animation to UE4. Unfortunately, on the first frae of the animation, most of the chunks seem disconnected and just a little bit off. They don't line up properly, so it breaks the illusion that the large structure is slowly falling to pieces.

Is there a way to make this more accurate? I have turned on full precision UVs in my models, and it looks like vertex color is exporting correctly (I think- at least, every chunk seems to have it's own color). I've also turned off normalizing from zero to one. I thought it might be a limitation caused by the size of my geometry, but I've seen this problem on much smaller sims, too. Is there anything else I can try?

Thank you!
Brian Kohrman
User Avatar
Member
394 posts
Joined: May 2017
Offline
What values are you using for your bbox min and max? If it's greater than 1000 then you're probably running into floating point precision issues. You could try scaling the sim down but you'd need to check rest, orient and pivot attributes as well (and possibly intrinsic transform).

We've considered another export method that use 2 pixels per position value but I haven't had a chance to test it out and implement it.

Mike
User Avatar
Member
40 posts
Joined: June 2017
Offline
Hi, Mike,
I thought of that, my min and max values are all between 100 and -100. If you have time to take a look, I've attached a very simple test hip file. It's just a shattering cube. When I bring it into Unreal and set up the material, I get something like the attached image. I am using full precision UVs, and I've tried both normalizing and not normalizing data. I'm sure I'm setting something up wrong. Do you have any suggestions?

Thanks again!

Attachments:
CubeTest_01.jpg (391.2 KB)
TestCube.hip (1.8 MB)

User Avatar
Member
394 posts
Joined: May 2017
Offline
Wanted to keep you in the loop. I thought it would be a quick fix but I think you've highlighted an underlying issue with how we normalize and then expand both the centroid and the position data. It doesn't happen with all setups and there's no immediate fix. I'll get back to you when I have something.
User Avatar
Member
40 posts
Joined: June 2017
Offline
Oh, good to know. Thanks! I have an idea for a hack that will work for me right now- in UE4, I will try ramping down the vertex offset to zero on the first frame. That should let me get my shattered object looking whole.
User Avatar
Member
394 posts
Joined: May 2017
Offline
Okay. This is silly it's so simple. Change your import style on the dopimport to “Fetch Geometry from DOP Network” and it will work. I'm going to speak to the team tomorrow to figure out what's happening under the hood since I'm sure I was the one that suggested you use fetch packed geo.

Mike
User Avatar
Member
40 posts
Joined: June 2017
Offline
Oh, awesome. Thanks a ton for digging into this! I'll post when I have it working. Unfortunately, I'm home sick today, or I'd try it right now.
User Avatar
Member
2 posts
Joined: Sept. 2015
Offline
mikelyndon-sesi
What values are you using for your bbox min and max? If it's greater than 1000 then you're probably running into floating point precision issues. You could try scaling the sim down but you'd need to check rest, orient and pivot attributes as well (and possibly intrinsic transform).

We've considered another export method that use 2 pixels per position value but I haven't had a chance to test it out and implement it.

Mike

I'm sorry to do this to this old thread, but Mike–do you think there's any chance this 2 pixel per position value could be implemented either as a ‘Large Object’-type switch in the output driver? It would be super useful as I'm struggling to scale down an already-cached sim, and don't want to go through the process of re-setting it all up as we've reached an art-directed result we're happy with.

Cheers!
Conrad
User Avatar
Member
394 posts
Joined: May 2017
Offline
Hey Conrad,

I've started work on an update to the Vertex Animation Texture ROP. That will include an option to provide more precision. But I probably won't release it in the next couple of weeks.

Mike
User Avatar
Member
2 posts
Joined: Sept. 2015
Offline
Hey! I wanted to update this to say that the tool has come a really long way - I noticed now in some occasions it seems to be using two pixels for position and rotation per frame which is great. One tip for anyone that finds this thread would be to make sure that your textures are set to ‘Nearest’ filtering mode which prevents a wobble on longer/larger rigid animations. I've not experienced it yet using the Soft settings but yeah, that will definitely help.

Cheers Mike
  • Quick Links