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 > New and alternative video codecs

Reply
 
Thread Tools Search this Thread Display Modes
Old 27th January 2010, 15:15   #10501  |  Link
tal.aloni
Registered User
 
Join Date: Sep 2008
Posts: 496
Quote:
Originally Posted by clsid View Post
What does the internal subtitle renderer of MPC-HC use? That works with DXVA and has low overhead.
that's the first thing I asked casimir,
1. they are using Direct3D, they create a seperate DX surface and let the hardware merge the two surfaces using DX, however, in order to do so, they are using a custom renderer.
I believe you can only do it their way if you develop a custom renderer. (or serving a custom allocator presenter to the VMR9 renderer)

2. they get this great performace because they're not filling the entire surface, they're only drawing on a surface big enough to draw the subtitles [I think they are using multiple small surfaces] (you can't do it easily in ffdshow, especially not if the OSD is involved).

Last edited by tal.aloni; 27th January 2010 at 15:43.
tal.aloni is offline   Reply With Quote
Old 27th January 2010, 15:34   #10502  |  Link
HeadlessCow
Registered User
 
Join Date: Nov 2002
Posts: 131
Oh yeah, one more thing. When playing VC1, the OSD showed up briefly when the video loaded, but wasn't visible after that.
HeadlessCow is offline   Reply With Quote
Old 27th January 2010, 16:17   #10503  |  Link
Jeremy Duncan
Didée Fan
 
Jeremy Duncan's Avatar
 
Join Date: Feb 2006
Location: Canada
Posts: 1,079
Quote:
Originally Posted by albain View Post
What do you mean ? Do yo have his contact information ?
mike(insert at here)haali.net
__________________
When I get tired during work with dvd stuff i think of River Tamm (Summer Glau's character). And the beauty that is Serenity.
Jeremy Duncan is offline   Reply With Quote
Old 27th January 2010, 16:51   #10504  |  Link
rsd78
Registered User
 
Join Date: Jan 2009
Posts: 73
Anyone else able to report back any CPU usage comparison between latest beta (DXVA + Overlay) and just DXVA? Thanks
rsd78 is offline   Reply With Quote
Old 27th January 2010, 17:09   #10505  |  Link
CiNcH
Registered User
 
CiNcH's Avatar
 
Join Date: Jan 2004
Posts: 567
Beta 3 is great! With beta 2 I experienced a lot of judder with subtitles being used and an increase in CPU usage from < 10% to > 40% on a C2D E6420. With beta 3 now, playback seems perfect with a CPU usage of only < 20%, effectively cutting it in half.
__________________
Bye
CiNcH is offline   Reply With Quote
Old 27th January 2010, 17:12   #10506  |  Link
rsd78
Registered User
 
Join Date: Jan 2009
Posts: 73
Also @Albain/Tal.Aloni,

Would Media Control now work with Beta3 to control subtitles? Thanks
rsd78 is offline   Reply With Quote
Old 27th January 2010, 17:41   #10507  |  Link
onomatopellan
Registered User
 
Join Date: Jan 2010
Posts: 47
Great work with beta 3!

It's very unstable (can't close the MPCHC without crashing like you said, cant' use Graphedit without crash) but I fixed it just replacing libavcodec.dll with the rv3217 XhmikosR's version. (rv3218 still crash BTW)

Overlay mode is very good, good quality and fast! In my AthlonXP2800 now I can watch 720p movies with subtitles with ~50% cpu usage (30% more than without Post processing) and karaoke is very fluid, awesome!


Something I've noticed is that in subs with fading (karaoke) the subtitles are somewhat transparent. These should be completely white for example:


Text input pin indeed has been enabled and I can use it now in Graphedit but it does detect the embedded sub in some mkv files and in some doesn't. External sub works without problem though.
onomatopellan is offline   Reply With Quote
Old 27th January 2010, 18:30   #10508  |  Link
tal.aloni
Registered User
 
Join Date: Sep 2008
Posts: 496
Quote:
Originally Posted by onomatopellan View Post
Something I've noticed is that in subs with fading (karaoke) the subtitles are somewhat transparent. These should be completely white for example:
well, oddly enough, that's actually on purpose,
you see, in YV12 / NV12 colorspace, 4 pixels (2x2) share the same color information (chroma), so if I would write the luma everytime I write the chroma, it would effectively limit the resolution by a factor of 1/4. (I've tried that, it looks aweful).

I guess I can write the chroma if I'm modifying 4 out of 4 pixels, it's not as fast though. I'm still experimenting.

Quote:
Text input pin indeed has been enabled and I can use it now in Graphedit but it does detect the embedded sub in some mkv files and in some doesn't.
this shouldn't be different than the software decoder, regarding which format supported and which are not, I'm not an expert.
but I guess that now that we have DXVA with subs, we will have to improve.
tal.aloni is offline   Reply With Quote
Old 27th January 2010, 18:33   #10509  |  Link
tal.aloni
Registered User
 
Join Date: Sep 2008
Posts: 496
Guys, The crash starts with 3218!

Edit:
it seems pretty obvious why the crash is occuring @ 3218+ (w32thread.c):
if avcodec_thread_execute2 is called with count of 1 thread, than no thread would be allocated, and when trying to release with avcodec_thread_free, the crash would occur.

Quote:
Originally Posted by TvideoCodecLibavcodecDxva.cpp
// One thread for DXVA mode
int numthreads=1;
libavcodec->avcodec_thread_init(avctx,threadcount=numthreads);
Edit:
I talked to the ffmpeg. I'll commit a fix soon.

Last edited by tal.aloni; 27th January 2010 at 19:32.
tal.aloni is offline   Reply With Quote
Old 27th January 2010, 18:45   #10510  |  Link
HeadlessCow
Registered User
 
Join Date: Nov 2002
Posts: 131
Quote:
this shouldn't be different than the software decoder, regarding which format supported and which are not, I'm not an expert.
but I guess that now that we have DXVA with subs, we will have to improve.
libass here we come!

Quote:
t seems pretty obvious why the crash is occuring @ 3218+:
if avcodec_thread_execute2 is called with count of 1 thread, than no thread would be allocated, and when trying to release with avcodec_thread_free, the crash would occur.
Nice find on the crash!
HeadlessCow is offline   Reply With Quote
Old 27th January 2010, 19:17   #10511  |  Link
albain
Media Control author
 
Join Date: Dec 2006
Location: Paris
Posts: 1,014
Quote:
Originally Posted by onomatopellan View Post
Great work with beta 3!
Text input pin indeed has been enabled and I can use it now in Graphedit but it does detect the embedded sub in some mkv files and in some doesn't. External sub works without problem though.
It shouldn't, maybe some media types are missing

Could you post a sample and eventually debugview logs with working + non working samples ?

About Media Control, it should work with DXVA filter (the remote/keyboard filter is enabled)
albain is offline   Reply With Quote
Old 27th January 2010, 19:46   #10512  |  Link
arestarh
Registered User
 
arestarh's Avatar
 
Join Date: Nov 2008
Location: Ukraine
Posts: 34
albain
Hello!
I'm again about problems with translation:
I can't open in translation mode dialogs:

And even I manually edit file of localization(add necessary strings), *Add* and *Reset* buttons in both dialogs and also dialog *Use ffdshow only in* is not appeared in GUI:

simply, I can't translate this elements...

And about section of Subtitles in configuration dialog.
I can't translate this dialog:


Edit:
Also, I can't translate following header(language file contains string "configuration=translation_of_this_header"):

Last edited by arestarh; 27th January 2010 at 19:54.
arestarh is offline   Reply With Quote
Old 27th January 2010, 19:47   #10513  |  Link
tal.aloni
Registered User
 
Join Date: Sep 2008
Posts: 496
crashing problem is fixed in rev. 3232
I've talked to ffmpeg devs, they have explained that avcodec_close() calls avcodec_thread_free(), so there's no need to call avcodec_thread_free() for the second time. (that's what caused the crash)
tal.aloni is offline   Reply With Quote
Old 27th January 2010, 23:28   #10514  |  Link
tal.aloni
Registered User
 
Join Date: Sep 2008
Posts: 496
DXVA Post Processing - Beta 4

Quote:
Originally Posted by HeadlessCow View Post
Oh yeah, one more thing. When playing VC1, the OSD showed up briefly when the video loaded, but wasn't visible after that.
Thanks, this is fixed in beta 4,
however, there are still issues with VC-1, now the osd / subs will be shown only after ~100 frames. I'm not sure why.

also: overlay will not be "transparent" anymore, it now also writes chroma when 3 or 4 (out of 4) pixels (luma) are being written.
(it should be slightly slower, but not much)

build
http://iknowu.net/files/public/ffdsh...sing-Beta4.exe

patch
http://iknowu.net/files/public/ffdsh...ng-Beta4.patch
tal.aloni is offline   Reply With Quote
Old 28th January 2010, 00:33   #10515  |  Link
HeadlessCow
Registered User
 
Join Date: Nov 2002
Posts: 131
Quote:
now the osd / subs will be shown only after ~100 frames. I'm not sure why.
LOL! Tricky software! I'll check out the build tonight after celebrating my mom's birthday!
HeadlessCow is offline   Reply With Quote
Old 28th January 2010, 02:39   #10516  |  Link
Jeremy Duncan
Didée Fan
 
Jeremy Duncan's Avatar
 
Join Date: Feb 2006
Location: Canada
Posts: 1,079
3233 patch for accurate frame seeking in avisynth
generic beta
icl11 beta
__________________
When I get tired during work with dvd stuff i think of River Tamm (Summer Glau's character). And the beauty that is Serenity.
Jeremy Duncan is offline   Reply With Quote
Old 28th January 2010, 02:45   #10517  |  Link
leeperry
Kid for Today
 
Join Date: Aug 2004
Posts: 3,477
thanks Jeremy, I'll look into them and report back!

the current official beta crashes sometimes at opening...but if I open it again, then it's fine?! it happens very rarely IME anyway, I'd say it works 99.99% of the time...good enough to me considering I use ColorMatrix(SD only)/LSF/GrainF3 on all my videos
leeperry is offline   Reply With Quote
Old 28th January 2010, 07:59   #10518  |  Link
CruNcher
Registered User
 
CruNcher's Avatar
 
Join Date: Apr 2002
Location: Germany
Posts: 4,926
Quote:
Originally Posted by tal.aloni View Post
crashing problem is fixed in rev. 3232
I've talked to ffmpeg devs, they have explained that avcodec_close() calls avcodec_thread_free(), so there's no need to call avcodec_thread_free() for the second time. (that's what caused the crash)
yep tried 3233 and its gone
__________________
all my compares are riddles so please try to decipher them yourselves :)

It is about Time

Join the Revolution NOW before it is to Late !

http://forum.doom9.org/showthread.php?t=168004
CruNcher is offline   Reply With Quote
Old 28th January 2010, 10:03   #10519  |  Link
littleD
Registered User
 
littleD's Avatar
 
Join Date: Aug 2008
Posts: 343
Quote:
Originally Posted by tal.aloni View Post
Thanks, this is fixed in beta 4,
however, there are still issues with VC-1, now the osd / subs will be shown only after ~100 frames. I'm not sure why.
Here, subs may have slight delay. OSD shows immediately.

Quote:
also: overlay will not be "transparent" anymore, it now also writes chroma when 3 or 4 (out of 4) pixels (luma) are being written.
(it should be slightly slower, but not much)
Yes, subs are white all the time.

Some vc-1 videos get cpu at 100%. And no crashes ofc.
littleD is offline   Reply With Quote
Old 28th January 2010, 19:06   #10520  |  Link
onomatopellan
Registered User
 
Join Date: Jan 2010
Posts: 47
Testing beta4 and it's the best so far: no transparent subs, more stable and fast... great work!

@albain/tal.aloni: After testing lots of mkv files I have discovered in 80% of my collection embedded subs are not detected. So the problem maybe is not in ffdshow but in splitter (I'm using last haali) or something in the graph connection. Ffdshow software decoder detects the embedded sub without problem.

I noticed this: When subs are not shown I only have to delete de subtitle->In Text connection in GraphStudio and reconnect it again, and then the subs are shown without problem.
I have tried with all the problematic video files and now all the embedded subtitles are detected using the 'trick' above.

That's using GraphStudio/Graphedit, in MPC-HC embedded subs are not detected though.

These are the Debugview logs while using GraphStudio (playing the same video file):
LOG WHEN SUBS ARE NOT SHOWN

LOG WHEN SUBS ARE SHOWN (trick)

Last edited by onomatopellan; 28th January 2010 at 19:14.
onomatopellan is offline   Reply With Quote
Reply

Tags
ffdshow, ffdshow tryouts, ffdshow-mt, ffplay, icl

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 20:06.


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