3
$\begingroup$

I am trying to get good camera paths and pointing. I've been trying to use an Empty that follows a path as the "Track To" constraint object for my camera. I noticed some bad jumping and think I have tracked it down to a problem in the evaluation of the path. Up through frame 17 the empty tracks the path nicely:

Empty tracking path

At frame 18 the Empty "Leaps" off the path by .1 Blender units. This is quite a distance to be jumping off the path in 1 frame when the camera is only 2 Blender units away. This causes an annoying jump in the camera angle that I cannot seem to get rid of:

Empty not on path

Is there a better way to get smooth positioning? I don't really want to have to keyframe the Empty position for this as it would be an enormous number of keyframes (curved path). This looks like some sort of numerical instability. If it were a more gradual deviation, I could adjust for it by moving the control points of the path. I'd really like suggestions on how to address this.

To reproduce this:

  1. Start a fresh Blender session & delete everything.
  2. Add a path
  3. Add an Empty
  4. Add a "follow path" constraint to the Empty
  5. Choose the path you created as the target
  6. Select the path.
  7. Edit the path to have the following 10 points: -2 0 0, -2 -2 0, 0 -2 0, 2 -2 0, 2 0 0, 2 90 0, 2 92 0, 0 92 0, -2 92 0, -2 90 0
  8. Under Path Animation set 2 keyframes for "Evaluation Time": frame 1 to 0.0, frame 100 to 100.0
  9. Now toggle between frames 17 and 18 and see the "jump" to the right.

I've tried a number of things including inserting a lot more control points into the path, but the problem persists in one form or another.

$\endgroup$
  • 2
    $\begingroup$ in the future please consider uploading a file that shows the issue instead of having others recreate it from scratch. $\endgroup$ – cegaton Feb 19 '16 at 16:39
  • 2
    $\begingroup$ Try increasing the resolution of the curve. See: blender.stackexchange.com/questions/34471/… and blender.stackexchange.com/questions/22940/… $\endgroup$ – cegaton Feb 19 '16 at 16:40
  • $\begingroup$ Increasing the "Resolution" of the "Active Spline" solves the problem! I really wanted to upload the .blend file but couldn't find a way to attach it to the post. The only thing I found was a way to create a URL link, and I didn't have anyplace to drop the file to link to it. $\endgroup$ – IRayTrace Feb 20 '16 at 3:46
  • $\begingroup$ to add a blend file to the question read: meta.blender.stackexchange.com/questions/658/… $\endgroup$ – cegaton Feb 20 '16 at 6:40
1
$\begingroup$

I recreated your example just to see that happens, although on my system, the "interesting" frames were different.

Path is a parametric curve, P(t). It is natural that the dP/dT = (P(t+dt) - P(t))/(dT) is not constant. Blender is trying to find such a dT(i) for every i-th frame to make your point moving along the path in constant steps. And it fails sometimes.

This is happening because your path has a long segment (from y=0 to y=90), while your other segments are significantly shorter. You can try inserting more control points into the longest segment (just subdivide it a few times). This will increase the accuracy of derivative computations. I usually keep my segments at equal lengths.

PS if you shorten the longest segment, the error will reduce dramatically

$\endgroup$
1
$\begingroup$

The direct answer to this has been to increase the "Resolution" in the "Active Spline" panel. Bumping up to "48" made all my problems disappear.

$\endgroup$
  • $\begingroup$ It's perfectly OK to accept your own answer. For someone searching for a similar solution - if they see the green square indicating an answer has been "accepted" they may be more likely to stop and read. $\endgroup$ – uhoh Apr 6 '16 at 12:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.