[mythtv-users] PVR150: Automatic removing black bar(s) from the recording

Rod Smith mythtv at rodsbooks.com
Wed Mar 28 01:24:24 UTC 2007


On Tuesday 27 March 2007 19:23, Ma Begaj wrote:
> Hi,
>
> I have black bars around mpeg recordings. They are not shown if played
> in MythTV, but MPlayer shows these. I read the IVTV mailing list, and
> moste of the people say this:
...
> Is it possible to remove these lines during transcoding? I give my
> recordings from time to time to my cousin, and I would like to have
> the video without these black bars.

AFAIK, the tools that MythTV calls from its GUI won't do this; however, there 
are cropping options in at least some other tools. For instance, in mencoder 
you can use the "crop=xxx:yyy:xo:yo" option to crop to a size of xxx by yyy 
with an offset (from the original frame) of xo,yo. For instance:

mencoder -vf kerndeint,softskip,crop=720:360:0:60,scale=720:480,harddup -ofps 
30000/1001 -aspect 1.7777 -ovc lavc -lavcopts vcodec=mpeg2video:vrc_buf_siz
e=1835:vrc_maxrate=9600:vbitrate=3300000:keyint=18:turbo:trell:dc=10 -oac 
lavc -lavcopts acodec=ac3:abitrate=192 -of mpeg -o outfile.mpg infile.mpg

That should all be on one line -- it's a BIG command line! It crops a 720x480 
4:3 letterboxed recording (infile.mpg) to produce a 16:9 MPEG-2 version of 
the file (outfile.mpg), scaled to 720x480 (DVD-standard resolution). You 
could use something similar to remove narrow black bars on the left and 
right, but you'll need to experiment to figure out the right values for your 
system, or grab a still image to measure it in a graphics program. Note 
you'll also probably want to adjust various other options, such as the audio 
and video bitrates and, depending on your needs, the output file format. 
Unfortunately for those wanting to get a quick start, mencoder is a pretty 
complex program. I don't claim to have mastered it myself.

-- 
Rod Smith
http://www.rodsbooks.com


More information about the mythtv-users mailing list