Colored genre on tvguide issue
#1
Code:
Hi Folks, 

I wonder if someone can help me with colored genre/category in PVR ( I use simple iptv client )
Is this only work with english language ?
Mine is french and I am not able to display colored category in the TV guide

please find below a sample of a record from my epg

  <programme start="20191127022000 +0100" stop="20191127044500 +0100" showview="" channel="C282.api.telerama.fr">
    <title>The Square</title>
    <desc lang="fr">En Suède, Christian, fringant quadragénaire pétri de valeurs humanistes, partage sa vie de père divorcé entre ses deux charmanst enfants et son travail de conservateur d'un très respecté musée d'art contemporain. La prochaine exposition de son établissement, intitulée The Square, doit faire se questionner ses visiteurs sur les notions d'altruisme et d'empathie. C'est alors qu'en pleine rue, Christian se fait voler son téléphone portable. Cet événement va peu à peu faire s'effondrer quelques une des certitudes qui guidaient la vie de Christian...</desc>
    <credits>
      <director>Ruben Östlund</director>
      <actor>Claes Bang (Christian)</actor>
      <actor>Elisabeth Moss (Anne)</actor>
      <actor>Dominic West (Julian)</actor>
      <actor>Terry Notary (Oleg)</actor>
      <actor>Christopher Laesso (Michael)</actor>
      <actor>Marina Schiptjenko (Elna)</actor>
      <actor>Elijandro Edouard (Pojken)</actor>
      <actor>Daniel Hallberg (un communicant)</actor>
      <writer>Ruben Östlund</writer>
      <guest>Josefin Asberg</guest>
      <guest>Fredrik Wenzel</guest>
    </credits>
    <date>2017</date>
    <category lang="fr">film : drame</category>
    <length units="minutes">145</length>
    <icon src="https://television.telerama.fr/sites/tr_master/files/sheet_media/media/e8ffd8b7-b3dd-4f71-b18d-6d348981eb38.jpg" />
    <country>Suède - France</country>
    <video>
      <aspect>4:3</aspect>
      <quality>HDTV</quality>
    </video>
    <audio>
      <stereo>dolby</stereo>
    </audio>
    <previously-shown />
    <rating system="CSA">
      <value>Tout public</value>
    </rating>
    <star-rating>
      <value>4/5</value>
    </star-rating>
  </programme>


Not sure which field is used by the skin to show different color. ( I bet its Category...)
Is there any xml to create /edit in order to have them match all my epg french category ?

Thanks in advance.

Rgds
Reply
#2
Checkout the readme file. It gives instructions. You need to create a mapping file.

https://github.com/kodi-pvr/pvr.iptvsimp.../README.md
Maintainer of Enigma2 PVR addon: repo, docschangelog
How to create a full debug: here
Reply
#3
(2019-12-04, 23:34)phunkyfish Wrote: Checkout the readme file. It gives instructions. You need to create a mapping file.

https://github.com/kodi-pvr/pvr.iptvsimp.../README.md

Hey,

Thanks for your help and tips....!!
After a lot of googling work I manage to understand how it works and  will provide few infos that may help others that want custom colored genre...

I am using iptv simple client with aeon nox sylvio and my epg is in french.

Here is Genre Numbers set internally by Kodi -->
0 = other/unknown
16 = moviedrama
32 = news
48 = show
64 = sports
80 = child
96 = music
112 = arts
128 = social
144 = science
160 = hobby
176 = special
192 = other/unknown
208 = other/unknown
224 = other/unknown
240 = other/unknown
256 = use genre string from the backend

Then you will have to create a genres.xml and be located here: userdata/addon_data/pvr.iptvsimple
This file should contains the info that is under category in my epg.

pleas find a quick sample of my file genres.xml 

<genres>
  <name>My Streams Genres Mappings</name>
  <genre type="16" subtype="0">film</genre> 
  <genre type="16" subtype="0">film : comédie dramatique</genre> 
   <genre type="16" subtype="0">film d'aventures</genre> 
   <genre type="16" subtype="0">film d'action</genre> 
   <genre type="16" subtype="0">film policier</genre> 
   <genre type="16" subtype="0">film : thriller</genre> 
  <genre type="16" subtype="0">film : comédie</genre>           
  <genre type="32" subtype="0">journal</genre>          
  <genre type="48" subtype="0">série policière</genre>     
   <genre type="48" subtype="0">série humoristique</genre>     
    <genre type="48" subtype="0">série d'animation</genre>     
  <genre type="64" subtype="0">magazine sportif</genre>     
  <genre type="80" subtype="0">magazine jeunesse</genre> 
   <genre type="80" subtype="0">jeunesse : dessin animé</genre> 
  <genre type="96" subtype="0">clips</genre>            
   <genre type="64" subtype="0">sport : football</genre>            
      <genre type="64" subtype="0">sport : multisports</genre>            
      <genre type="64" subtype="0">football</genre>            
  <genre type="144" subtype="0">documentaire</genre>          
    <genre type="144" subtype="0">documentaire : société</genre>          
  <genre type="160" subtype="0">divertissement</genre>     
    <genre type="160" subtype="0">divertissement-humour</genre>     
    <genre type="160" subtype="0">jeu</genre>     
  <genre type="32" subtype="0">magazine d'information</genre>     
</genres>

So basically all genre type number is associated with a color as per the skin. (here all my movie genre with 1type=16 will have the color of moviedrama )

Dont know if its clear but hope it can help someone.

++
Reply
#4
Hello,
I'm new to kodi and PVR simple client and I use telerama EPG as well, I would like colored "star rating", do you think it is possible?
Do you know what the "blue star" means in EPG and how to activate it?
Thanks for help
Reply
#5
The blue star means it is new program -- e.g., first time being aired.
Reply
#6
thanks for your reply, I found out myself by greping the source.
I think I'm going to ¨make" a small sed script to first remove Premiere and New from the xmltv.xml file and then add new or premiere again according to the star rating. It's only a dirty workaround I know but as I'm not a programmer I have to find a solution before the developers include that very useful feature.
Have a nice day
Reply
#7
Looking into doing something like this myself.
Very informative thread, thanks!
Reply
#8
Hello
I wrote a tiny bash script that works but I don't know how to send it on this forum that rejects my reply certainly for security reason.
Can you help please
Reply
#9
here it is, run by cron at startup on my xubuntu 20.04
Now the blue star on TV guide shows program better rated than 2/5
I hope it helps somebody and give an idea for a new feature officially supported
https://paste.kodi.tv/dojureyoxi
Reply

Logout Mark Read Team Forum Stats Members Help
Colored genre on tvguide issue0