I've been trying to implement a TV scheduling application using libvlc 1.1.7 on Windows 7. Currently, I'm using HDHomeRun ATSC network tuners. I create a UPD stream from the tune device to an instance of VLC and save the result in MPEG-PS format. After a few seconds of saving to the file, I create a VOD instance through libvlc VLM using the file as input. Clients then connect via RTSP to play on demand.
The technique works, with a few minor issues that I'm trying to resolve. First, sout to MPEG-PS file results in choppy playback, whether viewed through RTSP or playing the output file directly. Choppy playback occurs at the same location within the file, indicating some type of frame loss. To dump the UDP stream to file, I use the following options:
:sout=#file{mux=ps,dst=test.mpg} :ttl=1 :sout-keep :sout-all :no-sout-display
Second, VLC clients playing the VOD stream pause for ~1 second after 1-2 seconds of playback. This pause occurs only once directly after the RTSP location is opened. When creating the VOD instance via libvlc_vlm_add_vod(), I specify no options, just the input path and stream name. Clients use the following options to configure VLC for playback. Video window is set to child HWND. The same VLC instance is used for media file playback within the application, so some options do not specifically apply to this scenario:
-I dummy --plugin-path={VLCPath} --ignore-config --no-osd --ffmpeg-hw --network-caching=1000 --sub-autodetect-fuzzy=0 --no-sub-autodetect-file --input-timeshift-path=./Temp --video-filter=deinterlace --deinterlace=-1 --deinterlace-mode=linear
Are there any additional options that I can specify to alleviate these issues?