Page 1 of 1

VLC ActiveX control in VC

Posted: 12 Jan 2007 09:31
by angelo0802
when i want to use VLC ActiveX control in VC, i found a problem.
the function "addTarget" of VLC cannot be used.
how to solve the problem.

thank you!

same problem

Posted: 15 Jan 2007 16:59
by lemangw
Hello?

Did you solve your problem? I have the same one, and I do not have any answer for now...

Thanks

G.

i solve it , but error happens

Posted: 16 Jan 2007 02:04
by angelo0802
the sample code:

VARIANT v;
long pos = 0;
LPSAFEARRAY pSA = SafeArrayCreateVector(VT_VARIANT, 0, 1);
_variant_t var(_bstr_t("deinterlace-mode=mode"));
SafeArrayPutElement(pSA, &pos, (void FAR *)&var);
v.parray = pSA;
v.vt = VT_ARRAY;

m_VLCControl.put_Visible(TRUE);
m_VLCControl.addTarget("http://people.videolan.org/~dionoea/vlc-plugin- demo/streams/sw_3M.mov", v, CVlcplugin1::VLCPlayListInsertAndGo,
10);
m_VLCControl.put_Position(0);
m_VLCControl.put_Time(0);
m_VLCControl.put_AutoPlay(TRUE);
m_VLCControl.play();


but when program exits, the error happen:"Debug Assertion Failed"
the assertion is:

CCmdTarget::~CCmdTarget()
{
#ifndef _AFX_NO_OLE_SUPPORT
if (m_xDispatch.m_vtbl != 0)
((COleDispatchImpl*)&m_xDispatch)->Disconnect();
ASSERT(m_dwRef <= 1);
#endif
m_pModuleState = NULL;
}

I dont know how to solve it

Posted: 16 Jan 2007 10:42
by lemangw
OK, thank you very much!! It works well, thanks for your quick support!

G.