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
Register FAQ Calendar Today's Posts Search

Reply
 
Thread Tools Search this Thread Display Modes
Old 8th October 2010, 11:56   #12601  |  Link
Reimar
Registered User
 
Join Date: Jun 2005
Posts: 278
Quote:
Originally Posted by Gleb Egorych View Post
Since FLAC decoding in ffdshow is done by libavcodec, the output is indead 16-bit.
Nonsense, the libavcodec FLAC decoder isn't even able to decode > 16 bit input to 16 bit raw.
If the FLAC file encodes more than 16 bit per sample libavcodec will always produce 32 bit per sample output.
What then happens in ffdshow I do not know (it might not be able to play at all, it might reduce to 16 bit, ...).
Reimar is offline   Reply With Quote
Old 8th October 2010, 12:19   #12602  |  Link
nevcairiel
Registered Developer
 
Join Date: Mar 2010
Location: Hamburg/Germany
Posts: 10,346
FLAC is actually one of the few codecs that does decode to the proper bitdepth in avcodec.
What ffdshow does with it is unknown to me, however.

FWIW, TrueHD/MLP is also properly decoded to the original bit depth.

it would be awesome if ffdshow would pass it to the renderer in the same bitdepth as it was decoded, but sadly thats not possible.
__________________
LAV Filters - open source ffmpeg based media splitter and decoders
nevcairiel is offline   Reply With Quote
Old 8th October 2010, 21:14   #12603  |  Link
jmone
Registered User
 
Join Date: Dec 2007
Posts: 652
In testing with a FLAC 24 Bit (in MKV Container) I get the following results when "Output format for uncompressed or decoded streams" has "16 and 24 bit interger" checked.
1) FFDSHOW decdoing = 16 Bits output
2) MADFLAC (decodes to 24BIT PCM) --> FFDSHOW (Uncompressed) = 16 Bits ... This one gets me, If you insert FFDSHOW back into the filter graph to do post processing it still reduce the bitdebth to 16 Bit?

However, if I check "32 bit integer" I get 32 bit output for it all.

================================

I'm not sure how these 24-Bit streams are being processed internally in FFDSHOW, so I have:
1) Unchecked 16 Bit Integer in Processing
2) Checked 16, 24, and 32 Bit Integer in the Output Format for uncompressed or decoded streams

I "think" I may get 24bit input --> ??? 32 Bit ???? internal processing --> 32 bit output, but couple of Q:
- Is this assumption correct or is something still reducing the bitdepth to 16-bit at some point in the chain?
- Why does it output at 16Bits if I have only 16 and 24 bit output checked instead of 24-bit?

Thanks
Nathan

Last edited by jmone; 8th October 2010 at 22:10. Reason: Edit - added info on Output Format + more clarification
jmone is offline   Reply With Quote
Old 8th October 2010, 21:56   #12604  |  Link
nevcairiel
Registered Developer
 
Join Date: Mar 2010
Location: Hamburg/Germany
Posts: 10,346
ffdshow will always expose all output formats that you checked, and the renderer will pick whatever it likes. Maybe it doesn't like ffdshows 24 bit, for some arcane reason? I don't know.
__________________
LAV Filters - open source ffmpeg based media splitter and decoders
nevcairiel is offline   Reply With Quote
Old 8th October 2010, 22:54   #12605  |  Link
jmone
Registered User
 
Join Date: Dec 2007
Posts: 652
Quote:
Originally Posted by nevcairiel View Post
ffdshow will always expose all output formats that you checked, and the renderer will pick whatever it likes. Maybe it doesn't like ffdshows 24 bit, for some arcane reason? I don't know.
Thanks - I can get 24 Bit output working if I uncheck 16 and 32 bit, but oddly not when 16 and 24 bit are checked (go figure)

Anyway I'm using Reclock - so the full Audio chain is now more like:

MKV (FLAC 24-Bit) Input --> FFDSHOW 32-Bit Output --> Reclock 24bit int padded to 32 (max the format the card with accept) --> WASAPI --> ATI HD5450

