Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Announcements and Chat > General Discussion

Reply
 
Thread Tools Search this Thread Display Modes
Old 16th February 2009, 17:32   #1  |  Link
jdb2
Registered User
 
jdb2's Avatar
 
Join Date: Dec 2008
Location: Klein/Spring, Texas, USA
Posts: 10
Any solution for Linux users who need to transcode mixed progressive/interlaced DVDs?

I run Kubuntu Linux as my default OS and use, almost exclusively, Avidemux for manipulating video, especially MPEG-2/DVD video. The problem is that ever since version 2.4.3 Avidemux' demuxer has been totally broken. That is, when dealing with a video stream with mixed interlaced and progressive sections and the resulting framerate changes, the demuxer produces horridly out of sync and choppy audio. For me at least, this means that Avidemux is useless for transcoding or otherwise manipulating DVD video as almost *all* ( or all the DVDs I own ) contain at least some mixture of interlaced and progressive frames.

Does anyone have any recommendations as to a workaround for Avidemux, or, failing that, another tool?

Thanks,

jdb2
jdb2 is offline   Reply With Quote
Old 16th February 2009, 23:24   #2  |  Link
jdb2
Registered User
 
jdb2's Avatar
 
Join Date: Dec 2008
Location: Klein/Spring, Texas, USA
Posts: 10
Quote:
Originally Posted by jdb2 View Post
....The problem is that ever since version 2.4.3 Avidemux' demuxer has been totally broken. That is, when dealing with a video stream with mixed interlaced and progressive sections and the resulting framerate changes, the demuxer produces horridly out of sync and choppy audio...
I take that back. I just downgraded to 2.4.1 and its demuxer is as crappy as that of 2.4.4 .

Maybe I just got lucky by hitting a long sequence of progressive frames at the beginning of whatever I was encoding.

jdb2
jdb2 is offline   Reply With Quote
Old 20th February 2009, 21:08   #3  |  Link
jdb2
Registered User
 
jdb2's Avatar
 
Join Date: Dec 2008
Location: Klein/Spring, Texas, USA
Posts: 10
Well, I bit the bullet and switched to Mencoder. The problem now is that given such a proliferation of command line options, which filters, and codec options should I use for my source material? For reference, the source MPEG-PS stream is from the Star Trek TNG DVD set, and is badly, badly, interlaced, as well as horribly noisy. I've been running mplayer with various video filters on the episode I want to encode in order to test their efficacy. The MPEG stream is a jumbled mix of telecined, and progressive frames. If I use the pullup filter interlacing is still present and very visible. If I use the filmdint filter with all the thresholds set to 1 almost all interlacing is gone but ugly deinterlacing artifacts are present, especially in highly detailed high motion scenes. The only thing that seems to work is '-vf pullup,hqdn3d=8:6:12,softskip,pp=ha:128:7/va/dr/l5/al/tn:1:1:1'.

My question is : Is there a better method than the above that does not rely on post-processing filters and if the answer to that is yes, what additional video filters should I insert into the chain and/or what parameters should I change for "optimal" quality?

jdb2

Last edited by jdb2; 20th February 2009 at 21:24.
jdb2 is offline   Reply With Quote
Old 21st February 2009, 01:23   #4  |  Link
jason50146
Registered User
 
Join Date: Jan 2008
Posts: 19
Try Handbrake GUI for Linux. There is a build for Ubuntu based distros at http://handbrake.fr/.

I used to use mencoder exclusively, but the Handbrake GUI is very good.

Use x264 as your codec. The nice thing about Handbrake's GUI is if you hover over the options, it tells you useful info about the options.
jason50146 is offline   Reply With Quote
Old 27th February 2009, 20:02   #5  |  Link
Ranguvar
Registered User
 
Ranguvar's Avatar
 
Join Date: Feb 2007
Location: ::1
Posts: 1,236
AviSynth under Wine is what I use.
Ranguvar is offline   Reply With Quote
Old 28th February 2009, 05:04   #6  |  Link
jason50146
Registered User
 
Join Date: Jan 2008
Posts: 19
Just for grins, I dug up my old Mencoder script. I have pulled a couple of lines out for a two pass encode. I think this should help you out. I believe I used these on some of the newer Dr Who DVDs that were mixed progressive and telecine. Results were fine. You'll need to change the frame rate to what is appropriate. For TV episodes, it is probably 30000/1001, for NTSC.

