diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-11-10 07:58:37 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-11-10 07:58:37 +0300 |
commit | 9471855be5a2d83ececd54641fde533871069b13 (patch) | |
tree | feb660a0cbd07247357abc312f9a75eb7726e69d /source/blender/blenkernel | |
parent | df028b90a3fafaef4eec923b7caf7f8b786983ad (diff) |
correct some comments and fix for allocating more memory then needed for animation paths.
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/intern/anim.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/anim.c b/source/blender/blenkernel/intern/anim.c index 547d3f7a738..6bbcecce2f7 100644 --- a/source/blender/blenkernel/intern/anim.c +++ b/source/blender/blenkernel/intern/anim.c @@ -436,6 +436,7 @@ void animviz_calc_motionpaths(Scene *scene, ListBase *targets) /* free curve path data * NOTE: frees the path itself! + * NOTE: this is increasingly innacurate with non-uniform BevPoint subdivisions [#24633] */ void free_path(Path *path) { @@ -444,7 +445,7 @@ void free_path(Path *path) } /* calculate a curve-deform path for a curve - * - only called from displist.c -> makeDispListCurveTypes + * - only called from displist.c -> do_makeDispListCurveTypes */ void calc_curvepath(Object *ob) { @@ -507,7 +508,7 @@ void calc_curvepath(Object *ob) /* the path verts in path->data */ /* now also with TILT value */ - pp= path->data = (PathPoint *)MEM_callocN(sizeof(PathPoint)*4*path->len, "pathdata"); // XXX - why *4? - in 2.4x each element was 4 and the size was 16, so better leave for now - Campbell + pp= path->data = (PathPoint *)MEM_callocN(sizeof(PathPoint)*path->len, "pathdata"); bevp= bevpfirst; bevpn= bevp+1; @@ -637,7 +638,6 @@ int where_on_path(Object *ob, float ctime, float *vec, float *dir, float *quat, vec[1]= data[0]*p0->vec[1] + data[1]*p1->vec[1] + data[2]*p2->vec[1] + data[3]*p3->vec[1] ; /* Y */ vec[2]= data[0]*p0->vec[2] + data[1]*p1->vec[2] + data[2]*p2->vec[2] + data[3]*p3->vec[2] ; /* Z */ vec[3]= data[0]*p0->vec[3] + data[1]*p1->vec[3] + data[2]*p2->vec[3] + data[3]*p3->vec[3] ; /* Tilt, should not be needed since we have quat still used */ - /* Need to verify the quat interpolation is correct - XXX */ if (quat) { float totfac, q1[4], q2[4]; |