I'm just trying to avoid multiple conversions (esp at lower bit debths / sampling rate) unless there are other suggestions to FFDSHOW Config I'll leave it at 32-Bit Output with:
1) Uncheck 16 Bit Integer in Processing
2) Check 16, 24, and 32 Bit Integer in the Output Format

So is it confirmed (and againts prior assertions), that FFDSHOW using libavcodec is able to decode, process, and output 24-Bit FLAC at higher than 16-Bit?

Thanks
Nathan

Last edited by jmone; 8th October 2010 at 23:35. Reason: Clarity
jmone is offline   Reply With Quote
Old 9th October 2010, 11:08   #12606  |  Link
Reimar
Registered User
 
Join Date: Jun 2005
Posts: 278
Quote:
Originally Posted by jmone View Post
In testing with a FLAC 24 Bit (in MKV Container) I get the following results when "Output format for uncompressed or decoded streams" has "16 and 24 bit interger" checked.
1) FFDSHOW decdoing = 16 Bits output
2) MADFLAC (decodes to 24BIT PCM) --> FFDSHOW (Uncompressed) = 16 Bits ... This one gets me, If you insert FFDSHOW back into the filter graph to do post processing it still reduce the bitdebth to 16 Bit?

However, if I check "32 bit integer" I get 32 bit output for it all.
libavcodec never has and never will support 24 bit format (at least for decoder output, conversion is a different thing), no processor supports that format natively. Instead it will output as 32 bit and indicate that only 24 bits are really significant.
But since ffdshow obviously can do the 32 -> 16 bit conversion by itself, there's probably some code missing that converts 32 bit to 24 bit in case the decoder creates 32 bit output and you have only 16 and 24 checked.
Reimar is offline   Reply With Quote
Old 9th October 2010, 11:16   #12607  |  Link
STaRGaZeR
4:2:0 hater
 
Join Date: Apr 2008
Posts: 1,302
ffdshow doesn't output 24-bit unless everything else is unchecked. If the decoder outputs 24-bit, it'll use 32-bit int, with the extra bits zeroed (not sure about this though). So, if you have 24-bit sources, just be happy with 32-bit int because all your info is there untouched.
__________________
Specs, GTX970 - PLS 1440p@96Hz
Quote:
Originally Posted by Manao View Post
That way, you have xxxx[p|i]yyy, where xxxx is the vertical resolution, yyy is the temporal resolution, and 'i' says the image has been irremediably destroyed.
STaRGaZeR is offline   Reply With Quote
Old 9th October 2010, 15:55   #12608  |  Link
LigH
German doom9/Gleitz SuMo
 
LigH's Avatar
 
Join Date: Oct 2001
Location: Germany, rural Altmark
Posts: 6,782
Quote:
Originally Posted by LigH View Post
a) if DXVA decoding for H.264 is enabled: General { Video size = 640 x 368 }; stream list { Video: MPEG4 Video (H264) 640x360 25.00fps [Video] } -- at least MOD 16
b) if DXVA decoding for H.264 is disabled: General { Video size = 640 x 372 }; stream list { Video: MPEG4 Video (H264) 640x360 25.00fps [Video] } -- not even MOD 16?!
Any suggestion what could cause that?
__________________

New German Gleitz board
MediaFire: x264 | x265 | VPx | AOM | Xvid
LigH is offline   Reply With Quote
Old 9th October 2010, 17:46   #12609  |  Link
Reimar
Registered User
 
Join Date: Jun 2005
Posts: 278
Quote:
Originally Posted by LigH View Post
a) if DXVA decoding for H.264 is enabled: General { Video size = 640 x 368 }; stream list { Video: MPEG4 Video (H264) 640x360 25.00fps [Video] } -- at least MOD 16
b) if DXVA decoding for H.264 is disabled: General { Video size = 640 x 372 }; stream list { Video: MPEG4 Video (H264) 640x360 25.00fps [Video] } -- not even MOD 16?!

Test files: MP4 or MKV (same content, ~330 KB each)



