MP uses AAC audio decoder for MKVs and MP4s! (1 Viewer)

tourettes

Retired Team Member
  • Premium Supporter
  • January 7, 2005
    17,301
    4,800
    - In MP Configuration, under Videos -> Video Player: set AC3Filter as the "MPEG / AC3 audio decoder". Set ffdshow audio decoder as the "AAC audio decoder".
    Unfortunately MP graph building is not wise enough to handle such situations. It loads only the filters and lets directshow to do the rest. In your case ffdshow has bigger filter merit valua and directshow will use that instead of the AC3Filter.

    MPII will handle graph building in different way (most likely).
     

    damaster

    Portal Pro
    November 23, 2007
    412
    35
    Canada Canada
    - In MP Configuration, under Videos -> Video Player: set AC3Filter as the "MPEG / AC3 audio decoder". Set ffdshow audio decoder as the "AAC audio decoder".
    Unfortunately MP graph building is not wise enough to handle such situations. It loads only the filters and lets directshow to do the rest. In your case ffdshow has bigger filter merit valua and directshow will use that instead of the AC3Filter.
    This is incorrect: on my system AC3Filter has much higher merit than ffdshow. The only reason it's using ffdshow is because of the bug in the code: it is putting ffdshow in the graph because I have ffdshow configured as my "AAC audio decoder":
    Code:
              if (extension.Equals(".mp4") || extension.Equals(".mkv"))
              {
                if (strH264VideoCodec.Length > 0)
                {
                  h264videoCodecFilter = DirectShowUtil.AddFilterToGraph(graphBuilder, strH264VideoCodec);
                }
    [B]            if (strAACAudioCodec.Length > 0)
                {
                  aacaudioCodecFilter = DirectShowUtil.AddFilterToGraph(graphBuilder, strAACAudioCodec);
                }
    [/B]          }

    That bolded portion of code above should be instead:
    Code:
    [B]            if (strAudioCodec.Length > 0)
                {
                  audioCodecFilter = DirectShowUtil.AddFilterToGraph(graphBuilder, strAudioCodec);
                }[/B]
    Since AAC is much less likely to be in an MKV, then it should add the audioCodecFilter to the graph, and if the audioCodecFilter doesn't support AAC, such as AC3Filter, then it will rely on DirectShow as a back-off to use the filter with higher merit. In that case, I would configure ffdshow with higher merit and allow DirectShow to use ffdshow as a back-off to AC3Filter only for any MKVs that actually have AAC encoded audio.
     

    tourettes

    Retired Team Member
  • Premium Supporter
  • January 7, 2005
    17,301
    4,800
    Ah, actually it should put the both:

    Code:
                if (strAACAudioCodec.Length > 0)
                {
                  aacaudioCodecFilter = DirectShowUtil.AddFilterToGraph(graphBuilder, strAACAudioCodec);
                }
                if (strAudioCodec.Length > 0)
                {
                  audioCodecFilter = DirectShowUtil.AddFilterToGraph(graphBuilder, strAudioCodec);
                }
    and let the filter merits and directshow handle the rest. That way AAC is also working with .mkvs. As that would allow user to configure AAC code as directshow will prefer the loaded codecs more than the ones that arent loaded but have higher merit.
     

    damaster

    Portal Pro
    November 23, 2007
    412
    35
    Canada Canada
    Ah, actually it should put the both:

    Code:
                if (strAACAudioCodec.Length > 0)
                {
                  aacaudioCodecFilter = DirectShowUtil.AddFilterToGraph(graphBuilder, strAACAudioCodec);
                }
                if (strAudioCodec.Length > 0)
                {
                  audioCodecFilter = DirectShowUtil.AddFilterToGraph(graphBuilder, strAudioCodec);
                }
    and let the filter merits and directshow handle the rest. That way AAC is also working with .mkvs. As that would allow user to configure AAC code as directshow will prefer the loaded codecs more than the ones that arent loaded but have higher merit.
    Doesn't the order matter? Shouldn't it be this instead:
    Code:
                if (strAudioCodec.Length > 0)
                {
                  audioCodecFilter = DirectShowUtil.AddFilterToGraph(graphBuilder, strAudioCodec);
                }
                if (strAACAudioCodec.Length > 0)
                {
                  aacaudioCodecFilter = DirectShowUtil.AddFilterToGraph(graphBuilder, strAACAudioCodec);
                }
     

    stoked

    MP Donator
  • Premium Supporter
  • December 14, 2007
    297
    8
    Canada Canada
    damaster,

    Would you mind posting a fixed compile that you're using for this svn?
     

    damaster

    Portal Pro
    November 23, 2007
    412
    35
    Canada Canada
    damaster,

    Would you mind posting a fixed compile that you're using for this svn?
    Sure, see first post. I've attached a patch there for SVN 21688 and will continue to update the first post with the latest patch until this gets fixed in the official stream.
     

    htpcfreak

    MP Donator
  • Premium Supporter
  • January 14, 2009
    87
    2
    Germany Germany
    Hi,

    I have the same problem on some, not all mkvs since i thing the last two SVNs. On the Final it was working.
    The patch in the first post help me also. Thx.

    But this must be fixed i thing :)
     

    Users Who Are Viewing This Thread (Users: 0, Guests: 1)

    OP Similar threads Forum Replies Date
    morpheus_xx [WiP] OnlineVideos: New browser based playback support using WebDriver, new Amazon siteutil MediaPortal 2 6
    toricred [solved] Configuring TV Server to use NAS General 1
    vvulture Using Windows 10 MediaPortal 1 Talk 8
    atlantic How to use Spotify inside Mediaportal? Listen Music 18
    Megane Too much RAM used (over 2 GB). General Support 18
    doskabouter 1.23.0 MatroskaTagInfo uses the wrong casing for tags Bugreports 27
    D how to disengage from one version of a plugin to use another Newcomers Forum 0
    D I just installed MP 1.23. Which version of Schedules Direct should I use, where do I obtain it from Newcomers Forum 6
    M Can i use my Vu+ Zero 4k Tuner for Mediaportal? General 0
    benicehavefun Using MePo TV Server 1.23 via MPExtended/WebMediaPortal as a Backend for Plex MPExtended 4
    G MP1 TV Server "failed to upgrade the database" using MS Sql Server Installation, configuration support 3
    1gkar Use Alternative Sites to Scrape Series Info My TVSeries 5
    T Can Emprex 3009ARF III MCE Remote Control be used to toggle Fullscreen/Windowed mode?? Remotes 7
    S [solved] Live TV subtitle issue if not using 100% font General 31
    N [Proposal] Make text input using remote control easier MediaPortal 2 4
    T Issues with MediaPortal not starting correctly using versions after 1.20 Final General Support 6
    erika jandova Using SD and MediaPortal 1 Newcomers Forum 4
    D Large xml database in My Movies Management. I remain unclear on use My Films as bridge to MP2.2 General 9
    N [solved] When MP2-Client is trying to register credentials, it uses the wrong machine name MediaPortal 2 7
    high [Help Me!] Atlassian Fisheye/Crucible still used? Team Lounge 8
    D [solved] HID remote for mp2 and w10 64 bit? using all tools: sony, cisco, homeworkx ng General 2
    Symphy Still being used? ASIO music player 0
    P no signal when scanning for channels using antenna and dual hd General Support 2
    N Using mediaportal in lieu of hauppauge wintv Newcomers Forum 10
    T No data available using xmltv and mc2xml xmlTV 2
    Similar threads

























    Top Bottom