Page 1 of 1

Adding ActiveX in Visual Studio

Posted: 21 May 2009 22:45
by Mzhang
Hi All,

I am trying to add the VLC activeX to an unmanaged activeX program I wrote in visual studio 2005. I am managed to insert the activeX onto my dialogue box in resource view. Added a variable to it so I got a CWnd wrapper around the activeX.

When inserting the activeX, there are two plugins I can choose from (VIdeoLan AXVLCPlugin V11 and Plugin V2). To my understanding, Pluginv2 is the new version and Pluginv1 is old..

I first tried to add Plugin v1 , everything works fine.

Here is the question, I then tried to add Plugin v2, but I do not get all the exposed methods. I get access to some get/set methods but nothing like addTarget(), play(), pause() etc which I was able to access with Plugin v1.

So my question is if anyone can tell me why this happens. What is the difference between the two versions of VLC plugins?


Thanks very much,

Re: Adding ActiveX in Visual Studio

Posted: 21 May 2009 23:59
by Jean-Baptiste Kempf
API changed between Plugin1 and Plugin2, which is why you are missing things.

Re: Adding ActiveX in Visual Studio

Posted: 22 May 2009 16:17
by Mzhang
Thanks for the reply, so if I want to use the addTarget methods et al..I should be using version 1 then?

I have problem getting the length of the file and I am wondering if this was because that i used plugin1 instead of plugin2.

If I do
mPlugin->addTarget (....);
mPlugin->get_length();
I got an exception 'no active input', so I thought maybe I have to play the file in order to obtain its length.

but If I do
mPlugin->addTarget(....)
mPlugin->Play(....)
mPlugin->Stop(....)
mPlugin->get_length()
I got the length to be zero..what am I missing here..?