P.S.: DGIndexNV 2026 and 2030 warn "Stream specifies cropping" (for the MKV) and report the "coded size" as 640x384 (even MOD 32).
libavcodec bug. It currently does not support cropping more than 12 pixels for interlaced streams. For this file, 384 - 360 = 24 pixels need to be cropped. (and 372 = 384 - 12).
Reimar is offline   Reply With Quote
Old 9th October 2010, 18:51   #12610  |  Link
LigH
German doom9/Gleitz SuMo
 
LigH's Avatar
 
Join Date: Oct 2001
Location: Germany, rural Altmark
Posts: 6,782
Did I encode it interlaced?! ... - My fault then. But the content was deinterlaced. I should check my parameters again.
__________________

New German Gleitz board
MediaFire: x264 | x265 | VPx | AOM | Xvid
LigH is offline   Reply With Quote
Old 10th October 2010, 21:21   #12611  |  Link
Sebastiii
Registered User
 
Join Date: Oct 2009
Location: France
Posts: 616
Hi STaRGaZeR,

It seems that when you remove mp3lib, it break something about FFDShow.Interfaces.IffdshowBase.getParamStr3(UInt32 paramID, IntPtr& bufPtr) when use FFDshow in MediaPortal, r3602 is OK but not 3604.
I try to see why.
Thanks,
Seb.

Edit :
In FFDshowAPI.cs : i comment out line 2173 : ffdshowBase.getParamStr3((uint)param, out result);
I don't know exactly is doing but it fix the issue.
__________________
HTPC : i7 920 6Go Win10(x64) / Nvidia 1050Ti / P6T Deluxe / Harman-Kardon AVR-355.

Last edited by Sebastiii; 10th October 2010 at 21:32.
Sebastiii is offline   Reply With Quote
Old 11th October 2010, 17:43   #12612  |  Link
STaRGaZeR
4:2:0 hater
 
Join Date: Apr 2008
Posts: 1,302
Can you tell me param's value when getParamStr3 is called and it crashes?
__________________
Specs, GTX970 - PLS 1440p@96Hz
Quote:
Originally Posted by Manao View Post
That way, you have xxxx[p|i]yyy, where xxxx is the vertical resolution, yyy is the temporal resolution, and 'i' says the image has been irremediably destroyed.
STaRGaZeR is offline   Reply With Quote
Old 11th October 2010, 19:17   #12613  |  Link
Sebastiii
Registered User
 
Join Date: Oct 2009
Location: France
Posts: 616
hi m8

Yes but i'm not sure to how get this value
can you help me ?
Cheers,
Seb.
__________________
HTPC : i7 920 6Go Win10(x64) / Nvidia 1050Ti / P6T Deluxe / Harman-Kardon AVR-355.
Sebastiii is offline   Reply With Quote
Old 11th October 2010, 20:11   #12614  |  Link
STaRGaZeR
4:2:0 hater
 
Join Date: Apr 2008
Posts: 1,302
Compile a debug build, put breakpoints in TffdshowBase::getParamStr3 (TffdshowBase.cpp, line 164) and run debug. When something calls the function the execution will be stopped at the first breakpoint. You can see variable names, values, etc. By pressing the play icon you'll go to the next breakpoint. You just have to look for what's in the variables when it crashes, that will pretty much tell you where the problem is. You know the issue is in getParamStr3 but knowing the exact line and variable values helps a lot. You see that the get(...) function is called from getParamStr3, if it crashes in this line you can put breakpoints in get(...) to further track down the crash. Maybe it's an incorrect param, I don't know
__________________
Specs, GTX970 - PLS 1440p@96Hz
Quote:
Originally Posted by Manao View Post
That way, you have xxxx[p|i]yyy, where xxxx is the vertical resolution, yyy is the temporal resolution, and 'i' says the image has been irremediably destroyed.
STaRGaZeR is offline   Reply With Quote
Old 11th October 2010, 20:42   #12615  |  Link
Sebastiii
Registered User
 
Join Date: Oct 2009
Location: France
Posts: 616
Quote:
Originally Posted by STaRGaZeR View Post
Compile a debug build, put breakpoints in TffdshowBase::getParamStr3 (TffdshowBase.cpp, line 164) and run debug. When something calls the function the execution will be stopped at the first breakpoint. You can see variable names, values, etc. By pressing the play icon you'll go to the next breakpoint. You just have to look for what's in the variables when it crashes, that will pretty much tell you where the problem is. You know the issue is in getParamStr3 but knowing the exact line and variable values helps a lot. You see that the get(...) function is called from getParamStr3, if it crashes in this line you can put breakpoints in get(...) to further track down the crash. Maybe it's an incorrect param, I don't know
Thanks,

