hi,

like many I've recently built an htpc, mine is based on gentoo and myth tv. amongst my targets for this project is the ability to stick in one of my dvd's hit a button and have this transcoded as a 1 click operation.

linux-2.6.16-suspend2-r5

*  media-video/transcode
     Latest version available: 1.0.2-r2

So far I've been getting good results with PAL discs, the option I've used is -M3 ... however I had to make a small change to the way this works before the a/v sync seems correct. I essentially changed the value being used to a -ve and this seemed to correct the a/v sync problems I was getting.

to clarify ... the change made is listed below ...I know I could have posted my values on the command line but that seemed at odds with using the automatic feature offered by M3 and M4 ??? (or perhaps I was just being lazy :))

// AV sync correction: case (3)
 //
 // fully PTS based sync modes requested

 if(vob->demuxer==3 || vob->demuxer==4) av_fine=1;

 //set parameter

 if(av_fine) {
     //few demuxer modes allow auto-probing of AV shift parameter

// 2 lines below were originally +ve ... changed to -ve

     if( !(*flag & TC_PROBE_NO_AVSHIFT)) vob->sync=-D_arg;
     if( !(*flag & TC_PROBE_NO_AV_FINE)) vob->sync_ms=-D_arg_ms;
 }

 if(verbose & TC_INFO)
printf("[%s] is using the following AV correction -D %d --av_fine_ms %d \n",
            "transcode", vob->sync, vob->sync_ms);


I've tested this with a few dvd's with different 1st PTS offset and they seem to work fine,

---------------------------------------------------------------------------------------------------------------------------------------

With NTSC discs however I'm getting problems. I'm trying to encode Wonderfalls eppisode 1, 1st of all I tried the -M4 option with AC3 direct stream copy and this was all over the place, the sync started wrong and got worse. Then I tried the PSU mode as follows....

tccat -i '/dvdrip/wonderfalls-eppi1/vob/001' | tcdemux -W > nav_log

transcode -x vob -V -i '/dvdrip/wonderfalls-eppi1/vob/001' -M 2 -R 1 -y xvid --psu_mode --nav_seek nav_log -A -N 0x2000 -a 0 -o '/dvdrip/wonderfalls-eppi1/avi/001/wonder.avi' --no_split

transcode -x vob -V -i '/dvdrip/wonderfalls-eppi1/vob/001' -M 2 -R 2 -y xvid --psu_mode --nav_seek nav_log -A -N 0x2000 -a 0 -o '/dvdrip/wonderfalls-eppi1/avi/001/wonder.avi' --no_split

The resultant avi did seem to stay in sync (if there was any drift it was almost unnoticeable) but there was an obvious fixed sync error of at least -120ms (or there abouts). I'm not sure where this would have come from so I thought I'd see if I could get some help! I'm also trying some other variations to see if any work any better, at the moment I'm trying to encode the audio to mp3 with the -M4 option.

I'm using xine to replay the avi files and for comparison of the original dvd and the ripped vob streams (which seem fine to me). I've also tried to encode with dvd::rip which seems to have the same drifting sync issues, although I couldnt get it's PSU option to run.

If anyone could help on this it would be greatly appreciated and no doubt make me very happy :)).

P.S. Wonderfalls is a great show ... I'd recomend it to anyone who hasnt seen it!


Reply via email to