Dis90 / plugin.video.discoveryplus

discovery+ add-on for Kodi
65 stars 13 forks source link

Better Posters in Discoveryplus.in #54

Closed nikhilk0 closed 3 years ago

nikhilk0 commented 3 years ago

Currently the image which is shown as poster is just a cut-off thumbnail/fanart. Discoveryplus.in is using "kind" : "poster" instead of 'poster_with_logo' (other countries might be using this).

To get the correct poster, I've replaced image['attributes']['kind'] == 'poster_with_logo' with image['attributes']['kind'] in ['poster', 'poster_with_logo'].

Dis90 commented 3 years ago

Both poster and poster_with_logo is used correctly in discovery+ US. Maybe better way would be:

if helper.d.locale_suffix == 'in':
    if image['attributes']['kind'] == 'poster':
        poster_image = image['attributes']['src']
else:
    if image['attributes']['kind'] == 'poster_with_logo':
        poster_image = image['attributes']['src']

Can you check that Discoveryplus.in really has kind poster_with_logo? If I don't remember wrong it is possible that Kodi is showing thumbnail as poster.

nikhilk0 commented 3 years ago

Just checked again. Discoveryplus.in don't have 'poster_with_logo' as kind at all. They're using kind 'poster' for posters with logos and kind 'portrait' for posters without logos although not every title has 'portrait' kind. Here's couple of pages as example: https://paste.kodi.tv/agadijelow https://paste.kodi.tv/iqohikirul

If I don't remember wrong it is possible that Kodi is showing thumbnail as poster.

Maybe Kodi is falling back to thumbnail because kind 'poster_with_logo' doesn't exist.

Dis90 commented 3 years ago

Thanks for checking. Please try with latest version :)

nikhilk0 commented 3 years ago

Much better. Thanks.