Stereo clips - Y U no pair??

DDDyson wrote on 6/23/2012, 8:54 AM
I recently tried shooting multiple takes with my dual (identical) VIO POV.HD cameras.

When pairing the clips for editing, the first Left/Right takes paired just fine, but all the consequent clips refused to pair.

They're identical otherwise, but for some reason the framerates differ more in the later takes.

Take 1: Left: 29,953 fps; Right: 29,952 fps (0,001 fps difference)
Take 2: Left: 29,949 fps; Right: 29,939 fps (0,010 fps difference)
Take 3: Left: 29,951 fps; Right: 29,943 fps (0,008 fps difference)
Take 4: Left: 29,943 fps; Right: 29,948 fps (0,005 fps difference)
Take 5: Left: 29,951 fps; Right: 29,950 fps (0,001 fps difference)
Take 6: Left: 29,949 fps; Right: 29,950 fps (0,001 fps difference)

Takes 1, 5 and 6 can be paired into a stereoscopic clip in Vegas Movie Studio. Takes 2, 3 and 4 refuse to pair, presumably because their framerates differ too much?

What's the least lossy way to sync one video clip's timecode to another? I can't "just" change the framerate, because that would change the length of the video and make the two clips go off sync. I guess I need to re-encodee the video but as losslessly as possible, only resampling frames here and there. Any recommendations?