So i have compil debug version of FFDShow, put break point line 164.
Start debug -> select -> mediaportal.exe
Open a movie and try to select subtitle.
MVS2008 -> ask me for FFDShowAPI.cs (the one from MePo Sources).
After that, it stop on line 2254 (from this FFDShowAPI.cs) line for the one from FFDShow source is line 2173.

I have this value for param :
FFDShow.FFDShowConstants.FFDShowDataId.IDFF_subTempFilename

Quote:
2010-10-11 21:19:41.291121 [ERROR][MPMain(1)]: Exception :System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
at FFDShow.Interfaces.IffdshowBase.getParamStr3(UInt32 paramID, IntPtr& bufPtr)
at FFDShow.FFDShowAPI.getStringParam(FFDShowDataId param) in D:\svnroot\mediaportal_FFDshow_Patch18_Edition_MPCSubs\mediaportal\Core\Player\FFDShow\FFDShowAPI.cs:line 2254
at FFDShow.FFDShowAPI.get_CurrentSubtitleFile() in D:\svnroot\mediaportal_FFDshow_Patch18_Edition_MPCSubs\mediaportal\Core\Player\FFDShow\FFDShowAPI.cs:line 1129
at MediaPortal.Player.Subtitles.FFDShowEngine.get_CurrentSubtitleFile() in D:\svnroot\mediaportal_FFDshow_Patch18_Edition_MPCSubs\mediaportal\Core\Player\FFDShow\FFDShowEngine.cs:line 286
at MediaPortal.Player.Subtitles.FFDShowEngine.SwitchToNextSubtitle() in D:\svnroot\mediaportal_FFDshow_Patch18_Edition_MPCSubs\mediaportal\Core\Player\FFDShow\FFDShowEngine.cs:line 343
at MediaPortal.Player.g_Player.SwitchToNextSubtitle() in D:\svnroot\mediaportal_FFDshow_Patch18_Edition_MPCSubs\mediaportal\Core\Player\g_player.cs:line 2627
at MediaPortal.GUI.Video.GUIVideoFullscreen.OnAction(Action action)
at MediaPortal.GUI.Library.GUIWindowManager.OnAction(Action action) in D:\svnroot\mediaportal_FFDshow_Patch18_Edition_MPCSubs\mediaportal\Core\guilib\GUIWindowManager.cs:line 457
at MediaPortalApp.OnAction(Action action)
2010-10-11 21:19:41.291121 [ERROR][MPMain(1)]: Exception :Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
2010-10-11 21:19:41.292121 [ERROR][MPMain(1)]: site :Int32 getParamStr3(UInt32, IntPtr ByRef)
2010-10-11 21:19:41.292121 [ERROR][MPMain(1)]: source :Core
2010-10-11 21:19:41.293121 [ERROR][MPMain(1)]: stacktrace: at FFDShow.Interfaces.IffdshowBase.getParamStr3(UInt32 paramID, IntPtr& bufPtr)
But i didn't stop on breakpoint

I really don't know why
Thanks.

Ps : Thx to Underground78 to try to help me
__________________
HTPC : i7 920 6Go Win10(x64) / Nvidia 1050Ti / P6T Deluxe / Harman-Kardon AVR-355.
Sebastiii is offline   Reply With Quote
Old 12th October 2010, 14:45   #12616  |  Link
STaRGaZeR
4:2:0 hater
 
Join Date: Apr 2008
Posts: 1,302
Quote:
Originally Posted by Sebastiii View Post
Thanks,

So i have compil debug version of FFDShow, put break point line 164.
Start debug -> select -> mediaportal.exe
Open a movie and try to select subtitle.
MVS2008 -> ask me for FFDShowAPI.cs (the one from MePo Sources).
After that, it stop on line 2254 (from this FFDShowAPI.cs) line for the one from FFDShow source is line 2173.

