I'm using VideoLan.Interop, a .Net libvlc 0.9.x wrapper compiled on Visual Studio 2005 (VLC 1.0.5)
Now I'm creating an application with VB.net and VideoLan.Interop.dll
Everything works fine: I can open an rtsp stream ("rtsp://196.0.0.19:8082/test2.sdp") which carries an audio stream and a video stream.
Is it possible to display the video on a first form.panel and simultaneously have the audio visualization (say spectrum or scope) on a second form.panel without making 2 connections to rtsp source?
(I've succeded in doing this only with two different connections to my rtsp source).
This is my VB.net source code:
Code: Select all
Private Vlc As VideoLan.VideoLanClient
Private VlcPlayer As VideoLan.VlcMediaPlayer
Private VlcPlayerAudio As VideoLan.VlcMediaPlayer
Public Sub New()
InitializeComponent()
Vlc = New VideoLanClient()
VlcPlayer = Vlc.NewMediaPlayer(VideoPanel.Handle)
' in my form I have also an AudioPanel
'//VlcPlayer.TimeChanged += new EventHandler<TimeChangedEventArgs>(VlcPlayer_TimeChanged);
AddHandler VlcPlayer.PositionChanged, AddressOf VlcPlayer_PositionChanged
AddHandler VlcPlayer.StateChanged, AddressOf VlcPlayer_StateChanged
End Sub
Private Sub Play()
Dim desc As VlcMedia = Vlc.NewMedia("rtsp://196.0.0.19:8082/test2.sdp")
VlcPlayer.Load(desc)
desc.Dispose()
VlcPlayer.Play()
End Sub
Is it possible?
Thank you very much for any hint.