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 > Capturing and Editing Video > Avisynth Usage

Reply
 
Thread Tools Search this Thread Display Modes
Old 13th November 2005, 13:46   #1  |  Link
mantis2k
Registered User
 
Join Date: Nov 2002
Posts: 151
What's the best way to de-interlace this film?

Download clip...

I tried this code, but unfortunately the video comes out really jerky...
Code:
loadplugin("c:\program files\AviSynth 2.5\plugins\dgdecode.dll")
loadplugin("c:\program files\AviSynth 2.5\plugins\leakkerneldeint.dll")
MPEG2Source("dvd.d2v",upConv=1)
leakkerneldeint(order=1,threshold=7)
Please can you analyse the clip and tell me the best way of de-interlacing it? Any help would be much appreciated!
mantis2k is offline   Reply With Quote
Old 13th November 2005, 14:19   #2  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,174
If you do a separatefields you'll see that it isn't 50i, so a simple deinterlace isn't enough; it's been through the wringer a few times in fact. There seem to be two separate rounds of interlacing, one done before resizing; likely the conversion to pal was done very quickly and badly.

It's not going to be pretty restoring the original framerate and quality to that video.
foxyshadis is offline   Reply With Quote
Old 13th November 2005, 14:31   #3  |  Link
mantis2k
Registered User
 
Join Date: Nov 2002
Posts: 151
Please excuse my ignorance, as I'm not very technical when it comes to this sort of thing; are you saying it's not genuine PAL framerate?

PowerDVD seems to play it back fine with it's built-in de-interlacer, but what's the best way of de-interlacing the video with AviSynth?
mantis2k is offline   Reply With Quote
Old 13th November 2005, 14:56   #4  |  Link
scharfis_brain
brainless
 
scharfis_brain's Avatar
 
Join Date: Mar 2003
Location: Germany
Posts: 3,605
this film has been converted badly from NTSC to PAL. it is called a fliedblend.
restore24 wasn't that happy with this footage. it produced jerkyness, too.

you could try walking the tough way with manual deblending.

all you need to do is finding the correct offsets manually. this requires you scrolling through the whole movie checking for remained blends.

Code:
mpeg2source("D:\FORUM\mantis2k\LostSwordship.d2v") #,cpu=4)
crop(8,88,-8,-84,align=true)
tdeint(mode=1)
changefps(23.976*10)
selectevery(10,7)
bicubicresize(width,336)
addborders(0,72,0,72)
changing the offset is done via the 2nd number of selectevery.
valuable numbers are form 0 to 9.
7 actually works pretty well on that sample you provided.

if the blend-pattern changes during the movie, you need to trim it into several sections, apply another offset to it an then re join them.

the script above is built to reencode to NTSC-FILM DVD (23.976 fps progressive, 704x480, Letterboxed)
__________________
Don't forget the 'c'!

Don't PM me for technical support, please.
scharfis_brain is offline   Reply With Quote
Old 13th November 2005, 18:15   #5  |  Link
Guest
Guest
 
Join Date: Jan 2002
Posts: 21,924
Forum rule 12: do not ask what's best.
Guest is offline   Reply With Quote
Old 13th November 2005, 19:07   #6  |  Link
mantis2k
Registered User
 
Join Date: Nov 2002
Posts: 151
Many thanks, scharfis_brain; I'm running your method now! I hope the new framerate/screensize is compatible with DVD, and the audio won't go out of sync?

neuron2, what method would you use to de-interlace this horrid DVD of mine?
mantis2k is offline   Reply With Quote
Old 13th November 2005, 19:47   #7  |  Link
Didée
Registered User
 
Join Date: Apr 2002
Location: Germany
Posts: 5,390
Quote:
Originally Posted by scharfis_brain
restore24 wasn't that happy with this footage. it produced jerkyness, too.
Yeah, I'm sure poor old R24 doesn't like this too much. Shiny new R24 does like this, at some 15fps -- no need for manual intervention.

(Pity I can't work on all tools at the same time, isn't it.)

Scripts as they have been used are here. I give no support yet for this version of R24. It is WIP.
__________________
- We´re at the beginning of the end of mankind´s childhood -

My little flickr gallery. (Yes indeed, I do have hobbies other than digital video!)
Didée is offline   Reply With Quote
Old 13th November 2005, 19:51   #8  |  Link
mantis2k
Registered User
 
Join Date: Nov 2002
Posts: 151
scharfis_brain's method seems to have less ghosting than PowerDVD, so that's a result! Have I correctly modified the last 2 lines for 16:9?
Code:
bicubicresize(width,456)
addborders(0,12,0,12)
mantis2k is offline   Reply With Quote
Old 13th November 2005, 20:26   #9  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,174
I'm curious, but is this a general method for removing fieldblends, or more a last ditch for when restore24 doesn't work? I have a video [sample] in NTSC that was possibly originally PAL, although I counted blends and seemed to end up closer to FILM (~1/4 of fields were blends). I wonder if I should try tweaking restore24.

(I tried to find an offset resulting in the least blends as well, but they seem to jump around too much.)

Edit: Helps if I have the link in there.

Last edited by foxyshadis; 13th November 2005 at 21:09.
foxyshadis is offline   Reply With Quote
Old 13th November 2005, 21:34   #10  |  Link
mantis2k
Registered User
 
Join Date: Nov 2002
Posts: 151
Didée, thanks for posting the scripts and clip, but unfortunately I can't get it to work.

Any ideas what the problem might be?
mantis2k is offline   Reply With Quote
Old 13th November 2005, 21:56   #11  |  Link
scharfis_brain
brainless
 
scharfis_brain's Avatar
 
Join Date: Mar 2003
Location: Germany
Posts: 3,605
@mantis2k:

better use this for 16:9 anamorphic:

bicubicresize(width,448)
addborders(0,16,0,16)

16:9-height = 4:3-height * 1.33333

and please ensure, that the pattern ist constant all over the whole movie.
(scroll through it in VDub and look for blended, dropped, or repeated frames)

@didee: Oh, new stuff.
__________________
Don't forget the 'c'!

Don't PM me for technical support, please.
scharfis_brain is offline   Reply With Quote
Old 13th November 2005, 22:14   #12  |  Link
mantis2k
Registered User
 
Join Date: Nov 2002
Posts: 151
scharfis_brain, according to my authoring software, 23.976 is an invalid framerate for DVD; can the video be de-blended, but kept in 25fps?
Should I use DGPulldown? BTW, besides progressive-only, is there any disadvantage to using DGPulldown? I'm wondering why not everyone uses this software for PAL to NTSC standards conversion?
mantis2k is offline   Reply With Quote
Old 13th November 2005, 22:18   #13  |  Link
mantis2k
Registered User
 
Join Date: Nov 2002
Posts: 151
OMG, DGPulldown just messed it up!!! It looks jerky again with repeated frames!
mantis2k is offline   Reply With Quote
Old 13th November 2005, 22:39   #14  |  Link
scharfis_brain
brainless
 
scharfis_brain's Avatar
 
Join Date: Mar 2003
Location: Germany
Posts: 3,605
23.976 is 'invalid' for PAL DVD.
I suggest you to make a NTSC-DVD.

if you want to make a PAL DVD anyways, you have to leave out every resizing, or

use

bicubicresize(width,538)
addborders(0,20,0,18)

to make an anamorphic PAL MPEG with 23.976 out of it.
afterwards apply DGPulldown with the setting
23.976 -> 25.000

this will insert two field duplications when playing it back on TV.
you will notice a stutter, of course.

the only alternative is to speed it up from 23.976 to 25.000 fps. but this will force you to speed up the audio, too.
__________________
Don't forget the 'c'!

Don't PM me for technical support, please.
scharfis_brain is offline   Reply With Quote
Old 13th November 2005, 22:58   #15  |  Link
mantis2k
Registered User
 
Join Date: Nov 2002
Posts: 151
Quote:
the only alternative is to speed it up from 23.976 to 25.000 fps. but this will force you to speed up the audio, too.
DGPulldown is not acceptable for 23.976 -> 25.000, so please can you tell me a solution for speeding up the video and audio to 25fps? Also, how would you recommend I make an NTSC DVD; this would need to be changed to 29.97!!
mantis2k is offline   Reply With Quote
Old 13th November 2005, 23:11   #16  |  Link
scharfis_brain
brainless
 
scharfis_brain's Avatar
 
Join Date: Mar 2003
Location: Germany
Posts: 3,605
Nope. NTSC-FILM DVD is encoded at 23.976 fps with 3:2 Pulldownflags.
(this will have exactly the SAME judder as the PAL-DVD with its blending before deblending!)
During playback on your PC the Pulldown flags will be ignored, so the motion is fluent 23.976 fps.
There is no need to blow it up to 29.97 fps interlaced.
__________________
Don't forget the 'c'!

Don't PM me for technical support, please.
scharfis_brain is offline   Reply With Quote
Old 13th November 2005, 23:27   #17  |  Link
Didée
Registered User
 
Join Date: Apr 2002
Location: Germany
Posts: 5,390
@ mantis2k

you need the prerelease of Removegrain:
http://home.arcor.de/kassandro/Remov...emoveGrain.rar


@ scharfi

Not so hot new. It's exactly the version I PM'ed you about, several weeks ago ...
__________________
- We´re at the beginning of the end of mankind´s childhood -

My little flickr gallery. (Yes indeed, I do have hobbies other than digital video!)
Didée is offline   Reply With Quote
Old 13th November 2005, 23:32   #18  |  Link
mantis2k
Registered User
 
Join Date: Nov 2002
Posts: 151
scharfis_brain, my authoring software won't accept this framerate to make an NTSC-FILM DVD, so do I have to set the pulldown flags or something? I think I worked out how to speed up the video and audio to 25fps using TMPGEnc, but I'm still testing it now. However, DGPulldown only produces stutter when the output is played back on Winamp or Windows Media Player, so I need to test this too, on a standalone player; I may not need to speed up the streams afterall!
mantis2k is offline   Reply With Quote
Old 13th November 2005, 23:50   #19  |  Link
scharfis_brain
brainless
 
scharfis_brain's Avatar
 
Join Date: Mar 2003
Location: Germany
Posts: 3,605
Do NOT playback a pure m2v (elementary stream)file.
A program stream (mpg) is needed for smooth playback.
a m2v file without puldown flags will run smmoth, but a m2v file with pulldown flags will stutter. Mux it y=with your audio and you will see that it runs smoothly.

your authoring program will accept the DGpulldowned file.
(pulldown flags for NTSC-FILM are mandatory!)

If it doesn't accept in though, the authoring program is crap.

btw.: in your final encode you should stick to Tdeint.
(i hope the bob() you used in your sample isn't the thing you'll use for the DVD...)
__________________
Don't forget the 'c'!

Don't PM me for technical support, please.
scharfis_brain is offline   Reply With Quote
Old 13th November 2005, 23:51   #20  |  Link
mantis2k
Registered User
 
Join Date: Nov 2002
Posts: 151
Didee, my MPEG encoder is outputting the restore24 file @ 696x392! How do I resize this to 16:9 anamorphic for both PAL and NTSC?
mantis2k is offline   Reply With Quote
Reply

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 21:04.


Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2017, vBulletin Solutions, Inc.