I have filmed a play on a stage.
I have cropped to the size I wanted, but I'm wondering if I can go beyond namely.
The stage is fixed, the shoot was done without a support so that there is some movement
Is it possible(if yes, explanation please ) to tell ffmpeg that the cropping rectangle will move according to the a fixed point given on the first frame?
ffmpeg -i 2012-0331Praha.mp4 -acodec copy -vf crop=720:540:430:40:640:300 -sameq -vcodec mpeg4 output.avi
Sets the cropping rectangle top left corner at (430,40) the dimensions of the cropping rectangle being 720x540
The fixed point is located at 640:300 and this is the reference point of focus (like a giroscope).
+ Reply to Thread
Results 1 to 6 of 6
If I'm understanding you correctly: No, because ffmpeg doesn't have a motion tracker
The "fixed point" is no longer "fixed" between subsequent frames due to the movement of the camera (ie. it's no longer at x,y , it might be at x+11, y+12)
If you stabilize the shot, then crop , then it would be possible. You can use stabilization software e.g. deshaker , prodad mercalli, after effects
What's your goal? To stabilize? Or to pan within the frame, like a Ken Burns?
Last edited by budwzr; 11th May 2012 at 11:06.
If I'm understanding you correctly...The "fixed point" is no longer "fixed"
Yes you understood correctly, eventhough I was not clear.
Goal: Rather "restabilize" vertically.
Source is 1280x 720 (HD Ready)
If I crop so:
ffmpeg -i 2012-0331Praha.mp4 -acodec copy -vf crop=720:540:430:40 -sameq -vcodec mpeg4 output.avi
I would say that on the first half of the video one sees lot of ceiling on top of heads of dancers, while on 2nd half one sees lot of stage and virtually no ceiling.
The stage being fixed, I wanted to take one point on it as the tracking point
Seeing complex coding like
# trembling effect
I thought that there might exist an option
>Or to pan within the frame, like a Ken Burns?
How do you achieve that with ffmpeg?
Last edited by feelart; 11th May 2012 at 11:41.
Your tracking point can be visualized and assigned manually if you throw a grid overlay. Your pixel resolution would be the points. Like on a travel map when you find a destination in one plane and a departure in the other plane, then triangulate the mileage.
Panning within a frame? An example would be to shoot in 1080, then make a 720 crop rectangle. Then you can stabilize with no edge loss or jello effect too.
Last edited by budwzr; 11th May 2012 at 12:11.