HiDef Video Playback - A Solution

Posted by JD 09/14/2009 at 10:10

Some of us have older media playback devices, not PCs, but dedicated devices like a MediaGate or MASSCOOL. These devices let you playback TV and Movie files in the popular VOB, MPEG, Divx, xvid formats. Some allow network playback too from SMB shared folders. Nice.

They have issues playing HiDef content. Here’s a solution to that problem.

As more and more content is provided in HD, HiDef, format, we’re all discovering that our players won’t play the files. While AVI may contain hidef content, it usually doesn’t. HiDef is any resolution above DVD (720×544). Common HiDef resolutions are 1280 × 720 and YYYY x 1080. So even if your playback device has HD capable outputs (Component or HDMI), the video will not be displayed on your TV.

Often, a converted file from MKV or x264 formats into AVI will appear to play, but just audio will be heard, no video will be seen.

What you can do?

There is no way to display HiDef content using these devices. They simply do not have video processing capable, but you can “transcode” or “down sample” the video content to 720xSomething and watch it. Here’s a few scripts to accomplish this for UNIX people with mencoder/mplayer:
Here’s a nice, 2-pass, scaling script. It retains the aspect ratio of the source material.


#!/bin/sh
#

  1. This is for really simple XVID conversion, use
    #
    SCALE=“,scale=720:-3”
    XVIDENCOPTS=“bitrate=1400:max_key_interval=250:trellis:max_bframes=1:vhq=3”

for filename in “$@”; do

IN=$filename LOGFILE=“$IN.log” NICE_LEVEL=“+15”
  1. Pass 1
    nice /usr/bin/mencoder “$IN” -oac mp3lame -lameopts preset=128 -ovc xvid \
    -vf lavcdeint${SCALE} -noodml -forceidx -ffourcc XVID \
    -xvidencopts ${XVIDENCOPTS}:pass=1 -passlogfile “$LOGFILE” \
    -of avi -o “${IN}-xvid.avi”
  2. Pass 2
    nice /usr/bin/mencoder “$IN” -oac mp3lame -lameopts preset=128 -ovc xvid \
    -vf lavcdeint${SCALE} -noodml -forceidx -ffourcc XVID \
    -xvidencopts ${XVIDENCOPTS}:pass=2 -passlogfile “$LOGFILE” \
    -of avi -o “${IN}-xvid.avi”
    rm -f “$LOGFILE
    done

If you want a much easier and quicker conversion and don’t really care about having good quality, try this script:

#!/bin/sh
#
# This is for really simple XVID conversion, use
#
SCALE=",scale=720:-3"
XVIDENCOPTS="fixed_quant=4:max_key_interval=250:trellis:max_bframes=1:vhq=3"

for filename in "$@"; do

   IN="$filename"
      
   NICE_LEVEL="+15"

   nice /usr/bin/mencoder "$IN" -oac mp3lame -lameopts preset=128 -ovc xvid \
                -vf lavcdeint${SCALE} -noodml -forceidx -ffourcc XVID \
                -xvidencopts ${XVIDENCOPTS} -of avi -o "${IN}-xvid.avi"
done

I like XVID because it is open source and my MediaGate MG35 plays the resulting files. You may prefer DX50 or some other format.

Trackbacks

Use the following link to trackback from your own site:
https://blog.jdpfu.com/trackbacks?article_id=326