Just replace the variables with your true values.

Code:
/usr/bin/mencoder $TITLE1 -ofps 24000/1001 -vf pullup,softskip,crop=$CROP1 -aspect $AR1 -o /dev/null -oac copy -ovc 
x264 -x264encopts pass=1:turbo:bitrate=2048:frameref=5:subq=6:me=umh:partitions=all:bframes=15:b_pyramid:
weight_b:threads=auto:keyint=240:deblock:cabac

/usr/bin/mencoder $TITLE1 -ofps 24000/1001 -vf pullup,softskip,crop=$CROP1 -aspect $AR1 -of lavf -o 
/media/media_1/$TITLE1.mkv -oac copy -ovc x264 -x264encopts pass=2:bitrate=2048:frameref=5:subq=6:me=umh:partitions=all:
bframes=15:b_pyramid:weight_b:threads=auto:keyint=240:deblock:cabac
Also - if your ST:TNG episodes are really mixed progressive and interlaced, the Mencoder documentation says to deinterlace it. Are you sure they are mixed progressive and interlaced or are they mixed progressive and telecined? I don't think deinterlacing will deal with telecine artifacts.

Last edited by jason50146; 28th February 2009 at 05:13.
jason50146 is offline   Reply With Quote
Old 28th February 2009, 05:48   #7  |  Link
jdb2
Registered User
 
jdb2's Avatar
 
Join Date: Dec 2008
Location: Klein/Spring, Texas, USA
Posts: 10
Quote:
Originally Posted by jason50146 View Post
Try Handbrake GUI for Linux. There is a build for Ubuntu based distros at http://handbrake.fr/.

I used to use mencoder exclusively, but the Handbrake GUI is very good.

Use x264 as your codec. The nice thing about Handbrake's GUI is if you hover over the options, it tells you useful info about the options.
Thanks for the heads up. When I'm encoding with Avidemux or now, Mencoder, I always use x264 unless I'm authoring a DVD.

jdb2
jdb2 is offline   Reply With Quote
Old 28th February 2009, 05:49   #8  |  Link
jdb2
Registered User
 
jdb2's Avatar
 
Join Date: Dec 2008
Location: Klein/Spring, Texas, USA
Posts: 10
Quote:
Originally Posted by Ranguvar View Post
AviSynth under Wine is what I use.
I've considered that, but I'd rather use Wine as a last resort. Thanks for the tip though.

jdb2
jdb2 is offline   Reply With Quote
Old 28th February 2009, 06:05   #9  |  Link
jdb2
Registered User
 
jdb2's Avatar
 
Join Date: Dec 2008
Location: Klein/Spring, Texas, USA
Posts: 10
Quote:
Originally Posted by jason50146 View Post
Just for grins, I dug up my old Mencoder script. I have pulled a couple of lines out for a two pass encode. I think this should help you out. I believe I used these on some of the newer Dr Who DVDs that were mixed progressive and telecine. Results were fine. You'll need to change the frame rate to what is appropriate. For TV episodes, it is probably 30000/1001, for NTSC.

<snip>

Also - if your ST:TNG episodes are really mixed progressive and interlaced, the Mencoder documentation says to deinterlace it. Are you sure they are mixed progressive and interlaced or are they mixed progressive and telecined? I don't think deinterlacing will deal with telecine artifacts.
Thanks for the tip.


The ST:TNG material ( from the full 7-season set of DVDs ) is mixed telecine/progressive, but what's strange is that even when I reverse-telecine there is still some lingering interlacing visible occasionally, and some 10-20 second sequences that have frank, highly visible and ugly interlacing.

The only thing that seems to do the job are the filters in the following Mencoder command line :

Code:
mencoder dvd://2 -ovc x264 -x264encopts crf=18 -oac mp3lame -lameopts preset=insane -vf pullup,hqdn3d=8:6:12,softskip,pp=ha:128:7/va/dr/l5/al/tn:64:128:256  -o test4.avi -ofps 24000/1001
( the above was just a test : I'm using the average bitrate of the crf x264 encode with a 3-pass x264 encode )

As you can see I have to run a post-processing de-interlacer even after I've reversed telecined the source video.

jdb2
jdb2 is offline   Reply With Quote
Reply

Tags
avidemux, dvd, interlaced, linux, mpeg2

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 14:49.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.