|
|||||||||
|
Thread Tools | Search this Thread |
March 20th, 2010, 11:34 AM | #1 |
Trustee
Join Date: Jul 2007
Location: Novato, CA
Posts: 1,774
|
Putting Videos on the timeline at correct TC
Is there a way to automate putting videos on a timeline at the correct TC? I'm looking for something similar to the way Vegas can import a Broadcast Wave File where it puts it at the TC of the starting point if the BWF.
Thanks, Garrett |
March 20th, 2010, 05:55 PM | #2 |
Sponsor: JET DV
Join Date: Dec 2001
Location: Southern Illinois
Posts: 7,953
|
Here's a script I wrote you should try out. Just take the script text, paste it into notepad, and save it as "MoveClipToTimestamp.cs". Then go to Tools - Scripting in Vegas and run it:
Code:
/** * This script will move events to start at their timecode. * * Written By: Edward Troxel * Modified: 07-04-2007 **/ using System; using System.IO; using System.Text; using System.Drawing; using System.Reflection; using System.Diagnostics; using System.Windows.Forms; using System.Runtime.InteropServices; using Sony.Vegas; public class EntryPoint { Vegas myVegas; public void FromVegas(Vegas vegas) { myVegas = vegas; foreach (Track track in myVegas.Project.Tracks) { foreach(TrackEvent evnt in track.Events) { Media media = vegas.Project.MediaPool.Find(evnt.ActiveTake.MediaPath); if (null == media) { MessageBox.Show("missing media"); throw new ArgumentException("missing media"); } evnt.Start = media.TimecodeIn; } } } }
__________________
Edward Troxel [SCVU] JETDV Scripts/Scripting Tutorials/Excalibur/Montage Magic/Newsletters |
March 21st, 2010, 11:56 AM | #3 |
Trustee
Join Date: Jul 2007
Location: Novato, CA
Posts: 1,774
|
Hi Ed,
Thanks for the script. It works great. I'm not sure if it's because I have so many clips but it take me running it a few time before all of the clips get moved to the correct TC. In the end it put all of them in the correct place though. Thanks again, Garrett |
March 21st, 2010, 12:50 PM | #4 |
Sponsor: JET DV
Join Date: Dec 2001
Location: Southern Illinois
Posts: 7,953
|
It may be that it's placing events after other events on the track so that the ones it's missing come BEFORE the new location of the event being processed. So I can see how that might happen. It could be written in a more complicated method to avoid that but it's probably just as easy to run it multiple times. Glad to hear it properly works for you (even if after running multiple times).
__________________
Edward Troxel [SCVU] JETDV Scripts/Scripting Tutorials/Excalibur/Montage Magic/Newsletters |
| ||||||
|
|