[Finished] MP1-4777 Additional info for video and audio (1 Viewer)

yartat

Portal Pro
October 1, 2007
71
115
Kjiv, Ukraine
Home Country
Ukraine Ukraine
Description of Change

This branch will change code of enumeration player streams. it's planing mix them with information from the MediaInfoLib.
Unfortunately information about stereoscopic type contains only in the .MKV container. MediaInfoLib detects stereoscopic type well.
For now, there is no way to detect stereoscopic type in the .TS container.
It will create new stream detection.

For ex :
Would it be possible to have a detection based on video track name too?
Would it be possible to disable 3D subtitle rendering if a subtitle track name contains 3D?

Adding new event to g_Player ChangeStream with information about type of the stream to change and information about this stream. This event can be used with third party plugins.

This is a big FEAT / REWORK so get attention about testing, with enough good result and without regression, it surely can go in next MP release.

Jira Link : https://issues.team-mediaportal.com/browse/MP1-4777
Wiki docs: Explain used with third party plugins

Steps to install and test
Installation
2016.03.06 :
Download the -->> Installer based on 1.14 Pre-release <<-- and execute it. (Not available for now)

Testing
Upgrade your current 1.14 Pre-release or 1.13 installation and try :
Please do not forget to give some feedback (also if there is no bug). Thank you!
That's all

Sebastiii

Changelog

Thanks to @yartat
 
Last edited by a moderator:

yartat

Portal Pro
October 1, 2007
71
115
Kjiv, Ukraine
Home Country
Ukraine Ukraine
According to this post I created pull request with additional info for video and audio stream in g_Player and event to notification when user change audio or video stream. Please, check it
 
Last edited:

Sebastiii

