MP2 - V2.5 TVMosaic Provider for MP2 (4 Viewers)

joecrow

Test Group
  • Team MediaPortal
  • August 9, 2012
    2,647
    1,994
    Home Country
    Germany Germany
    New recordings are only displayed after a new manual synchronization. I read somewhere that an automatic synchronization should be installed. Just like deleting individual recordings in MP2.
    So how do I do a manual sync and how to install an automatic one?
     

    ge2301

    Lead Design MP2
  • Team MediaPortal
  • January 11, 2014
    8,736
    3,501
    Stuttgart
    Home Country
    Germany Germany
    @morpheus_xx I had a go at starting to implement a ResourceProvider and MetadataExtractor to access and import the recordings through the API. It basically works. I pushed to a new branch here.

    There are still a few open points:
    • The TvMosaic IP and port aren't available on the server...yet, so I've just hardcoded some values here for now. When testing you'll obviously need to update those if necessary. Ultimately isn't it probably best if these are stored on the server anyway so each client doesn't have to be configured individually?
    • I set the mime type of the recordings to LiveTvMediaItem.MIME_TYPE_TV_STREAM as a quick and dirty solution to test playback on the client, this uses the live TV stream player as that already had support for playing back from a url. This player expects a live TV stream though so has a few issues but playback basically works
    • Some more metadata can probably be imported, e.g. thumbnails and I'm not sure if I interpreted the times and durations correctly
    • Currently the share has to be added manually in the usual way through Add Media Source, you'll see a new provider there for TvMosaic when selecting what type of share to add which will allow you to add a recordings 'directory', then you'll need to select Video as category. However there doesn't seem to be an easy way to trigger a reimport when a recording gets added or deleted beyond adding some sort of polling...which might mean just adding custom recording screens that access the API directly might be better
    @joecrow it is described earlier in this thread how to deal with recordings. Just in case you missed it.
    There is no automatic import yet if I understood correctly.
     

    joecrow

    Test Group
  • Team MediaPortal
  • August 9, 2012
    2,647
    1,994
    Home Country
    Germany Germany
    @joecrow it is described earlier in this thread how to deal with recordings. Just in case you missed it.
    There is no automatic import yet if I understood correctly.
    TV Mosaic was already set up as a share and doing a re-import did not bring in the recording also tried removing and re-adding the source and although the import arrow showed up my recording folder remains empty.
    rec_1.jpg
     

    Timhoh1234

    Portal Pro
    September 29, 2015
    252
    90
    Home Country
    Germany Germany
    I’ve the same issue, imports do not show recordings though the share is added correctly. In the past this worked. Are you working on a fix?
     

    morpheus_xx

    Retired Team Member
  • Team MediaPortal
  • March 24, 2007
    12,073
    7,459
    Home Country
    Germany Germany
    @Brownard , you developed the resource provider and MDE, do you have an idea how we could trigger the reimport?

    We could poll the TvMosaic server for known schedules, or recordings, and after changes we could force a reimport. Or is there a better way?
     

    Brownard

    Development Group
  • Team MediaPortal
  • March 21, 2007
    2,305
    1,884
    Home Country
    United Kingdom United Kingdom
    Some sort of polling is the only way I think, it's just a question of how smart we can make it, e.g. check recordings returned by the API against the database at some regular interval and additionally shortly after a schedule is due to finish (or start if TV Mosaic supports playback of ongoing recordings) to get them in the database as soon as possible.
     

    Brownard

    Development Group
  • Team MediaPortal
  • March 21, 2007
    2,305
    1,884
    Home Country
    United Kingdom United Kingdom
    I've started to implement automatic import of recordings, there are a couple of things to consider.

    TvMosaic returns the recorded tv item as soon as the recording starts, however when playing back an ongoing recording the stream will only play up to wherever the recording had reached at the time the stream was requested, i.e. if you start playback 2 minutes into a recording you can watch those 2 minutes then the stream stops (whereas TV Server keeps appending to the stream until the recording completes), which probably makes watching ongoing recordings impractical as you'd have to keep restarting and FF the stream to get the next bit of the recording. Additionally if we import the recording at this point then the duration gets stored as the duration at that particular point and we'd need to figure out which items have changed duration when reimporting to update the duration, which is possible but not easy.

    The easiest thing to implement is to only import recordings that have actually finished, so they are guaranteed to be fully playable and have the correct metadata. Any objections to this?
     

    ge2301

    Lead Design MP2
  • Team MediaPortal
  • January 11, 2014
    8,736
    3,501
    Stuttgart
    Home Country
    Germany Germany
    The easiest thing to implement is to only import recordings that have actually finished, so they are guaranteed to be fully playable and have the correct metadata. Any objections to this?
    No objection from my side :)
     

    joecrow

    Test Group
  • Team MediaPortal
  • August 9, 2012
    2,647
    1,994
    Home Country
    Germany Germany
    The easiest thing to implement is to only import recordings that have actually finished, so they are guaranteed to be fully playable and have the correct metadata. Any objections to this?
    Not optimal from my point of view, as a user, having to wait for a recording to finish before being able to view. If watching a recording in progress is not dooable or very difficult to implement then yes go for it that so we have something working. Would it be possible to display the recording(s) in progress thumbnail(s) with a notification saying not available to view till complete?
     
    Last edited:

    Users who are viewing this thread

    Top Bottom