6.3. Examples
Prev | Chapter 6. TV input | Next

## 6.3. Examples

Dummy output, to AAlib :)

    mplayer -tv driver=dummy:width=640:height=480 -vo aa tv://

Input from standard V4L:

    mplayer -tv driver=v4l:width=640:height=480:outfmt=i420 -vc rawi420 -vo xv tv://

A more sophisticated example. This makes MEncoder capture the full PAL image, crop the margins, and deinterlace the picture using a linear blend algorithm. Audio is compressed with a constant bitrate of 64kbps, using LAME codec. This setup is suitable for capturing movies.

    mencoder -tv driver=v4l:width=768:height=576 -oac mp3lame -lameopts cbr:br=64\
        -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=900 \
        -vf crop=720:544:24:16,pp=lb -o output.avi tv://

This will additionally rescale the image to 384x288 and compresses the video with the bitrate of 350kbps in high quality mode. The vqmax option looses the quantizer and allows the video compressor to actually reach so low bitrate even at the expense of the quality. This can be used for capturing long TV series, where the video quality isn't so important.

    mencoder -tv driver=v4l:width=768:height=576 \
        -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=350:vhq:vqmax=31:keyint=300 \
        -oac mp3lame -lameopts cbr:br=48 -sws 1 -o output.avi\
        -vf crop=720:540:24:18,pp=lb,scale=384:288 tv://

It's also possible to specify smaller image dimensions in the `-tv` option and omit the software scaling but this approach uses the maximum available information and is a little more resistant to noise. The bt8x8 chips can do the pixel averaging only in the horizontal direction due to a hardware limitation.

Prev | Up | Next
6.2. Usage tips | Home | Chapter 7. Teletext