-
-
Notifications
You must be signed in to change notification settings - Fork 416
_VlcControl.VclMediaPlayer.Stop() Freeze when stopping a disconnected dshow device #625
Comments
Please send a complete code on github. I didn't understand the "Same in VLC" part. Does it freeze the same way? If so, there's nothing I can do about that. |
No what i mean is in the desktop vlc the "real" vlc, it freezes as well, but that is to be expected the video source has been turned off. But when i try to switch the media it is playing it can switch it.
|
Another idea : can you try to trigger the Stop before the FormClose event, from another thread than the main thread? |
I tried it, and with this code it freezes straight away:
Whereas when I try this, the interface stays working, but it freezes after a while and on exit.
|
Hello,
I have been building a camera into an application.
It works really well and have had almost no issues, but i ran into one the other day.
When I am playing a dshow stream in the player if the camera gets disconnected the screen freezes. Same in desktop VLC. However in the desktop VLC i can change to a different video playback. When i try to stop the player in my app it hangs. I have left it running for an hour during lunch bit it stays hanging.
This happens however i try to do it. be it VlcControl.stop() or Vlc.VlcMediaPlayer.Stop(). Same thing happens if i try to dispose the player, or the form it is running in.
I have tried using invoke as suggested in https://github.com/ZeBobo5/Vlc.DotNet/wiki/Vlc.DotNet-freezes-(don't-call-Vlc.DotNet-from-a-Vlc.DotNet-callback):
Invoke(new Action(() => { _vlcControl.VlcMediaPlayer.Stop(); _vlcControl.Dispose(); Dispose(); }));
also tried it with the ThreadPool method. I know i dont have to call stop because dispose calls it to, but the freeze happens there so it narrows it down slightly.
I saw somewhere else that
_vlcControlVideoStream.SetMedia(@"C:\Downloads\Rotating_earth_(large).gif");
might work, but it doesnt.If anyone has an idea, any help would be appreciated!
David
The text was updated successfully, but these errors were encountered: