[EPG] Use data-provided value for #TV.Guide.thumb texture? (1 Viewer)

Blue Lightning

Portal Member
October 8, 2011
49
52
Australia Australia
Summary:
Have #TV.Guide.thumb use a provided program-specific image if available

Area:
TV Guide / xmlTV

Description:

Currently #TV.Guide.thumb defaults to "defaultVideoBig.png". Then if that program's channel has an image it'll use that image (mpdirectory/thumbs/tv/logos/CHANNEL.png). It would be nice if this value could also check the TV Guide data, and if an "<icon>" is provided with a "src" attribute, set that URL (or local/network path) as the image. So priority order would be: (highest to lowest) Data-provided image URL/path for this specific airing, channel image for the channel the airing is on, defaultVideoBig.png
(I'm unsure if MediaPortal's built-in thumbnailer from the video file also hooks into #TV.Guide.thumb but in my opinion the priority order there would be: Data-provided image URL, MP generated thumb from video file, channel image, defaultVideoBig.png)

As far as I can tell most of this would already work, but that particular xmltv data isn't stored in the database, and isn't assigned as the #TV.Guide.thumb
Substituting that value with another such as #TV.Guide.classification (where <rating> has a value with the URL) in the guide data correctly shows the image (if you replace #TV.Guide.thumb in the TV guide skin file).

Two important changes that may be needed with GUITextureManager.cs
- It only accepts "http:" prefix as a valid web address (line 161). It should be updated to accept "https:" too.
- When a URL is used as a <texture> value it downloads the image and temporarily places it in "C:\ProgramData\Team MediaPortal\MediaPortal\thumbs" with a filename like "MPTemp0.jpg". The file is deleted when MediaPortal closes. For these URLs (TV program images) it may reduce remote site load to cache them in "thumbs\tv\Shows", either by time (1 week?) or a size limit.


Here are two examples of how it could look (with images in an edited skin file and data) in DefaultWideHD's TV Guide:

 

Blue Lightning

Portal Member
October 8, 2011
49
52
Australia Australia
Further research: This would also need to apply to #TV.Scheduled.thumb, and #TV.RecordedTV.thumb


I want to help develop a patch for this but I can't run the code. Mediaportal compiles (and runs) but refuses to see the TV server and I'm not sure how to fix that. It might be a longshot but could I provide some untested patches and then a Mediaportal dev could test and fix up any errors?
 

Blue Lightning

Portal Member
October 8, 2011
49
52
Australia Australia
It turns out it can't see the TV server because I wasn't running it (didn't realise it wasn't part of the sln). Attempting to run the SetupTv project in the TvLibrary sln gives me this in SetupTv.log http://pastebin.com/raw/7mQH6ick
It says "No connection could be made because the target machine actively refused it 192.168.184.128:31456" but the MySQL service is running (the MP tables and user exist), I've added the loopback and the firewall is disabled. I haven't set up TV server without the MP installer before, could I be missing something?
 

Blue Lightning

Portal Member
October 8, 2011
49
52
Australia Australia
This is C:/ProgramData/Team MediaPortal/MediaPortal TV Server/Gentle.config file http://pastebin.com/6uBR4jHX
I can't get to the stage of running the TV Server config GUI so that gentle.config is the only place I've done any configuration for the TV Server. The Server name in the DefaultProvider connectionString is the name of the local machine (a Windows 10 (1607) Virtual Machine). The IP on Ethernet0 is 192.168.184.128 and the IP I gave the loopback adapter is 192.160.0.100 (both with subnet mask 255.255.255.0)
 

Blue Lightning

Portal Member
October 8, 2011
49
52
Australia Australia
I had no TV/Radio entry due to no TvPlugin.dll but I've now compiled it and copied it into the /plugins/windows folder, along with a bunch of other tasks. I can now get the server to start and SetupTv to let me configure it and the client's configuration.exe to connect to it (goes green like yours), but when trying to view the TV guide in MP it times out and asks to confirm server name. This is what the client log has http://pastebin.com/raw/z6bjuGZn
 

Blue Lightning

Portal Member
October 8, 2011
49
52
Australia Australia
It turns out Gentle.Provider.MySQL.dll was missing from the client (even though it had one for SQLServer) so I copied it over from the server and now it works.
Thank you for all your help @ajs , getting a default MP running without an installer was a lot harder than I thought it would be. Hopefully now I can get some code going without too much trouble.
 

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

OP Similar threads Forum Replies Date
toricred Using TMM, How to Stop Importer From Going to The Movie Database for Data General 1
D EPG No Data General Support 2
D [solved] EPG Data off by -20 hours? General 10
W Setup data connection - mySQL connection failed Installation, configuration support 1
emphatic How to get the right data for War Of The Worlds? My TVSeries 1
T Freeview EPG-Anyone know what channel sends the guide data? Electronic Program Guide 10
F No data in "File Details" Moving Pictures 2
G Newb trying MP2, trouble with guide data General 5
J EPG data recheck? Feature Requests 0
B [solved] Where is the satellite data now? General 10
T No data available using xmltv and mc2xml xmlTV 2
M Importing movie data General 38
T Media Portal 2 EPG data missing General 16
P Multiple clients - share resume/watched data General 1
azzuro [WiP] Providing most of 3rd part tools as nuget MediaPortal 1 13
ajs [fixed] 5022: Improving the MPE Installer, providing nicer GUI :) MediaPortal 1 42
ajs [fixed] 5015: Improving the MP1 installer, providing nicer GUI :) MediaPortal 1 138
P No TV provider available (yet)? General 1
morpheus_xx Interest in a DVBLink / TV Mosaic SlimTV provider? MediaPortal 2 18
D "attempt to index local `zf' (a nil value)" General Support 0
G 1.23.0 Wrong return value for refresh rate / DRR Bugreports 4
D 'IPTV' is not a valid value for LineupTypes Electronic Program Guide 1
A "IRQL unexpected value" error General 4
CyberSimian What values is the VISIBLE tag supposed to accept? MediaPortal 1 11
Top Bottom