Get and set the parameters of proDAD Mercalli v4 Plugin

peter-r wrote on 6/18/2017, 6:29 AM

Dear Vegas Pro scripters,

I'm working on a C# script (Extension) that adds proDAD Mercalli v4 Plugin on selected Clips.

What I want to do, is to read (get) the Parameters inside the Mercalli v4 Plugin modify some of them and write (set) the Parameters back.

Then I would like to reanalyse.

Can someone help me or give me an hint.

Thank you very much!

Peter

PS: I know there exists a similar Extension from an user, but I want to create an another Extension by myself, because the existing Extension does not fit my Needs. Also the Extension is compiled so that I cannot get how it works.

 

 using (UndoBlock undo = new UndoBlock("Mercalli add"))

{

   PlugInNode plugIn = vegas.VideoFX.GetChildByName("proDAD Mercalli v4");

   Effect effect = new Effect(plugIn);

   clip.Effects.Add(effect);

   // Get and set Parameters of Plugin

   // Reanalyse

}

 

Comments

peter-r wrote on 6/26/2017, 12:16 PM

Dear Vegas Pro scripters,

I think there is no trivial Vegas solution!?

But I am working on a solution that fits my Needs:

1. I search for the handle of the Analyse-Button

      GetProcessesByName("vegas140")

      GetTextBoxText(hWnd) == "Analyse"

2. Then I get the handle to the parent of this Analyse-Button

      GetParent(handle_from_the_Analyse_Button)

3. Now I can get all handles of the Mercalli-Plugin and get/set all values.

      GetTextBoxText(hWnd)

4. Then I Analyse/reanalyse.

      SendMessage(Analyse_hwnd, BN_CLICKED, IntPtr.Zero, IntPtr.Zero);

 

Best regards

Peter