sometimes i make cutup films, for example: here, here, here & here
i'm currently working on a cutup involving 104 different clips, each of 3 seconds, to be cut in a variety of different length subclips,
so i make subclips with the clips using the trimmer,
i would like to cut a clip in a certain way, save the way it's cut (into let's say 10 different subclips)
then cut another clip in exactly the same way, as if i recorded a macro (to use an excel term) the 1st time i did it and used that macro for the other times i needed it,
Re: macro? by Edward Troxel on Jun 17, 2008 at 12:46:56 pm
You would need to use a script. Add a clip on the timeline, put regions where you wanted the sub-clips from, then create a script that would make one sub-clip for each region. Now replace the first clip with the next clip and run the script again to create sub-clips from each region. It would be much faster that way.
If you don't want to write your own script, the "Extract Good Clips" tool in Excalibur could actually do this for you. Not sure if there's any free scripts out there that does this particular task.
Re: macro? by Robbie Knight on Jun 18, 2008 at 2:11:20 am
thanks, i'll check that out, it would be most helpful, and would save me hours...
to be more exacting, i would also like to control the amount of fading on either side of each subclip, which means that regions wouldn't have exact edges, one region (representing 1 subclip) would bleed a little (by a frame or as much as 3 frames) into the next region,
Re: macro? by Robbie Knight on Jun 18, 2008 at 4:14:00 pm
thanks again, i've got excalibur (version 5.5 because i'm running vegas 7) & i'm in the 15 day period before i have to pay money, (which i can't afford to do just yet)...
for this current project i want to have different amounts of fade... but for many projects a set fade amount would be quite acceptable,
for what i do, partly because excalibur is a little pricey (for me) i'm more likely to find/create a few set scripts that deal with my obscure needs,
but then maybe i'll find i can't live without excalibur in the next 15 days and i'll find the money somewhere for it..?
anyway, it's going to take me awhile to learn how to create scripts, in the meantime, i need a script that puts 4 nodes into the velocity envelope bringing the velocity down to 99% for one second every 1 minute 24 seconds,
maybe it's a good little project to learn how to create scripts with, or maybe someone has a similar script that i could change up a little?
Re: macro? by Robbie Knight on Jun 22, 2008 at 6:17:24 pm
i am fortunate to have a brother who is a computer programmer...
he wrote a script exactly as you described, his 1st, so a tiny bit buggy... if i can attach it as a txt file to this post i will (it would need to be renamed as a .cs file to be used as a script)...
thanks again for your help x
- as i can't see where i can attach the .TXT file i'll just cut & paste it here:
public class EntryPoint
{
Vegas myVegas;
public void FromVegas(Vegas vegas) {
myVegas = vegas;
Re: macro? by Robbie Knight on Jun 22, 2008 at 9:35:30 pm
the same talented brother of mine gave me this version 2 of his script, helping me with naming and putting the subclips in a specific folder...
the trouble is, these scripts make something odd happen to vegas, occasionally the script won't finish and vegas will tell me an exception has occurred,
then i try and load the same file (saved after i had done a script or 2) and it won't load...
gets to 85%, 90%, or 94% and fails, "an exception has occurred" again...
so clearly there's something not right with my brothers scripts, (and it is his 1st time writing them), i know it's a lot to ask, but does anything strike anyone in the code?
thanks again x
/**
* You can use this script to convert Vegas regions to subclips. It will only work with saved projects.
*
* To use this script:
*
* 1) Create named Vegas regions.
* 2) Confirm no overlapped regions.
* 3) Vegas>tools>scripting>run script>Convert Regions To Subclips.cs
* 4) Check Project Media to see the subclips
*
* Revision Date: June 22, 2008.
**/
using System;
using System.IO;
using System.Text;
using System.Collections;
using System.Windows.Forms;
using System.Globalization;
using Sony.Vegas;
public class EntryPoint
{
Vegas myVegas;
public void FromVegas(Vegas vegas) {
myVegas = vegas;
String projName;
String projFile = myVegas.Project.FilePath;
if ((null == projFile) || (String.Empty == projFile)) {
Re: macro? by Jill Simpson on Nov 21, 2008 at 6:32:39 pm
I partially solved the error.
I installed the script version 2, and I got an error, all due to line 171 of the script, which is:
MessageBox.Show("Cannot find media bin "in order"");
The problem is the quotes around "in order". I replaced them with apostrophes:
MessageBox.Show("Cannot find media bin 'in order'");
Before that change, the error details showed:
C:Program Files (x86)SonyVegas Pro 8.0Script MenuJ - Convert Regions To Subclips.cs(171) : ) expected
(I think that means it got a close-parenthesis when it expected nothing.)
C:Program Files (x86)SonyVegas Pro 8.0Script MenuJ - Convert Regions To Subclips.cs(171) : Invalid expression term 'in'
C:Program Files (x86)SonyVegas Pro 8.0Script MenuJ - Convert Regions To Subclips.cs(171) : ; expected
C:Program Files (x86)SonyVegas Pro 8.0Script MenuJ - Convert Regions To Subclips.cs(171) : ; expected
C:Program Files (x86)SonyVegas Pro 8.0Script MenuJ - Convert Regions To Subclips.cs(171) : ; expected
C:Program Files (x86)SonyVegas Pro 8.0Script MenuJ - Convert Regions To Subclips.cs(171) : Invalid expression term ')'
After changing the quote marks to parentheses, I got a simpler error: "cannot find bin 'in order'".
I could change the script to match one of my bins, but I created a bin 'in order', and saved the project.
Then I ran the script and - oh darn - got the "Exception occurred" error, the details of which are: