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 Development

Reply
 
Thread Tools Search this Thread Display Modes
Old 7th February 2021, 15:20   #1  |  Link
Ceppo
Registered User
 
Join Date: Feb 2016
Location: Nonsense land
Posts: 339
TelecineBob + FieldDeBlend.avsi

Here I am sharing my first plugin after starting the C++ journey. I'm kind of scared to share it since I'm not a C++ expert but whatever.

TelecineBob + FieldDeBlend.avsi

Let's say you have your telecined source and it has field blend, a lot of post telecine cuts, post telecine animations, and so on. So you jump to the conclusion the is far better to just use QTGMC(). However, there are a few downsides to that:
1) 90% of the frame are either progressive or have a clean match.
2) QTGMC is slow.
3) On DVD is not as good as with HD content.

So I decided to make a field matching bob to solve this problem. The way to make a field matching bob is to make a c/p match on even fields and a c/n match on odd fields. Think about it, you will see that it makes sense. Then we have fields with no match due to various reasons. The filter handles those as well.

Default TelecineBob() does just the field matching with no deinterlacing. For deinterlacing the filter makes a distinction between heavily combed frames and lesser combed frames. Here some examples.

My source has a post telecine animation, a transition, that makes the frames as if they were purely interlaced. In this case, a good solution would be to use QTGMC() since it does a better job than a simple spatial check. My filter allows limiting QTGMC usage to just these cases.

TelecineBob()
TelecineBob(thr2=3,edeint2=QTGMC())

To detect it as heavily combed we perform the average combed value then we make the combed check on the average. This allows limiting QTGMC usage to just when is truly needed saving speed.

Now we have lesser combed cases, that are handled differently. Here an example (the source is crappy so is not the best but whatever).

TelecineBob(thr2=3,edeint2=QTGMC())
TelecineBob(thr=6,edeint=nnedi3(-2),thr2=3,edeint2=QTGMC())

You might notice that I used nnedi3 for this job. The reason is that to use QTGMC this way would be like using it with the lossless parameter and I don't like that since the pixels might be a bit off due to the motion compensation. It's a matter of taste I guess.

Now if you are willing to filter only heavily combed frames, you could take advantage of TBob output to filter field blending. I made a script that takes advantage of that and removes field blending as long there is a clean match. Here an example.

TelecineBob(thr2=3,edeint2=QTGMC())
FieldDeBlend(thr=1,bob=TelecineBob(thr=6,bt=32,bs=8,edeint=nnedi3(-2)))

More in the ReadMe file!
Let me know if you like my solution or if something is not clear!

Here a link to a short clip to play with.

Last edited by Ceppo; 7th February 2021 at 16:44.
Ceppo is offline   Reply With Quote
Old 7th February 2021, 17:55   #2  |  Link
real.finder
Registered User
 
Join Date: Jan 2012
Location: Mesopotamia
Posts: 2,587
I will give it a try

off-topic but your sample source is just upscaled BD, there were 480i BD for it IIRC and it was very clean, if there are no other than upscaled one then there are this method https://forum.doom9.org/showthread.php?p=1823545
__________________
See My Avisynth Stuff
real.finder is offline   Reply With Quote
Old 7th February 2021, 20:18   #3  |  Link
Ceppo
Registered User
 
Join Date: Feb 2016
Location: Nonsense land
Posts: 339
Thank you, is nice to know.
Ceppo 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 09:13.


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