thegoodhen / AprilTools

A marker-based camera tracker for Blender based around the AprilTags Library by University of Michigan
GNU General Public License v3.0
253 stars 29 forks source link

Import addon only creating one keyframe #20

Open vmxeo opened 5 years ago

vmxeo commented 5 years ago

After creating the track.txt and importing into Blender, there's only one single keyframe at frame 3.

Peeking into the track.txt, it seems the first value, which normally shows the track number, is 3 for each line. e.g.

3, -0.1799,-0.2406,-0.7874,-0.0587,0.0438,0.7369 3, -0.0465,-0.1112,-0.7868,-0.0440,0.0304,0.7635 3, -0.0547,-0.1188,-0.7915,-0.0415,0.0326,0.7671 3, -0.0625,-0.1284,-0.8005,-0.0424,0.0392,0.7712 3, -0.0698,-0.1437,-0.8055,-0.0436,0.0432,0.7733

(Had some other issues with the released version so I downloaded the zip)

benno5020 commented 4 years ago

Could it be that your image sequence has a digit at the end of its filename? I haven't actually looked at the code enough, but I experienced a similar problem where the camera would only move once at the start. Turns out I had named my sequence 'test1', resulting in files named 'test1001.png' etc. The script seems to have interpreted this as frame 1001 instead of frame 1.

To fix this you can either redo the entire process with another filename or you can rename all your image files as well as the first line and the frame numbers inside your track.txt.

Hope this helps!