Page 1 of 1

Can i use one Active X to Record & Play Video

Posted: 22 May 2006 07:53
by Bob.Huang
I use VLC 0.8.5 and use it in VB to get a streaming video from tcp://192.168.6.23:8888

Here is my Sample

Connect & Play
Private Sub Connect_Command_Click()

Dim opt() As Variant

Dim connect_string As String

connect_string = Connect_Text.Text

opt() = Array("--sout=#transcode{vcodec=mp4v,vb=1024,scale=1,acodec=mp3,ab=128,channels=2},--sout=#deinterlace-mode {discard,blend,mean,bob,linear,x}")

VLCPlugin1.addTarget connect_string, opt(), 4 + 8, -666

End Sub
Record
Private Sub Record_Command_Click()

Dim opt() As Variant

Dim connect_string As String

connect_string = Connect_Text.Text

opt() = Array(":sout=#transcode{vcodec=mp4v,vb=1024,scale=1,acodec=mp3,ab=128,channels=2}:duplicate{dst=std{access=file,mux=ps,url=C:\1.mpg}},--sout=#deinterlace-mode {discard,blend,mean,bob,linear,x}")

VLCPlugin1.addTarget connect_string, opt(), 4 + 8, -666


End Sub
Here is my question

When i press "Record" button to record video, the Active X will not to display video.

How can i solve this program with only one Active X?

Posted: 22 May 2006 15:56
by xtophe
add a dst=display{} in your duplicate

Posted: 23 May 2006 03:07
by Bob.Huang
Thank you.

It works now. :D