(I'm going to contact VIO support about the inconsistent clock behavior of my cam unit #1)

Comments

Chienworks wrote on 6/23/2012, 9:09 AM
Adjust the lengths to match. Well, more accurately, adjust some determinable starting & ending points within the clips to match, since it's unlikely that all three cameras were started and stopped at exactly the same times. Disable resampling.
musicvid10 wrote on 6/23/2012, 9:15 AM
Haven't we all been down this path before?
http://www.sonycreativesoftware.com/forums/ShowMessage.asp?ForumID=12&MessageID=815019

Either use cameras that you can genlock and freerun T/C sync, --or-- match the media properties of one of the clips and disable resampling, --or-- do as Kelly suggested, if the error at the end is at least a full frame.

Reported frame rate in properties, and the average over hours of shooting are not the same. Unless there's something inherently wrong with your camera clocks, one skipped or duped frame in a 2 or 3 hour take would be about the norm. More than that from the same model camera might indicate sloppy QC.

I suspect this may be a tempest in a teacup.
DDDyson wrote on 6/23/2012, 9:33 AM
Thank you for your reply and tips.

There are only two cameras, and I start them with the same remote (at best it gives a 0,008 second difference between the cameras).

I right clicked on both clips (Left and Right) and set them to "Disable Resample". I time stretched the Right clip shorter to match the Left clip (in time, not frames). I attemted pairing them to a stereoscopic subclip. Still the same problem: the clips become a subclip, but the stereoscopic mode does not work (it only displays the left image), because the clips' framerates differ too much.

The clip settings have a "Playback rate" and "Undersample rate" values available, but they do not allow enough accuracy to make the rates match closely enough.
DDDyson wrote on 6/23/2012, 9:35 AM
musicvid; I don't have a problem with small sync errors, as long as the clips agree to pair. But now, with these new takes, the framerate difference between the two clips is so large that Vegas MS refuses to pair them properly. This is where it becomes a problem.

These were a set of very short test takes, only 1-2 minutes in length.

I guess I can alway re-encode the clips with AviSynth and "AssumeFPS" to force them to match. But that's a lossy and slow process.
musicvid10 wrote on 6/23/2012, 10:03 AM
I guess I don't understand what you mean with the word "pair." It's not a familiar part of my editing terminology.

But if you have "matched media settings" in your Project and Quantize to Frames is turned on before adding the clips to the timeline, they should line up just fine.

I don't see where the differences would be anything that would be considered "large."
A factor of 1 x 10^-5 fps shouldn't ever be noticed unless something else is amiss.
DDDyson wrote on 6/23/2012, 10:26 AM
>>> I guess I don't understand what you mean with the word "pair." It's not a familiar part of my editing terminology.

1) Shoot two clips with identical cameras, starting and stopping them at the same time
2) Set Vegas's Project settings' Stereoscopic 3D Mode to Enabled (any mode will do)
2) Place both clips on different tracks in the timeline so that they overlap and play at the same time (adjust their sync if needed)
3) Select both video clips, right click, select "Pair as stereoscopic 3D Subclip" from the right click menu
4) The clips will fuse into one subclip, whose stereoscopic streaming mode has been set to "Pair with next stream" (you can see this in the subclip's Properties -> Media tab).

This is how two video files can be combined/paired into one stereoscopic clip in Vegas.

The problem in a nutshell: For some reason, Vegas refuses to pair two video clips into a stereoscopic subclip, if their native framerates differ too much. And alas, my cameras appear to behave a bit inconsistently in this respect. Also, Vegas doesn't allow me to force the native framerate of a clip so I could make them match. I've tried changing to custom time code, but the Frame Rate option in the media settings stays greyed out.

The only thing I can presumably do, is to re-encode the videos and forcing their framerates to match. I'm going to try that now: I'll make an AVISynth script that takes the two videos, forces their framerates to Vegas NTSC native (29.970), Defishes them, and composites them side by side.
DDDyson wrote on 6/23/2012, 11:50 AM
It worked. As in, I crudely solved the problem with an AviSynth script:


LoadPlugin ("C:\Program Files (x86)\Video\AviSynth 2.5\plugins\QTSource.dll")
# QTSource is required for QuickTime videos

leftvideo = QTInput("video1_left.mov", quality = 100, mode=3, audio=1).AssumeFPS(29.970)
rightvideo = QTInput("video1_right.mov", quality=100, mode=3, audio=1).AssumeFPS(29.970)

# The framerate is crudely forced to match on both clips. In long clips this may become a problem.
# You can add a .trim(x, y) to either video to fix any small sync error, preview this in the MeGUI previewer

composite = StackHorizontal (leftvideo, rightvideo).ConvertToYV12()

# YV12 conversion is required for MeGUI x.264 re-encoding

return composite


Open this in MeGUI and re-encode to a new h.264 file with x.264.

The result is a 3840x1080 h.264 side-by-side video which Vegas Movie Studio can read (fortunately it only refuses to render higher than full HD videos). After importing this video to Vegas, the video clip's Media Properties can them be set to "stereoscopic 3D: side by side - full", and then the Sony Stereoscopic Adjust plugin works on the clip as usual. Handy! But the intermediate re-encoding step is a bit slow.

The above script is simplified, my processing pass also involved the DeFish, MSU DeBlock and MSU SmartSharpen plugins.
DDDyson wrote on 6/24/2012, 2:35 AM
>>> Vegas doesn't allow me to force the native framerate of a clip so I could make them match. I've tried changing to custom time code, but the Frame Rate option in the media settings stays greyed out.

I guess exporting to and importing as image sequence would allow me to use any frame rate I want... but that's beside the point, and creates an unwieldy intermediate.
DDDyson wrote on 7/24/2013, 10:51 AM
I now have two new MP4 video clips straight out of a pair of Sony HDR-AS15 action cameras (yes, Sony!), which have exactly the same framerate, and even happen to be almost perfectly in sync what comes to the time the cameras were started.

I arrange them to the tracks for pairing, right click to "Pair as a Stereoscopic Sub-clip" and.... nothing happens.

Why?

I've paired clips from these two cameras before just fine. In fact I did it just 10 minutes before this with another pair of test shoot clips. They paired just fine. What on earth could be the difference between these two and those two?

Interestingly, after I've deleted both clips from the timelines/tracks and press the 'lightning button' to clear all unused media from the project, one of the two clips stays and refuses to delete. The delete command does nothing! I have to start a new project to get it out. WTF?!

And.... this happened both in Vegas 11 and 12.
DDDyson wrote on 7/24/2013, 11:02 AM
I just shot another pair of clips and these refuse to pair, too. And just 20 minutes ago I had shot clips with these same two cameras, the same settings, and they paired just fine.

What's going on?
DDDyson wrote on 7/24/2013, 5:03 PM
>>> Interestingly, after I've deleted both clips from the timelines/tracks and press the 'lightning button' to clear all unused media from the project, one of the two clips stays and refuses to delete. The delete command does nothing! I have to start a new project to get it out.

More weirdness: I switched the media pool to display the media attributes, and when I try to pair the clips (and nothing happens), their Use Count increases by 2 every time I try it.

Even after deleting the clips from the tracks, their Use Count remains above 0, thus the "clear unused" button doesn't remove them. I have no idea why they can't be deleted from the project at all though.

It's a if the cameras suddenly started producing corrupted video files? They can be viewed normally etc, they just ... behave weirdly and cannot be paired.

Already tried resetting the cameras and formatting the memory cards, no avail. Even tried un/reinstalling Vegas, didn't help.