Discussion: Find and Download Subtitles (1 Viewer)

morpheus_xx

Lead Dev MP2
  • Team MediaPortal
  • March 24, 2007
    11,487
    7,020
    Germany Germany
    Country flag
    In MP1, DVB subtitle decoding and rendering is handled in the graph (DVB sub filter). SetSubtitleStream() simply selects the PID which is passed to the DVB subs filter. However, teletext subtitle [and page] decoding and overlay is handled in the player. SetSubtitleStream() could select which teletext PID to pass back to the player (most or all channels have 0 or 1 teletext stream, so I don't understand the point)...??? ...but where will the teletext be decoded for rendering?
    I see. Probably we would need a combination of:
    1. Full support of IAMStreamSelect to expose available streams and allow user selection
    2. Output of selected stream types to a subtitle "decode filter"
      1. DvbSub3 to handle also teletext decoding, same way as for DVB. The filter input pin would need to handle more media(sub)types than now
      2. A new filter could be developed (more complicated to handle; additional TsReader output pin, graph building etc..)
      3. (A callback interface in TsReader itself)
    3. Handling of subtitle callbacks from DvbSub3.ax is already implemented in C# side.
    While this is good for all subtitles, I'm not sure about the "teletext page" handling.

    IMO also this decoding could be done by one of the existing filters, which then do callbacks with decoded data to C# side.

    I'm interested in this topic because I was assuming I would need to reimplement teletext page decoding in the TVE 3.5 plugin for MP1, but if the player design changes then I will need to know what to do. Also, I'm wondering if and how you will implement teletext page viewing in MP2...
    I didn't use Teletext on TV sinces years. And in MP1 it also was one of the code parts which lead to many crashes once you used it. Besides that I think it's still useful for some users, so I think MP2 should have support for it as well.
     

    morpheus_xx

    Lead Dev MP2
  • Team MediaPortal
  • March 24, 2007
    11,487
    7,020
    Germany Germany
    Country flag
    Looks like the 3rd point above is the existing one, I will check how to integrate the ITeletextSource into MP2 TsVideoPlayer...
     

    Owlsroost

    Development Group
  • Team MediaPortal
  • October 28, 2008
    5,540
    5,038
    Cambridge
    United Kingdom United Kingdom
    Country flag
    Note that you can have Teletext (pages) and DVB Subtitles at the same time - so it could be an and/or situation in theory.

    I'll take a look at the TsReader IAMStreamSelect interface stuff.
     

    MrTechno

    Development Group
  • Team MediaPortal
  • February 27, 2011
    1,256
    511
    London
    United Kingdom United Kingdom
    Country flag
    Who still broadcasts teletext? UK stopped about two years ago.
     

    Ministerk

    Super User
  • Team MediaPortal
  • Super User
  • November 28, 2007
    970
    825
    Uppsala
    Sweden Sweden
    Country flag
    Who still broadcasts teletext? UK stopped about two years ago.
    I was curious had to google some statistics: The usage in Sweden is 3 minutes per day and person and hasn't changed since 2001, no earlier data available.
    TV channels/broadcasters with the most viewers uses teletext subtitles and not dvb.
     

    pur_berger

    Super User
  • Team MediaPortal
  • Super User
  • May 14, 2007
    1,679
    309
    48
    Vienna
    Austria Austria
    Country flag
    Can only talk for myself - and I use teletext regulary - special with splitscreen reading news next to ble bla series ;). I don't think it's that dead - and the next gen Teletext doesn't seem to have a chance of being implemented.
     

    morpheus_xx

    Lead Dev MP2
  • Team MediaPortal
  • March 24, 2007
    11,487
    7,020
    Germany Germany
    Country flag
    @offbyone I have a question regarding DotNetStreamSource and external subtitles.

    I made a test with graphstudio and compared that with MP2's graph. There is only one difference: the source. But inside graphedit the loading and rendering of external subtitles is working! Inside MP2 it does not.

    I think the subfilter checks the source filter for IFileSourceFilter (or similar) to query the current opened file. I've seen DotNetStreamSource implements this as well. Any idea about the differences and why subs are not loaded in MP2 graph?
     

    offbyone

    Development Group
  • Team MediaPortal
  • April 26, 2008
    3,981
    3,703
    Stuttgart
    Germany Germany
    Country flag
    • Thread starter
    • Moderator
    • #69
    (Currently on vacation, so a short answer must suffice).

    The DotNetStreamSource filter was build to take a single stream as source without knowing where this comes from (file, network, i-net, .iso, chained resource provider,...). In result this means external subtitle files are not seen by it - it gets a System.IO.Stream.

    What do subtitle filters with the ability for external files in the graph do? They ask the source filter for the full file path and then use their pattern to check for .sub or .srt or so. This is done then with direct file system access by the subtitle filter. When our filter is asked for the source file path - I can't remember what is returned, but most likely null ;)

    If you check page 3 of this thread - you can see that this problem is already "known" - MP2 does not support external subs yet - and we need to think about how to support external files. The xySubFilters interfaces are also on that page - IIRC it has an interface to manually load a subtitle file - this also means we need a way inside MP2 to find those files when something is played, e.g. a C# implementation to request related files for a resource, merge those with the list of embedded subtitle streams and present to the user, so when you select one, we can manually load the file (might need to be mounted via Dokan - but better if we could use a stream here as well to keep away from the Dokan dependency).

    I can't remember if we concluded that this filter breaks dxva. But if we plan to use it, it also has interfaces to get the rendered sub as image so we can mix it in the mp2 UI as overlay? But that's already a new topic.
     

    aspik

    Development Group
  • Team MediaPortal
  • April 14, 2008
    1,384
    556
    Hi offbyone,

    are they any chances to convince you to add support for external subs? Clearly you know the most about how can it be implemented :) If I could help you in any way, I would, but I don't know how... I could offer to help/take over the task with the integration of SubtitleDownloader, but as you already said, this is the easiest part and firstly MP2 has to be able to "see" and play the subtitles.

    PS: of course after your return from your vacation!! ;)
     

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

    OP Similar threads Forum Replies Date
    M General TVE 3.5 VS2019 - build discussion TV Engine 50
    ge2301 Discussion Thread Nereus 11
    ge2301 MP2.2 Pre-Release Discussions General 28
    C Telenet analog-to-digital switch -- manually finding and inputting DVB-C channels in Mediaportal2 General 0
    W Not finding/matching new series - thetvdb issue? My TVSeries 3
    morpheus_xx [Help Me!] Where can I find source code for MPUrlSourceSplitter? Developer Discussions 3
    F [solved] Could not find the MediaPortal.Common.Logging.ILogger service after upgrading from 2.2.2 to 2.2.3 General 2
    joecrow [solved] Can't find Series (Animals with Cameras) My TVSeries 4
    Jean-Christophe MP 2.2 - Where can I find Movies NOT imported (and why??) ? General 13
    Terra [solved] MP TV Server cannot find any channels anymore, DVB viewer works Installation, configuration support 8
    N [fixed] Where do I find radio programmes I have recorded MediaPortal 2 1
    P Mediaportal 2 client can't find TV server General 3
    D Downloading EPG XML file: Installation, configuration support 0
    vuego themoviedb.org - Covers downloaded in the wrong language Moving Pictures 8
    horned_reaper [solved] When playing music Fanart does not appear immediately after downloading Fanart Handler 272
    caveman [solved] Cannot download new version My TVSeries 5
    D [solved] Movie artwork download stopped working Submit: Bug Reports 9
    S myemulators kein download mehr Plugins & Erweiterungen 0
    Mainhattan Olli [solved] Download MP 2.2.3 Allgemeines Support- und Diskussionsforum 3
    F EPG Buddy download Plugins & Erweiterungen 1
    high [Evaluate] MP Extension Manager can't download HTTPS links MediaPortal 1 38
    S Tote Download Links bei den Plugins Plugins & Erweiterungen 3
    N Skins to download separately MediaPortal 1 Talk 5
    G Splash screen option pack does not download. StreamedMP 8
    Similar threads
























    Top Bottom