PlayerManager and adding new players (1 Viewer)

sytone

Portal Member
April 17, 2013
49
70
97
Barbados Barbados
Any details on the player manager service and adding new players?
 

morpheus_xx

Lead Dev MP2
  • Team MediaPortal
  • March 24, 2007
    11,400
    6,972
    Germany Germany
    Country flag
    I moved your question into a new thread so we can focus on this topic.

    First, the best source for information is the source code of MP2. If you check here: https://github.com/MediaPortal/Medi...tal.UI/Presentation/Players/IPlayerManager.cs you'll find all methods commented.

    If you plan to add new players, this can be done by plugins. We are using the much: OnlineVideos, SlimTV, Cinema plugin, all provide own players (mostly derived from inbuilt players and extending them for new features or "linking" them to plugins).

    I'll will collect more information about examples and post them here.

    What parts you are interested in?
     

    sytone

    Portal Member
    April 17, 2013
    49
    70
    97
    Barbados Barbados
    So I have embedded the Silverlight player for Netflix in v1 in a hacky way and wanted to see what alternatives there are and if I can use that as a interface so system events can be hooked in better.
     

    morpheus_xx

    Lead Dev MP2
  • Team MediaPortal
  • March 24, 2007
    11,400
    6,972
    Germany Germany
    Country flag
    Ok, this requires a bit more brainstorming :)

    Can you please post a link to the MP1-way? I need to get an idea first how it works.
     

    sytone

    Portal Member
    April 17, 2013
    49
    70
    97
    Barbados Barbados
    So I am currently creating WebBrowser control and wrapping calls from MP and translating them to the sliverlight control in the page. This is hacky as I have added the WebBrowser to the forms Controls collection and I am intercepting calls to the window to add/remove it. I also have to do PInvokes to stop the control from eating all command sent to it as JavaScript/IE/Silverlight eat any keyboard commands, I have to refocus to the Media portal window.

    I have considered looking at ISilverlightViewer to host natively but not had time and was wondering if I can use the player framework so it was more native for MP. If I do this however I think I will have to deal with the rendering of the hosted instance.
     

    morpheus_xx

    Lead Dev MP2
  • Team MediaPortal
  • March 24, 2007
    11,400
    6,972
    Germany Germany
    Country flag
    I can explain how current video players work:

    Video Player uses DirectShow to playback a file/stream. Its output video frames are "captured" by a custom EvrPresenter, it does a callback to pass the video frame back to MP2. This frame is than used by VideoBrush to be painted in controls (fullscreen background or simple rectangle).

    So the chain is:
    DirectShow --> EvrPresenter --> Video Surface --> VideoBrush --> Rendering.

    I'm not sure if such a chain (or shorter) could work for WebBrowsers. But i.e. if you get a bitmap of the rendered screen, you could use this the same way like the video surface in my example above.

    Another way would be to let the plugin run like in MP2, bypassing the player system an using a screen that shows WebBrowser in "fullscreen" (or how you like it).

    It's an interesting topic for me, so I appreciate any work on this :)
     

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

    OP Similar threads Forum Replies Date
    DHosein Adding Custom Artwork? My TVSeries 3
    raffe [TV] Option for adding IPTV channels without checking Improvement Suggestions 0
    Rob Hexenmeister Navigation problems adding menu buttons to EPG General Support 1
    BrownGhost MP-TVSeries, Failed to save xml to cache, and not adding any info to tvseries from tvdb My TVSeries 4
    G How best to get cover art for tracks to show up on the Audio Menu (Latest Added, Unplayed)? General 9
    Neoculture "Recently Added" option My TVSeries 8
    doskabouter No guide info added due to a MYSQL deadlock Electronic Program Guide 1
    morpheus_xx [WiP] Adding 64 bit support to MP2 MediaPortal 2 15
    Hawkeye Changes to last added view Feature Requests 0
    P Media portal not adding all TV series General 2
    breese Forum Ad blocking screen and will not allow access to upper Post New Thread Website/Forum/Wiki Feedback 4
    Rob Hexenmeister ITV Player still not working for me OnlineVideos 2
    F Show Player info while skipping Feature Requests 0
    T Wish list for TV Player WMC Skin 16
    T TV Player Controls WMC Skin 0
    Icaro Close MP when the external player is started General Support 13
    T Integrated Blu-ray player General 1
    B xml file for perfect player Newcomers Forum 1
    L [solved] MP2 doesnt play anything - player missing? General 1
    G [fixed] [MP2-786] Party Music Player can only play playlists with less than 1000 items 2.2 Archive 7
    ge2301 [fixed] [MP2-807] Problem when switching player in PiP mode with audio files MediaPortal 2 32
    N Music player help Listen Music 4
    el Filou Is Windows Media Player still needed on Windows 10 ? MediaPortal 1 Talk 0
    Icaro [solved] JRiver as external player Codecs, External Players 31
    T MP 2.1.3 Audio Player General 5
    Similar threads

























    Top Bottom