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 > Video Encoding > MPEG-4 AVC / H.264
Register FAQ Calendar Today's Posts Search

Reply
 
Thread Tools Search this Thread Display Modes
Old 17th March 2010, 21:01   #1  |  Link
bloodem
Registered User
 
Join Date: Jun 2005
Location: Galati, Romania
Posts: 98
Help with AVCHD deinterlacing

Hello guys! I just bought a new video camera (a Canon HF200) and once again I started playing with deinterlacing methods.
I'm recording at 1920 x 1080 / 50i / 24 Mbps

A few years ago I was using a great deinterlacing plugin which - I though at that time - was giving the best results. It was called MVBOB. It did a great job with deinterlacing and kept the motion smooth (while doubling framerate). Now I'm using MeGUI + AviSynth + x264 but unfortunately mvbob doesn't work anymore.
Is there some other, new plugin I could use to achieve the same "mvbob" results (good quality deinterlacing + smooth video)? I haven't done this in a while now, so I'm not up-to-date with the latest tools... Thanks!
bloodem is offline   Reply With Quote
Old 17th March 2010, 21:39   #2  |  Link
bloodem
Registered User
 
Join Date: Jun 2005
Location: Galati, Romania
Posts: 98
And after some research... the winner is.... TempGaussMC
Although... jeez I need an upgrade. My poor Core2Duo E7200 @ 3.8 GHz is really struggling to reach 1 FPS...
bloodem is offline   Reply With Quote
Old 17th March 2010, 21:47   #3  |  Link
Atak_Snajpera
RipBot264 author
 
Atak_Snajpera's Avatar
 
Join Date: May 2006
Location: Poland
Posts: 7,815
You better check plain Yadif. Quality is good but it is alot faster!
Atak_Snajpera is offline   Reply With Quote
Old 17th March 2010, 21:47   #4  |  Link
Guest
Guest
 
Join Date: Jan 2002
Posts: 21,901
I like sbdeint() also.
Guest is offline   Reply With Quote
Old 18th March 2010, 00:05   #5  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by Atak_Snajpera View Post
You better check plain Yadif. Quality is good but it is alot faster!
Yadif is my favorite "real time" deinterlacer, but it doesn't give "archiving quality" in my opinion.

I prefer YadifMod+NNEDI2 for encoding purpose. Can't compete with TempGaussMC in certain situations, but it's a bit faster and works very well for me most of the time

Well, give it a try and decide yourself...
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊
LoRd_MuldeR is offline   Reply With Quote
Old 18th March 2010, 06:26   #6  |  Link
bloodem
Registered User
 
Join Date: Jun 2005
Location: Galati, Romania
Posts: 98
Thanks guys! After I get home from work I'll give them a try. I'll let you know about my final decision.
bloodem is offline   Reply With Quote
Old 18th March 2010, 09:06   #7  |  Link
bloodem
Registered User
 
Join Date: Jun 2005
Location: Galati, Romania
Posts: 98
I tried a simple script for sbdeint:

DirectShowSource("C:\test.mts")
sbdeint()

The result is pretty strange, I get a lot of stuttering during playback. Am I missing some special parameters for AVCHD?
bloodem is offline   Reply With Quote
Old 18th March 2010, 09:58   #8  |  Link
nm
Registered User
 
Join Date: Mar 2005
Location: Finland
Posts: 2,641
Maybe the field order is wrong since you're using DirectShowSource. Try changing the order with AssumeTFF() or AssumeBFF() before sbdeint.
nm is offline   Reply With Quote
Old 18th March 2010, 10:01   #9  |  Link
bloodem
Registered User
 
Join Date: Jun 2005
Location: Galati, Romania
Posts: 98
Yep. I was about to write that. Indeed. AsumeTFF() was the solution...
bloodem is offline   Reply With Quote
Old 18th March 2010, 13:37   #10  |  Link
bloodem
Registered User
 
Join Date: Jun 2005
Location: Galati, Romania
Posts: 98
Well, after trying all of them, I have to say that YadifMod+NNEDI2 works best for me, it has the greatest visual BANG relative to encoding time. Thank you LoRd_MuldeR for the suggestion and a big thanks to all of you for the quick answers. On my machine, enconding a 10 minute 24Mbps AVCHD to x264 and at the same time deinterlacing it with YadifMod+NNEDI2 takes about 4-5 hours (processing at about 2 FPS) which is OK by me.

Here is the script I use for deinterlacing AVCHD content, just in case anyone else is interested:

DirectShowSource("F:\test.mts")
AssumeTFF()
interp=nnedi2(field=3)
yadifmod(order=1, field=-1, mode=1, edeint=interp)

If someone has more suggestions, I'm all ears!


Edit: I came across another issue. After encoding, the video has more brightness. I think it has something to do with the color space. The original AVCHD is in YUY2 and after encoding it's YV12. Is there some way to keep the original brightness?

Last edited by bloodem; 18th March 2010 at 14:32.
bloodem is offline   Reply With Quote
Old 18th March 2010, 15:18   #11  |  Link
poisondeathray
Registered User
 
Join Date: Sep 2007
Posts: 5,377
Quote:
Originally Posted by bloodem View Post
Edit: I came across another issue. After encoding, the video has more brightness. I think it has something to do with the color space. The original AVCHD is in YUY2 and after encoding it's YV12. Is there some way to keep the original brightness?
HF200 shoots AVCHD, which is YV12 4:2:0 subsampling ; AVC-Intra 100 is YUY2 4:2:2 (but I doubt you are using that). So I don't think it's a color space issue

It's likely something else, eg. playback issue, levels issue, configuration issues

