Postby es@work » 03 Aug 2015 20:34
I'm new to libVLC, so hopefully since you have some experience in this area you might be wiling to share some insight. As stated in my previous post I'm trying to start/stop video recording on the fly.
At this time, I can display video either from another vlc player steaming a file from my PC to the network via rtsp or by directly playing the file on my PC. I'm able to record either one in almost all attempts but once in a while something refuses to cooperate. When I connect to network cameras, steaming via rtsp, I can see the video but cannot record it. If I'm lucky, the recording file is created but only 1k is written to it and the display goes blank until I stop recording.
The args I use to create the instance are:
"-I",
"dummy",
"--ignore-config",
"--sout-display"
when playing a file I add the following to the instance creation:
"--vout-filter=deinterlace",
"--deinterlace-mode=blend"
when connecting to an IP c amera I add to the instance creation:
"--rtsp-tcp"
The args for playing a file and connecting to an IP camera are mutually exclusive.
When I want to record on the fly I use the libvlc_media_add_option call to add the following sout after creating a new instance:
":sout=#duplicate{dst=display,dst=std{access=file,mux=mp4,dst=C:\Test_Panel.mp4}}"
When I start/stop recording I kill the media player and start a new one after grabbing the time at stop request and using that time and appropriate args when creating the new player. The time setting has no effect on video cameras that I can tell but that's ok.
My point about Doxygen is the lack of a reference as to how current it is. One could assume that it's current, however I did read somewhere that keeping it updated was a task that was done when time was available. I may have read an older comment or something in another vlc related blog which may not be relevant anymore, but it did raise a question in my mind as to how current it is.
Thanks in advance for any advice or pointers you provide.