Development Group
  • Team MediaPortal
  • November 12, 2007
    16,583
    10,403
    France
    Home Country
    France France
    According to this post I created pull request with additional info for video and audio stream in g_Player and event to notification when user change audio or video stream. Please, check it

    Hi,

    I have build issue with your branch :

    Code:
    Error    15    The command ""D:\MediaPortal-1-Git\mediaportal\MediaPortal.Tests\PostBuild.bat" "D:\MediaPortal-1-Git\mediaportal\" Debug" exited with code 4.    MediaPortal.Tests
    Also when i will be able to buid, can you explain why you have removed :

    C#:
    if (MediaInfo != null && !MediaInfo.MediaInfoNotloaded && !MediaInfo.HasVideo)
    vs
    if (MediaInfo != null && !MediaInfo.HasVideo)

    We add that when mediainfo was not able to scan a file, so it means that mediainfo can failed on some file, so we need to have something working when it happen (for ex : .WTV failed).

    Thanks :)
     

    Sebastiii

    Development Group
  • Team MediaPortal
  • November 12, 2007
    16,583
    10,403
    France
    Home Country
    France France
    Ok above error it's because directshowfilter was not builded :) so need to compared how is the other postbuild.bat :)
     

    Sebastiii

    Development Group
  • Team MediaPortal
  • November 12, 2007
    16,583
    10,403
    France
    Home Country
    France France
    @yartat I will push a branch based on your rework but i have put in back the MediaInfoNotloaded and also i have change the space line to be conform with MP1 rules (read here :
    http://wiki.team-mediaportal.com/1_MEDIAPORTAL_1/18_Contribute/4_Development/Coding_Standards)

    Could you test the branch (when pushed) and be sure that all space line are ok ?
    Thanks :)

    EDIT : Also i have put in back the mediainfo.dll .69 because recent one is broken on .TS and teletext subs. We also need to use nuget for that and not adding bin. So maybe other dll be be added to a nuget package.

    EDIT 2 : Also why remove : TvEngine3\TVLibrary\TvThumbnails\VideoThumbCreator\MediaInfo.cs it's needed for generate Thumb on TVServer side.

    EDIT 3 : Hope it didn't break : MP1-4757-FEAT-Add_stream_selection_based_on_LAV_Splitter

    @Marcus Venturi sorry to hijack your thread, i will surely open an Area51 thread for this and move post threre.
     
    Last edited:

    yartat

    Portal Pro
    October 1, 2007
    71
    115
    Kjiv, Ukraine
    Home Country
    Ukraine Ukraine
    C#:
    if (MediaInfo != null && !MediaInfo.MediaInfoNotloaded && !MediaInfo.HasVideo)
    vs
    if (MediaInfo != null && !MediaInfo.HasVideo)

    We add that when mediainfo was not able to scan a file, so it means that mediainfo can failed on some file, so we need to have something working when it happen (for ex : .WTV failed).

    Thanks :)
    I replaced MediaInfo definition from official github. This implementation does not support MediaInfoNotloaded. :)
    i have change the space line to be conform with MP1 rules (read here : http://wiki.team-mediaportal.com/1_MEDIAPORTAL_1/18_Contribute/4_Development/Coding_Standards)
    My fault. Sorry. I develop 3 projects as parallel and forgot switch sometimes.
    Could you test the branch (when pushed)?
    I tested more than 100 movies and clips from my collection movies (about 750 items)
    A liitlle bit of them in the Mediaportal.Tests
     

    Sebastiii

    Development Group
  • Team MediaPortal
  • November 12, 2007
    16,583
    10,403
    France
    Home Country
    France France
    C#:
    if (MediaInfo != null && !MediaInfo.MediaInfoNotloaded && !MediaInfo.HasVideo)
    vs
    if (MediaInfo != null && !MediaInfo.HasVideo)

    We add that when mediainfo was not able to scan a file, so it means that mediainfo can failed on some file, so we need to have something working when it happen (for ex : .WTV failed).

    Thanks :)
    I replaced MediaInfo definition from official github. This implementation does not support MediaInfoNotloaded. :)

    Ok :) but that's needed here :) when a mediainfo failed to analyse a file :)

    I have try to merge the new branch into my own for testing too and it break the realspeed branch (MP1-4745-Slow_down_playback) from @regeszter. But that lead to the fact that i think we need to try to load mediainfo once, i remember changing something about a long time ago to avoid multiple loading on mediainfo to speed the process, so now i'm not sure that your branch is OK on this side.
     

    Sebastiii

    Development Group
  • Team MediaPortal
  • November 12, 2007
    16,583
    10,403
    France
    Home Country
    France France
    Yep you revert the change made a long time ago :(
    For example (but there are other place):

    Here, it try to not reload it if already loaded :
    C#:
    // Set currentMediaInfoFilePlaying for later use if it's the same media to play (it will cache mediainfo data)
            MediaInfoWrapper mInfo = null;
            if (!string.IsNullOrEmpty(g_Player.currentMediaInfoFilePlaying) && (g_Player.currentMediaInfoFilePlaying == strFilenameAndPath))
            {
              mInfo = g_Player._mediaInfo;
            }
            else
            {
              g_Player.currentMediaInfoFilePlaying = strFilenameAndPath;
              mInfo = g_Player._mediaInfo = new MediaInfoWrapper(strFilenameAndPath);
            }

    to

    Now you always read/load mediainfo :

    C#:
            // Set currentMediaInfoFilePlaying for later use if it's the same media to play (it will cache mediainfo data)
            var mediaInfo = new MediaInfoWrapper(strFilenameAndPath);
            if (string.IsNullOrEmpty(g_Player.currentMediaInfoFilePlaying) || g_Player.currentMediaInfoFilePlaying != strFilenameAndPath)
            {
              g_Player.currentMediaInfoFilePlaying = strFilenameAndPath;
            }

    I will try to explain what it's needed, the purpose of old code, is to try to load only once the mediainfo.dll and reload it or refresh it if it's really needed.
    So do you think you can do that way too (with your new code) ? And really reload mediainfo if it's really needed.
     

    Sebastiii

    Development Group
  • Team MediaPortal
  • November 12, 2007
    16,583
    10,403
    France
    Home Country
    France France
    Thanks :) i have almost change the code guide lines in MP1-4777 so please use it (on your own repo ofc), you just need to fetch MP1 repo? Thanks.
     

    Users who are viewing this thread

    Top Bottom