Forum Replies Created

Page 3 of 3
  • Hi,

    i just tested the script, but i got over 440 missed frames. What really mazes is that the script worked with you so why doesnt it with me? Is there anything wrong with my Vegas or something? Maybe my settings? Im totally puzzled but i still appreciate your time and help.

  • Hi,

    yes, now i get a popup that says no image to analyze at 00:00:10.13 and it always stops around that same time.Im using the exact same video i sent you so i dont understand.

  • Im doing it on the video i sent you. This time i did everything exactly the same as you do in your video but still, it stops at about 10 seconds.What OS are you using? Im on Windows 7.

  • Ah, okay, now it started to add the events but it stopped halfway for some reason. I got the error below:

    System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. —> System.NullReferenceException: Object reference not set to an instance of an object.
    at ParseBoxChanges.ParseVideo(List`1 selected)
    at ParseBoxChanges..ctor(Vegas vegas)
    at EntryPoint.FromVegas(Vegas vegas)
    — End of inner exception stack trace —
    at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
    at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
    at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
    at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
    at Sony.Vegas.ScriptHost.ScriptManager.Run(Assembly asm, String className, String methodName)
    at Sony.Vegas.ScriptHost.CodeDomScriptManager.Run()
    at Sony.Vegas.ScriptHost.RunScript(Boolean fCompileOnly)

  • Oh, great. I wanted to ask you also, the files i sent were just a sample, the actual file is much more complex. It has many more tracks and its always quite different in structure so i would like to discuss the script you sent me in order to be able to modify it myself accordingly. These lines below:

    boxes = new List();
    boxes.Add((VideoEvent)vegas.Project.Tracks[0].Events[0]);
    boxes.Add((VideoEvent)vegas.Project.Tracks[1].Events[0]);
    boxes.Add((VideoEvent)vegas.Project.Tracks[2].Events[0]);
    boxes.Add((VideoEvent)vegas.Project.Tracks[3].Events[0]);

    represent the tracks that are supposed to contain the png events? If thats the case Tracks[1] represents track number 1? So it means i have to place the events on that track or it wont work? Because in my actual veg file the tracks that contain those events are 8 through 11 so i thought should modify the script like below:

    boxes = new List();
    boxes.Add((VideoEvent)vegas.Project.Tracks[8].Events[0]);
    boxes.Add((VideoEvent)vegas.Project.Tracks[9].Events[0]);
    boxes.Add((VideoEvent)vegas.Project.Tracks[10].Events[0]);
    boxes.Add((VideoEvent)vegas.Project.Tracks[11].Events[0]);

    but i tried it and didnt work. How should i proceed?

    Editing: i just tested the script exactly as you sent it to me on the files i sent you but i get this error after processing a few frames:

    System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. —> System.NullReferenceException: Object reference not set to an instance of an object.
    at ParseBoxChanges.ParseVideo(List`1 selected)
    at ParseBoxChanges..ctor(Vegas vegas)
    at EntryPoint.FromVegas(Vegas vegas)
    — End of inner exception stack trace —
    at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
    at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
    at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
    at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
    at Sony.Vegas.ScriptHost.ScriptManager.Run(Assembly asm, String className, String methodName)
    at Sony.Vegas.ScriptHost.CodeDomScriptManager.Run()
    at Sony.Vegas.ScriptHost.RunScript(Boolean fCompileOnly)

    Maybe i have the wrong version of Vegas? I have Vegas Pro 11.

    Thank you.

  • Hi,

    i really appreciate the time you dedicated to do this for me. I have a few questions though. Its my first time with a script so im not really sure about how it works upon execution. Does it just adds the events to the tracks? Or it also starts rendering?

    Also, about point 1), I have to add at least one frame of each png images onto the tracks, right? Does it matter where in the time line i add them to? If so, wont they appear there for a split of a second on the rendered video?

    Tank you so much!

  • Thanks for your help. This a rar file with all the data.

    https://f1.creativecow.net/7090/test-for-vegas-script

  • Yes, they are transparent pngs and they are not animated. Doing it manually is not a problem when its a single video. However it becomes tedious when you have to do it on a 30 minute video or more every week. This is why im desperately looking for a way to automatize the process.

  • Thanks for you answer. Some guy posted this on other forum and it might help:

    under “class VideoColor” , Public Properties it’s possible to get or set , the R,G,B components as a float or byte value

    Code:

    Syntax:
    class VideoColor

    Public Properties: Summary:
    Single Red Get or set the red component of the color as a float value.
    Single Green Get or set the green component of the color as a float value.
    Single Blue Get or set the blue component of the color as a float value.
    Single Alpha Get or set the alpha component of the color as a float value.
    Byte R Get or set the red component of the color as a byte value.
    Byte G Get or set the green component of the color as a byte value.
    Byte B Get or set the blue component of the color as a byte value.
    Byte A Get or set the alpha component of the color as a byte value.

Page 3 of 3

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy