Streaming VLC content to MVPMC
(MVPMC is a project to provide an open source OS for the Hauppage MVP set top box devices.)
Note: This guide assumes you have mvpmc 0.3.2 or are running one of the older mvpmc daily builds containing my VLC improvements.
This guide covers watching stored video content only (pretty much what I use my MVP for) and not streaming audio/other uses of VLC.
File paths
First, you’ll need to set up your NFS or SAMBA shares containing your content. The file path on the mvpmc device must be EXACTLY the same as the path seen by the host machine running VLC.
So if I kept my movies in /storage/movies on the machine running VLC for example and exported /storage/movies via NFS, then I’d have this in my mvpmc dongle config:
mkdir /storage
mkdir /storage/movies
mount -t nfs -o nolock,rsize=4096,nfsvers=3 nfsserver:/storage/movies /storage/movies
(where “nfsserver” is the hostname of your NFS machine)
MVPMC Command Line Options
In your dongle config again, you should specify the IP address of the VLC server. You can also choose a streaming movie quality setting at the command line. The options are:
- dvd - DVD Quality - 720x480/576 4912KB/s
- svcd - SVCD Quality - 480x480/576 2788KB/s
- vcd - VCD Quality - 352x240/288 1152KB/s
- none - Manual
MVPMC will auto-detect whether you have a PAL or NTSC TV and will set the screen height accordingly. It will use the MVPMC TV aspect ratio setting to figure out the aspect of your TV and make sure the transcoded movie fits correctly. It will also apply synchronisation and deinterlacing options, as well as overlaying subtitles onto any transcoded stream. Using these presets is the recommended way of using VLC with MVPMC.
If you chose the manual option, MVPMC will send a very basic transcode request, not specifying anything but the video/audio codecs necessary for mvpmc, and bitrates of 2048 for video and 192 for audio (overridable at the command line on VLC). Any scaling will be done by the mvpmc hardware MPEG2 decoder instead of on the VLC server.
Choose an option depending on the CPU available in your VLC machine - I have an Athlon 2400XP+ machine as my VLC server and VLC roughly uses the following resources during transcoding streams:
- DVD Quality - 80-85% CPU
- SVCD Quality - 45-55% CPU
- VCD Quality - 15-20% CPU
Note also that you can override the default bitrates for any of these presets at the command line (for example, if you have a really fast machine, use DVD quality and set the video bitrate to 8192 for highest possible quality).
One final note - the mvpmc hardware will always scale the video to fill the screen, these options are controlling the quality of what you see on screen (lower quality is softer and more likely to pixelate on darker areas of the image).
Sample command line for dongle.bin.config:
mvpmc -a 4:3 --vlc 192.168.84.2 --vlc-vopts dvd --vlc-vb 6240 &
All of these options are available in the mvpmc settings menu under “VLC Streaming”
Running VLC
Install and run VLC on your machine. You’ll ideally need 0.8.6 for full support (there’s a bug in stream stats which means the OSD timeclock won’t work in mvpmc with VLC 0.8.5 and below). If it hasn’t been released yet, you can pick up a binary for it on your platform from the Nightly VLC Builds page.
0.8.5 will work for now, but you won’t get an accurate timecode when pausing or seeking (although these functions will still work correctly) and you won’t be able to do +30/-10 second commercial skipping.
Start up your VLC with the following command line:
vlc -I Telnet
Setting VLC Options Manually
If for some reason, the mvpmc transcoding presets aren’t working out for you (CPU usage is too much, or you’d like to handle other options), then you can put VLC streaming into manual mode by either passing “–vlc-vopts none” on the command line, or choosing manual from the settings menu under VLC Streaming->Video Transcoding
You can then pass additional VLC options when you start your VLC up by adding them to your vlc -I Telnet startup line.
Here are some useful ones:
- –sout-transcode-fps 25.0000 (fps of stream, set to 29.97 or 23.976 for NTSC)
- –sout-transcode-canvas-width/height [pixels] (set transcoding canvas to fill screen)
- –sout-transcode-width/height [pixels] (scale movie to width/height)
- –sout-ffmpeg-keyint=3 (sets number of keyframes to regular frames ratio - stops transcoding artifacts and strange garbage in scene changes)
- –sout-transcode-deinterlace (deinterlace the movie before transcoding - stops sound sync wandering)
- –sout-transcode-audio-sync (synchronise on audio track)
- –sout-transcode-soverlay (overlay subtitle files onto transcoded stream)