Fix T76440: Follow Track -> Constraint to F-Curve has no effect

Differential Revision: https://developer.blender.org/D7630
This commit is contained in:
Germano Cavalcante 2020-05-06 11:11:32 -03:00
parent 11d440f1a2
commit c57f65c088
Notes: blender-bot 2023-02-14 00:09:06 +01:00
Referenced by commit 3ffb52d114, Fix T77448: Camera Solver constraint can't be converted to f-curve
Referenced by issue #76440, Follow Track -> Constraint to F-Curve has no effect
1 changed files with 12 additions and 1 deletions

View File

@ -486,7 +486,18 @@ class CLIP_OT_constraint_to_fcurve(Operator):
return {'FINISHED'}
# Find start and end frames.
for track in clip.tracking.tracks:
if con.object:
tracking_object = clip.tracking.objects.get(con.object, None)
if not tracking_object:
self.report({'ERROR'}, "Motion Tracking object not found")
return {'CANCELLED'}
tracks = tracking_object.tracks
else:
tracks = clip.tracking.tracks
for track in tracks:
if sfra is None:
sfra = track.markers[0].frame
else: