xmltv - Mapping of XML tags to MP2 fields? (1 Viewer)

pclemins

Portal Member
October 15, 2015
5
0
47
Home Country
United States of America United States of America
Hello all...

I'm trying to enhance some MP2 skins to display some additional information in the TVGuide, and one piece I'd like to display is the subtitle / episode name of the show as you scroll over it. However, I can't seem to find the correct data binding string. I'm guessing it's CurrentProgram.<something>, but EpisodeName shows up blank as does a number of permutations of SubTitle, Sub-Title, etc. I'm not sure this is a question of what the appropriate name for that data binding is... I think it's more a matter of the xmltv plugin not importing the <Sub-title> tag from the xml file. Is there someplace where the mapping from xml tag to MP2 TV DB is documented so we can use that information in skins? Or... alternatively, is the source for the xmltv plugin in the core MP2 git repo? I'm happy to play around in there if need be, but I'm having trouble finding the source code.

Best,
Pat
 

Lehmden

Retired Team Member
  • Premium Supporter
  • December 17, 2010
    12,552
    3,934
    Lehmden
    Home Country
    Germany Germany
    Hi.
    The XMLTV plugin is Part of the TV Engine so you will find the source there somewhere. There already is a field "episodeName" in the database that holds the episodes title of any program this data is available by your EPG source. And this will be displayed in EPG and recordings view so what else do you want?
    If you need, I can later show some screenshots how this looks inside MP2....
     

    pclemins

    Portal Member
    October 15, 2015
    5
    0
    47
    Home Country
    United States of America United States of America
    Let me see if I can lay out the problem with some more technical details. Here's a code snipet from the tvguide.xml that I imported using xmltv:

    <programme start="20151017210000 -0400" stop="20151017220000 -0400" channel="I3.1.44991.schedulesdirect.org">
    <title lang="en">Code Black</title>
    <sub-title lang="en">Pre-Existing Conditions</sub-title>
    <desc lang="en">During a 36-hour shift, the doctors are faced with a distraught woman whose sons were in a devastating car accident; Mario makes Angus perform an unnecessary operation.</desc>

    Note the <sub-title> tag and that this xml was generated using mc2xml and schedules direct json.

    Here's a snippet of what I modified (bolded here for emphasis) in my skin's ProgramInfoSlim.inc in C:\Program Files (x86)\Team MediaPortal\MP2-Client\Plugins\SlimTv.Client\Skin\Titanium\screens

    <Label Grid.Row="1" Grid.Column="1" Grid.ColumnSpan="3" x:Name="Description" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
    Wrap="True" Scroll="Auto"
    Content="{Binding Path=CurrentProgram.episodeName}"
    Color="{ThemeResource TextColor}"/>

    And here's how it looks (below). Clearly, the skin modification is being read in as the description is gone, but CurrentProgram.EpisodeName returns no information, even though it's there in the schedule's direct XML in the sub-title tag. I tried it with capital and lower case .episodeName.

    upload_2015-10-15_15-56-17.png


    Does that better describe what I'm trying to do?

    Thanks!
    Pat
     

    morpheus_xx

    Retired Team Member
  • Team MediaPortal
  • March 24, 2007
    12,073
    7,459
    Home Country
    Germany Germany
    Hi Pat,

    did you see this thread already? https://forum.team-mediaportal.com/threads/extending-slimtv-plugin-series-information.132246/

    The changes are already contained in this development snapshot: https://forum.team-mediaportal.com/threads/mediaportal-2-weekly-snapshot-2015-10-03.132293/ (official SR'15 Update 1 does not contain this!).

    Until this version the episode infos where not included in the Program items and thus not displayed. To make this working completely, the EPG sources would need to deliver Season / Episode numbers. This is unfortunately only provided by few sources. I personally use https://forum.team-mediaportal.com/threads/webgrab-plus-howto.127828 (german thread), which contains grabbers for several online sources.
     

    pclemins

    Portal Member
    October 15, 2015
    5
    0
    47
    Home Country
    United States of America United States of America
    I did not... thanks!

    Schedules Direct has the episode numbers and names, but I'm not convinced the xmltv plugin is importing them fully. The only web grabber we have for the US is www.imdb.com that I've found, and while the website is good, the TV listings are less so and include only minimal info. :(

    But, let me download the dev snapshot and poke around... I'll post again when I have further news... it looks promising... at least I'll know the correct data bindings after looking at it.

    Thanks all for now!
    Pat
     

    Users who are viewing this thread

    Top Bottom