Windows c# AXVLC.VLCPlugin2Class

This forum is about all development around libVLC.
completenewbee
New Cone
New Cone
Posts: 2
Joined: 28 Jan 2016 22:56

Windows c# AXVLC.VLCPlugin2Class

Postby completenewbee » 28 Jan 2016 23:31

I have been fighting all day to try to get VLC to cooperate with my c# form. Basically what I am needing to do is load multiple VLC targets and display them side by side inside my form. Although VLC is being created within my process id, the moment I start playing the target, a new DC window outside my form in it's own window is opened with the caption "VLC (Direct3d output)". I finally submitted to using FindWindow to locate this newly created window and SetParent to force it into a panel within my form but that to me seems cumbersome and I cannot help but think I am doing something wrong here. To me, the current method I am using is nothing short of a hack because the moment I hit play, I have to spawn a thread to wait for this window to be created, grab the handle then use SetParent to force this into my form.

Code: Select all

AXVLC.VLCPlugin2Class vlc = new AXVLC.VLCPlugin2Class(); vlc.addTarget("rtsp://1.1.1.1:554/Streaming/Channels/1", null, AXVLC.VLCPlaylistMode.VLCPlayListInsert, 0); vlc.play();
I even attempted to set the vlc.Visible to "false" before calling play to see if I could convince the window to be created behind the scenes so I do not get the flicker between window creation and the time my thread realizes it and can SetParent. It appears even if visible is set to false, the moment you play, the window becomes visible and loaded at full screen.

I also attempted to use the "gui" control from the toolbox but get a message that it fails to create component. I have also tried installing 2.2.2 to see if maybe it was something wrong with the 2.2.1 version but still failed.

Can anyone point me in the right direction.

completenewbee
New Cone
New Cone
Posts: 2
Joined: 28 Jan 2016 22:56

Re: Windows c# AXVLC.VLCPlugin2Class

Postby completenewbee » 31 Jan 2016 04:17

I have given up on trying to use the control and instead opted to use libvlc.dll. This seems to give me all the functionality I need for this application.

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: Windows c# AXVLC.VLCPlugin2Class

Postby Jean-Baptiste Kempf » 28 Jun 2016 09:42

I have given up on trying to use the control and instead opted to use libvlc.dll. This seems to give me all the functionality I need for this application.
Yes, it's better.
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.


Return to “Development around libVLC”

Who is online

Users browsing this forum: No registered users and 25 guests