Jump to content
Corwin

Create a Moving Crop Selection

Recommended Posts

I have a 1280x720 mp4 video with several people and I need to crop out one person into a 320x720 section that will fit on a mobile phone screen. I can easily do this with the Crop effect.

However about 3 minutes into this 20 minutes video I need to pan the crop selection to the left as the person walks left. I have to pan the crop selection a few times as the video plays as the person moves left and right.

Easily done except that when I do this VideoPad rebuilds the entire video to the new crop position, starting from the beginning, and I have to sit and wait as VideoPad says "Building Preview".

So what I need to do is move the crop position left or right as the video plays along. I can't find good documentation as to how to do this. There is an effect called Position that might help but there is little documentation.

Can anyone please help? Thanks!

Share this post


Link to post
Share on other sites

Hi

One way to speed up the process is to reduce the preview display resolution.There is then less work for VP to do whilst the cache is updated. here that usually allows he effect to be regenerated without the message appearing.The method you seem to be using is the normal way to follow a moving object..Framing the object at regular intervals along the timeline and creating keyframes at each point.

However if that still results in hangups and delays particularly if it's a video consisting of one complete clip then you could split the clip into shorter sections. Note the place where you need to make your cropped area move and just before this point split your timeline. Keep the same crop parameters at the start of the next section. and then use keyframes to make the cropped area move. Split the timeline again where the movement ceases and proceed in the same fashion to the end of the video.(or wherever.) It's a time consuming way but feasible.

Here's another possibility if you want to keep the visible rectangle stationary without any cropping. You could add a blank black image to the overlay track and then create a mask of the right size in the centre. Click the  Mask Inside  box and then make it 0% opaque.This creates what is, in effect an open rectangle in the centre of a black frame through which the main video on Track 1 will be visible. Now apply the Position effect to the main video on  Track 1 to keep the person of interest within the rectangle. This will require keyframe creation. Note that the rectangle should fit around the subject without showing the edge of the underlying video at the maximum extent of the left to right movement. This also applies to the cropping method..

Nat

 

Share this post


Link to post
Share on other sites

In the CROP effects box be sure that the animation editor is visible at the right.  Click the white-dot icon in toolbar if it is not.

Make your crop.  Move the scrubber (red line) to the spot just prior to where the movement occurs.  Click the small green + in the toolbar to create the initial keyframe.

Play the video.  When the subject moves, click the crosshatch in the preview display and drag the cropped window to the new position.  This will create another keyframe.  The dimensions of the cropped window can also be adjusted, if necessary by either dragging the preview window handles or adjusting sliders.

Continue this process as needed.  The plot that results - visible as an animation graph - will track your subject.  For a detailed explanation of how the animation editor works,  click the ? at the top-right of the Videopad window and click the Animating Video Effects item.

Share this post


Link to post
Share on other sites
5 hours ago, Nationalsolo said:

Hi

One way to speed up the process is to reduce the preview display resolution.There is then less work for VP to do whilst the cache is updated. here that usually allows he effect to be regenerated without the message appearing.The method you seem to be using is the normal way to follow a moving object..Framing the object at regular intervals along the timeline and creating keyframes at each point.

I reduced the preview display resolution, thanks, it's speeded up things!

4 hours ago, borate said:

Play the video.  When the subject moves, click the crosshatch in the preview display and drag the cropped window to the new position.  This will create another keyframe.  The dimensions of the cropped window can also be adjusted, if necessary by either dragging the preview window handles or adjusting sliders.

I'm not sure what I'm doing wrong, borate. I created my cropped area, created a keyframe, then started playing the video. When I got to just before the subject moved I stopped the video, created another keyframe, played the video & let the subject move, stopped the video, then left-clicked on the cropped area to create the arrowed-crosshatch and dragged the cropped window to a new position. But when I restated the video from the beginning it seems like the cropped area is following my subject? Is there a hidden setting or something?

Also, can you please explain the animation editor graph & how I can use it?

The other PITA is sometimes when I click Pause || from the Clip Preview up top, sometimes it pauses & sometimes it stops and video goes back to time index 00:00. That is really annoying!

Thank you to both of you, I really appreciate you taking the time to help me!

Share this post


Link to post
Share on other sites

In the animation window there are dots (keyframes), which can be dragged to change timing or positioning.  The lines, each one denoting a different parameter, are a graphic plot of the action.

The closer the keyframes are to one another for a particular parameter, the quicker the action between them. Many interim keyframes may have to be created depending upon how fast the subject moves, if the action is to be tracked precisely.

Begin by cropping your subject.  Just prior to the first movement, click the small green + to create the first keyframe.

Play until the subject moves.  Pause.

Drag the crosshatch in the middle of the cropped area to the subject's new position.  Another keyframe is created.

Play some more, until the subject moves to another position that should be the focus.  Pause.

Drag the crosshatch to the new location, and so forth.

Keyframes dots can be deleted.  Right-click on them and choices will appear.

Dots can be dragged.  The result of doing that will be apparent in the preview window, or in the timing between effect locations while playing.  Takes practice.

Share this post


Link to post
Share on other sites

Excellent borate. Thanks for the info, I ran a few experiments and I'm getting the hang of cropping now!

My last problem is with saving the video. After cropping, I now have a 1280x720 video with a moving  310x640 crop area moving from left to right. How do I save only the cropped area?

Edit: Hmmm, maybe Zoom is the function I want to use instead of Crop.

Edited by Corwin
Added Zoom

Share this post


Link to post
Share on other sites

Hi

As it stands when you export your result it will show the whole frame with just the cropped are moving around it. If you want to see JUST the cropped area filling the screen you can use the ZOOM effect. Zoom works in a similar way to CROP  in that you can outline an area and move it about with keyframes. The difference is that the "frame" will be enlarged to fill the screen..a subtle difference to the fitting the screen.. The caveat here is that the zoom frame should be Restrained to the AR as that of your video or it will be stretched or squashed. To avoid this the area used must be the same orientation and shape (Aspect ratio) as the the full screen; usually 16:9. There are controls to set this. For your particular requirement this might not do but worth looking at.

Pan and Zoom will retain the AR automatically. If you don't change the size of the rectangle throughout the clip (You just drag it) it will just pan at full screen. The downside is there are only no keyframes....just start frame and end frame. I would avoid this option as I don't think it is currently working correctly.

Nat

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×