How are you determining the "brightness" ?

Last edited by poisondeathray; 18th March 2010 at 15:21.
poisondeathray is offline   Reply With Quote
Old 18th March 2010, 15:38   #12  |  Link
aegisofrime
Registered User
 
Join Date: Apr 2009
Posts: 478
TGMC is *not* slow, depending on what settings you use. The speed of TGMC has been address in it's own thread by Didee himself, who did a speed and quality comparison vs Yadif+NNEDI2 using the Stockholm clip and this TGMC setting:

Code:
tempgaussmc_beta2(1,1,0,0,0,0,edimode="--",SVthin=0.0,pelsearch=1)
I would link you to his post, but for some reason I can't find it. In any case the speed result was that TGMC is faster, or at least comparable to Yadif+NNEDI2.

In any case, do give the above code a try. I get around 40 fps on a lossless rendering run with DVD footage on my Phenom II 955.
aegisofrime is offline   Reply With Quote
Old 18th March 2010, 16:14   #13  |  Link
bloodem
Registered User
 
Join Date: Jun 2005
Location: Galati, Romania
Posts: 98
Well surprise, surprise!
I just got home (after working via remote desktop, from work) and guess what... the stuttering is even WORSE than before. I tried various scripts:

1)
DirectShowSource("F:\test.mts")
AssumeTFF()
sbdeint()


2)
DirectShowSource("F:\test.mts")
AssumeTFF()
interp=nnedi2(field=3)
yadifmod(order=1, field=-1, mode=1, edeint=interp)


3)
DirectShowSource("F:\test.mts")
AssumeTFF()
TempGaussMC_beta1u(tr2=0, EdiMode="nnedi2")

They all give the same result... video stutters like hell!

Here is the test sample:
http://www.megaupload.com/?d=QYF11YFJ

What do you guys think? What am I missing here?
bloodem is offline   Reply With Quote
Old 18th March 2010, 16:32   #14  |  Link
sneaker_ger
Registered User
 
Join Date: Dec 2002
Posts: 5,565
How about you post a sample of the source.
sneaker_ger is offline   Reply With Quote
Old 18th March 2010, 17:02   #15  |  Link
bloodem
Registered User
 
Join Date: Jun 2005
Location: Galati, Romania
Posts: 98
'Course! Here is the source sample:
http://www.megaupload.com/?d=NGG7OHX3
bloodem is offline   Reply With Quote
Old 18th March 2010, 17:31   #16  |  Link
bloodem
Registered User
 
Join Date: Jun 2005
Location: Galati, Romania
Posts: 98
Well, just found out that this problem occurs only when the Media Player Classic renderer is either VMR9 or Haali. On "System Default Renderer" the framerate is smooth and there is no stuttering.
This is really starting to bug me....
PS: I'm using CoreAVC 2.0 for x264 decoding.

PPS: What's even stranger, is the fact that if I open the AVCHD file in Windows Media Player 12 (Windows 7 64Bit) the quality is INCREDIBLE... I mean, it's like some kind of ultra-expensive realtime hardware deinterlacer. I have no idea what codec it uses to achieve this...

Last edited by bloodem; 18th March 2010 at 17:49.
bloodem is offline   Reply With Quote
Old 18th March 2010, 17:47   #17  |  Link
sneaker_ger
Registered User
 
Join Date: Dec 2002
Posts: 5,565
Strange. ffmpeg2source produces awkward "jumps" on that sample, but DirectShowSource() with ffdshow seems to work fine.
sneaker_ger is offline   Reply With Quote
Old 18th March 2010, 19:55   #18  |  Link
nm
Registered User
 
Join Date: Mar 2005
Location: Finland
Posts: 2,641
Quote:
Originally Posted by bloodem View Post
PPS: What's even stranger, is the fact that if I open the AVCHD file in Windows Media Player 12 (Windows 7 64Bit) the quality is INCREDIBLE... I mean, it's like some kind of ultra-expensive realtime hardware deinterlacer. I have no idea what codec it uses to achieve this...
It uses "hardware" deinterlacing provided by your graphics card (drivers). Quality is probably somewhere between YadifMod+NNEDI2 and TGMC, if you have a fast GPU and the driver is set to use the best filter.

If you have an Nvidia GPU, I'd suggest buying DGDecNV so that you can use hardware decoding and deinterlacing when importing video to AviSynth. You'll also get a reliable, frame-accurate video source.
nm is offline   Reply With Quote
Old 18th March 2010, 20:50   #19  |  Link
bloodem
Registered User
 
Join Date: Jun 2005
Location: Galati, Romania
Posts: 98
Awesome! Thanks for the valuable info, nm! That's exactly what I wanted to know. I would certainly like to put my little 8800GT to good use
Now, the thing that bothers me now is that for some unknown reason, when using any kind of bobber to double the framerate, the video stutters like hell. If I use a switch such as SelectEven() video plays normally (but the smoothness is gone).
If I figure this out... the case would be closed.
bloodem is offline   Reply With Quote
Old 18th March 2010, 21:14   #20  |  Link
Boolsheet
Registered User
 
Join Date: Apr 2009
Location: Switzerland
Posts: 69
Quote:
Originally Posted by bloodem View Post
the video stutters like hell.
Can you pin down the cause of the stutter? Source, processing/Avisynth, encoding, playback...

Do you see this problem in the encoded test sample you posted earlier? It plays fine for me with the DivX decoder (with and without DXVA).
__________________
My nightmares are horrifying, they're all interlaced!
Boolsheet is offline   Reply With Quote
Reply


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 15:16.


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