CoD Modern Warfare reboot moving cloth shader?

Hi, I’m pretty new to shaders just started some tuts a couple weeks ago. Today in the new CoD trailer I noticed a pretty cool effect in the clothes of the soldiers where it vibrates because of the strong winds before jumping off the plane or from the helicopter.

as seen at 0:50 and 1:20

I believe this cloth isn’t physics based, it looks like maybe a mesh or texture affected by some render target magic?

I know I don’t make a lot of sense but could somebody explain me what’s going on here and point me in the right direction to replicate this?

Thanks :slight_smile:

Those are both in game cinematics, so most likely it’s just sim’d in a 3d package and baked into the animations for those sequences. Model probably gets swapped to a gameplay model when you regain control of your character.

1 Like

I was wondering about that, they had an “Actual in-game footage” as opposed “Game Engine footage” which had me a little confused, if they are actually doing like a wind simulation shader on their in-game models, that’d be pretty cool.

I feel like it would actually pretty easy to do as a Vertex shader though, as long has you have like a fold mask or something to drive parts that move/ don’t move. You’d need enough mesh density though, which you will probably have on character models.

There’s no doubt it was in game, but that doesn’t mean everything is done dynamically, that just means the game is rendering everything vs loading and playing a video. The shots mentioned at :50 and 1:20 could have still had custom one-shot animations for those sequences.

What if the scarf is quite high poly instead of a normal map. Cause it looks like a vertex shader, offseting over surface normal. They could easily switch out the scarf mesh for a lower poly one once they go in game.

I’m going with @Travis on this one, it’s most likely all simed. I say this because we’re around E3 right now, and these trailers are the start to a volley of marketing. The odds for fakery stack up around this time. Pinch of salt and all that. :salt:

Cool though. :slight_smile:

My guess is just vertex shader trickery really. I feel like using sims for this would be a bit overkill and possibly harder to control?

3 Likes

There’s no need to control it? The only shots that cloth is moving with wind are in game cinematics. It would be way more straight forward to simulate the cloth with physics and bake it out for those shots. It would take way more effort to build a shader with a bunch of vertex movement, tweak it over and over to get something that’s both realistic and doesn’t clip through the character, probably custom UVs on all those uniforms. I’m directing that ^^^ at the 1:20 shot on the helicopters; the scarf and sleeves in the plane jump shot would be easy enough to do with some simple vertex stuff.

1 Like

https://youtu.be/RbfhmuxsorY?t=157

3 Likes

They might have used Apex framework cloth physics on this with regards to the rig to create that has nice real-time simulation and wind simulation on it. :slight_smile:

The cloth caught my eye too, my first guess would be vertex shaders. I don’t see any reason why it wouldn’t be done that way, the cloth is probably highpoly enough to do it.

1 Like

If that’s simulated I will eat my hat. A couple of sine curves in the vertex shader could do that and more.
Looks sweet though!

2 Likes

Doesn’t looks simulated at all. Something similar could be achieved with simple vertex offset driven by panning textures and influence mask baked into vertex color.

1 Like

Hey thanks all for the replies :slight_smile:

1 Like

Hmmm. :confused:

Well… looks like I need to update my understanding on vertex shaders vs baked simulations. :sweat_smile:

Learning!

2 Likes

The other thing is, if this is a vertex shader, they could potentialy use it in game as well, as it would scale with the amount of vertices, this would make it more useful as a time investment.

I will not join the hat eating if I’m wrong though, sorry @Partikel :smiley:

1 Like

Lol, now that there is potential hat eating on the line, im going to go ahead and ask one of the FX artists at IW how they did it. I still think its a vertex shader as well but let’s hear it from the horse’s mouth.

3 Likes

My experience was our animators always took care of that kind of stuff, so that’s why I suggested it could be simulated for that one shot (the helicopter shot, not the back of the plane)

Please do! In the meantime Digital Foundry has uploaded a video about it

It says that everything is in-game “no cg fakery, no in-engine footage” all running on ps4 pro says.

Will be interesting to hear how it was done. To me it looks like vertex shader trickery rather than sim.