5 Replies Latest reply on Feb 11, 2015 4:33 AM by lornaimw

    Motion blur and looping a character walk cycle

    lornaimw Level 1


      Hi all. See above images for the highlighted issue. Image 1 shows the blur problem. Image 2 shows end keyframe, Image 3 shows start keyframe, and Image 4 is a close up to show you the space between those keyframes.


      I'm using motion blur on a walk cycle, and using time remapping to cycle through it. Why is my character creating this horrible blur frame between the end and the new start? This happens if I use a loop expression as well, and have previously found that copying keyframes wasn't producing the horrible blur.. However it is back!

      Am I missing a trick? I have tried using hold keyframes as well. The first and last key frame should be identical. It works using looped RAM preview in my precomp, but in any other place this looks terrible!


      Any help would be greatly received Let me know if this needs further explanation too.

        • 1. Re: Motion blur and looping a character walk cycle
          Szalam Adobe Community Professional & MVP

          When you're looping something, the first and last frame should NOT be identical. If they are, you'll end up with a little hiccup in the motion. The frame RIGHT AFTER the last frame should be identical to the first frame.

          That won't help your motion blur issue, but it should help you in your animation overall.


          I'd suggest copying your walking keyframes so that you have a full walk cycle happening twice, then use your time remapping to go with a single walk cycle in the middle of those two. See if that helps.

          • 2. Re: Motion blur and looping a character walk cycle
            Mylenium Most Valuable Participant

            Well, a frame is a frame is a frame. AE interpolates everything based on genuine time, not just frames. So any sampling that occurs inbetween frames will behave the same, including overlap areas in loops. You need to adjust the timing accordingly or pre-render the cycle with motion blur before remapping it.



            • 3. Re: Motion blur and looping a character walk cycle
              lornaimw Level 1

              Thanks! This is how I've always done it, glad to know I can make it better!


              Mylenium That makes sense, I will gives these a go. Thanks to you both very much.

              • 4. Re: Motion blur and looping a character walk cycle
                Rick Gerard Adobe Community Professional & MVP

                I usually do not use motion blur on a time remapped sequence but use CC Force Motion Blur instead. You can get into some weird motion artifacts when using time remapping. I also would tie a walk cycle using time remap to the character's position using an expression. This makes it much faster to edit your animations. All you have to do is move the character into position, adjust the start position value in the expression and you're done. If you need to retime things you only have to move position keyframes.


                Here's a suggested workflow:

                1. Create a 10 frame long comp and call it Walk Cycle the size of your character to create a walk cycle
                2. Animate one complete strides so the left foot would be in exactly the same position at frame 1 and frame 10 (note: not frame 9, which is the out point of the 10 frame comp.)
                3. Nest my 10 frame comp called "Walk Loop" in a new comp that is long enough to give me enough walk cycles so the stride will cover the distance you want the character to cover. For example, if you stride length is 250 pixels and you want the character to walk from one side of a 1920 pixel wide comp then you need at least your comp width / your stride * the number of frames for a half stride. In this case 1920/250*5 = 38.4 so to give yourself some extra room make the Walk Loop comp 50 frames
                4. Time remap the nested walk cycle and add this expression:
                5. Move the the last frame of the Walk Loop comp and set a new out point for the nested Walk Cycle comp
                6. Add your Walk Loop comp to the main comp
                7. Apply Time remapping to the Walk Loop comp and then add this expression

                sp = -350;

                p = position[0] - sp;

                stride = 250/5;

                ap = p*thisComp.frameDuration;


                Here's what the expression does. The cs variable is the starting x position of Walk Loop comp. I've set it to start 350 frames left of the edge of the comp. The variable p is the X position of the layer minus the start position. The stride is the width of the stride in pixels divided by the number of frames to complete half a stride. In this case the left foot takes 5 frames to move from it's farthest left position to it's farthest right. The variable ap multiplies the position value by frame duration to convert a whole pixel to the time value of a single frame. Then you simply divide the adjusted pixel value by the stride. Now when you move the layer across the frame the feet accurately track with the ground. To make things really easy you could use an expression control slider for the sp value and just drag that around to set the resting stride position of your character.

                To make things easier to understand I created a simple comp using this technique. You'll find it HERE.  (note: Dropbox will probably add a .txt extension to the .aep file name. Just delete the .txt)

                • 5. Re: Motion blur and looping a character walk cycle
                  lornaimw Level 1

                  Thanks Rick, a helpful and detailed response.


                  It turned out motion blur wasn't the issue at all, but more the fault in my walk cycle. This is all great info to have put by.


                  Thanks very much!