[mythtv-users] pdatranscode script for watching shows on a PDA

Dave lists at netsalve.com
Sat Oct 14 20:24:56 UTC 2006


Hi Jeff,

I've tried your script from the command line and it works really well if I use 
the mencoder option, but it fails with mythtranscode. The error I get is:

2006-10-14 20:37:23.717 Using runtime prefix = /usr/local
2006-10-14 20:37:23.940 New DB connection, total: 1
2006-10-14 20:37:23.979 Enabled verbose msgs: important
2006-10-14 20:37:24.001 New DB connection, total: 2
2006-10-14 20:37:24.163 Using protocol version 31
[mpegts @ 0xb732f460]Parser not found for Codec Id: 94212 !
[mpegts @ 0xb732f460]Parser not found for Codec Id: 94212 !
0: start_time: 7784.389 duration: 175.349
1: start_time: 7784.333 duration: 175.344
2: start_time: 7784.341 duration: 175.349
3: start_time: 7784.333 duration: 175.405
4: start_time: 7784.333 duration: 175.405
5: start_time: 7784.333 duration: 175.405
6: start_time: 7784.333 duration: 175.405
stream: start_time: 86492.592 duration: 1948.945 bitrate=3371 kb/s
2006-10-14 20:37:24.716 Unknown video codec:
Transcoding failed for 1013_20061010002500.mpg with error 247


I have tried encoding files that have been recorded from DVB and also ones 
recorded from a pvr-250. I'm obviously missing a codec, but which one and 
where can I get it from, I am running 0.20-fixes from svn.

Regards,
Dave.
On Thursday 12 October 2006 01:47, Jeff volckaert wrote:
> I created a simple script to transcode recordings for a PDA (Dell Axim
> X51V in my case).  The files get stored in the directory pda under my
> video directory.  I just copy the files I want onto a memory card and
> watch them using TCPMP.  An hour long show comes out to 105M or so
> (that's alot of shows on a $40 2G card).  They play wonderfully on the
> PDA.
>
> I created a second user job to run after Zach's removecommercial
> script from the Wiki.  I check only those shows I want a copy of for
> the PDA.
>
> Here's the commands I used to create the user job:
>
> mysql> use mythconverg;
> mysql> UPDATE settings SET data='/usr/local/bin/pdatranscode %DIR%
> %FILE% "%TITLE%" %STARTTIME%' WHERE value='UserJob2';
> UPDATE settings SET data='PDA Transcode' WHERE value='UserJobDesc2';
> mysql> UPDATE settings SET data='1' WHERE value='JobAllowUserJob2';
>
> Then I create a script call "pdatranscode" and put it in
> "/usr/local/bin".  I have two methods to transcode here.  The first
> one uses mythtranscode's low quality transcoder (number 29 on my
> system).  I have low quality set to 320x240 with a 300k bitrate.  An
> hour long show came out to 136M.  The second method uses mencoder.
> Mencoder produced a show 105M in size.  Uncomment whichever you prefer
> to use.
>
> Here's the script:
> #!/bin/sh
> # pdatranscode
> #
> # created by Jeff Volckaert (inspired by Zach White)
> VIDEODIR=$1
> FILENAME=$2
> TITLE=$3
> # Remove non-alpha characters from TITLE
> TITLE=${TITLE//[^a-zA-Z0-9]/}
> STARTTIME=$4
>
> # Sanity checking, to make sure everything is in order.
> if [ -z "$VIDEODIR" -o -z "$FILENAME" ]; then
>         echo "Usage: $0 <VideoDirectory> <FileName> "<Title>" <Starttime>"
>         exit 5
> fi
> if [ ! -f $VIDEODIR/$FILENAME ]; then
>         echo "File does not exist: $VIDEODIR/$FILENAME"
>         exit 6
> fi
>
> # Transcode the file
> #mythtranscode -i  $VIDEODIR/$FILENAME -o
> $VIDEODIR/pda/$TITLE-$STARTTIME.avi -l -p 29
>
> mencoder -srate 32000 -vop scale=320:240 -oac mp3lame -lameopts
> preset=15:mode=3 -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=300 -sws 2
> -o $VIDEODIR/pda/$TITLE-$STARTTIME.avi $VIDEODIR/$FILENAME
> ERROR=$?
> if [ $ERROR -ne 0 ]; then
>         echo "Transcoding failed for ${FILENAME} with error $ERROR"
>         exit 3
> fi
> _______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users


More information about the mythtv-users mailing list