I have this value for param :
FFDShow.FFDShowConstants.FFDShowDataId.IDFF_subTempFilename



But i didn't stop on breakpoint

I really don't know why
Thanks.

Ps : Thx to Underground78 to try to help me
After building a debug version you have to register it (by using register.bat for example). If everything is right, your breakpoints will stay red after you start debug. If something went wrong, they'll be grey with a yellow exclamation sign. One good way of knowing if you're really using the debug version is to check deband for example, video will freeze because of the speed penalty.

This crash is related to subtitles, and I didn't change anything regarding subtitles in the mp3lib commit, so I'm out of ideas. What you can do is revert file by file until you find what makes it crash. BTW, why does MP have a different FFDShowAPI.cs? Really a noob on this I am
__________________
Specs, GTX970 - PLS 1440p@96Hz
Quote:
Originally Posted by Manao View Post
That way, you have xxxx[p|i]yyy, where xxxx is the vertical resolution, yyy is the temporal resolution, and 'i' says the image has been irremediably destroyed.
STaRGaZeR is offline   Reply With Quote
Old 12th October 2010, 17:07   #12617  |  Link
Sebastiii
Registered User
 
Join Date: Oct 2009
Location: France
Posts: 616
Thanks,

I will try this this evening
I have look @ each file and yes nothing related to sub (and it's only happen for external sub).

I don't know exactly why the API (cs) is different, i know that i have add modification in FFDShowAPI.cs but the bug appear after r3602.

I'll and notice you
Thanks again.
__________________
HTPC : i7 920 6Go Win10(x64) / Nvidia 1050Ti / P6T Deluxe / Harman-Kardon AVR-355.
Sebastiii is offline   Reply With Quote
Old 12th October 2010, 19:09   #12618  |  Link
magic144
Registered User
 
Join Date: May 2005
Posts: 395
raised a new issue on bug-tracker regarding subtitle (start play with subs hidden) interaction between Zoom Player 7.1a5 and clsid's newest 32-bit/x86 ffdshow build (3611)
https://sourceforge.net/tracker/?fun...41&atid=867360

also CC'd ZP msg board
thanks,
m
magic144 is offline   Reply With Quote
Old 12th October 2010, 22:41   #12619  |  Link
Sebastiii
Registered User
 
Join Date: Oct 2009
Location: France
Posts: 616
Quote:
Originally Posted by STaRGaZeR View Post
After building a debug version you have to register it (by using register.bat for example). If everything is right, your breakpoints will stay red after you start debug. If something went wrong, they'll be grey with a yellow exclamation sign. One good way of knowing if you're really using the debug version is to check deband for example, video will freeze because of the speed penalty.

This crash is related to subtitles, and I didn't change anything regarding subtitles in the mp3lib commit, so I'm out of ideas. What you can do is revert file by file until you find what makes it crash. BTW, why does MP have a different FFDShowAPI.cs? Really a noob on this I am
Hi,

Debug version is working (register .ax) but the issue is always here and i didn't find what happen, i have try each file but it's hard because all is link between them (not all but a big part).

And i didn't see why is related to sub section
+++
__________________
HTPC : i7 920 6Go Win10(x64) / Nvidia 1050Ti / P6T Deluxe / Harman-Kardon AVR-355.

Last edited by Sebastiii; 14th October 2010 at 08:34.
Sebastiii is offline   Reply With Quote
Old 14th October 2010, 21:31   #12620  |  Link
TheShadowRunner
Registered User
 
TheShadowRunner's Avatar
 
Join Date: Feb 2004
Posts: 399
It seems libavcodec's VP6F decoding has a slight bug. Here is a sample video:
http://videoff7.free.fr/FF13_fn.avi (15megs)
When decoded by ffdshow, there is some disturbance at the very bottom of the screen, all along. When played via activex (on website), there is no such artefact.
I tried every renderer and no changes, if anyone has a clue on how to solve this? ^^;

Last edited by TheShadowRunner; 14th October 2010 at 22:11.
TheShadowRunner is offline   Reply With Quote
Reply

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


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


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