[mythtv-users] Crop in Transcode?
Rod Smith
mythtv at rodsbooks.com
Wed Apr 25 18:38:41 UTC 2007
On Wednesday 25 April 2007 13:04, Robert Current wrote:
> I'm guessing the answer is no, but...
>
> Is there anyway to do a crop in transcode?
AFAIK, there's no way to do this from the MythTV GUI; however, it is possible
when using command-line tools. Here's one that I use (note that this is one
big long line; it's split for e-mail):
mencoder -vf kerndeint,softskip,crop=720:360:0:60,scale=720:480,hard
dup -ofps 30000/1001 -aspect 1.7777 -ovc lavc -lavcopts
vcodec=mpeg2video:vrc_bu
f_size=1835:vrc_maxrate=9600:vbitrate=${vbitrate}:keyint=18:turbo:trell:dc=10:au
toaspect=1 -oac lavc -lavcopts acodec=ac3:abitrate=192 -of mpeg
-o ${dest} ${src}
Replace ${vbitrate} with your target bitrate (such as 4771000 for 2GB/hr),
${dest} with the destination filename, and ${src} with the source filename.
This specific example takes a 720x480 letterbox recording, crops it to
720x360, and then expands that out to MPEG-2 720x480 widescreen. I use it in
preparing to burn to DVD, but you could use it to keep recordings for
long-term on-disc storage. You'd need to tweak it if you record in other
resolutions or want to store the final result in something other than 720x480
resolution. You could also alter the output format from MPEG-2 to something
else, too, or make other changes -- mencoder has LOTS of options.
> This would probably save me a lot of disk space, and probably lighten
> up the load on the system during playback of non-HD recordings of OTA
> HD broadcast.
I doubt if the black letterboxing bars consume all THAT much disk space; they
are just static solid black areas, which shouldn't take a lot of data to
encode. You'll also necessarily lose some quality whenever you transcode. If
disk space is an issue, I'd recommend either examining your recording options
or buying more disk space.
If you're recording in HD but playing back in SD, transcoding ahead of time
will certainly lighten the load on playback, but of course the transcoding
itself will of course consume a lot of CPU time. You probably won't want to
crop when doing this unless you want to crop off the right and left sides of
HD transmissions of 4:3 material.
--
Rod Smith
http://www.rodsbooks.com
More information about the mythtv-users
mailing list