video duration
#1
Hello,
Until now, to set the duration of the videos of my addons I used listitem.setInfo('video',{'duration':7500}) or vInfoTag.setDuration(7500) depending on the version of Kodi, but in both cases the duration was always an integer that represents the number of seconds.
Now I see that in some skins this duration is not indicated correctly, they read the hours as minutes (in this case 7500s shows it as 2 minutes).

I have also seen that since Kodi 18 ListItem.Duration(format) is supported, and that is what the skins are reading, but I don't know how to pass that data to them from my addon.

Can you help me?
Reply
#2
kodi 20+ use infoTagVideo https://alwinesch.github.io/group__pytho...c55dcbd60e
kodi <20 use setInfo https://alwinesch.github.io/group__pytho...90e8edbf18

both are in seconds, if the skin is not showing properly then the skin should be looked at, the change to seconds was at v15
Reply
#3
Thank you for your answer.
I'm ashamed to admit it, but it was my mistake. I was adding the duration in minutes instead of seconds.
Reply
#4
(2024-01-09, 19:51)caperucitaferoz Wrote: Thank you for your answer.
I'm ashamed to admit it, but it was my mistake. I was adding the duration in minutes instead of seconds.

typos happen, no big deal
glad you got it
Reply
#5
(2024-01-09, 19:51)caperucitaferoz Wrote: Thank you for your answer.
I'm ashamed to admit it, but it was my mistake. I was adding the duration in minutes instead of seconds.
Don't feel bad.  When I was writing the TV show scraper I put the duration in as minutes as well.  I didn't even notice for weeks during testing until some TV episode had a duration more than an hour and I finally noticed it has been showing me something that looked like the duration but wasn't.
Reply

Logout Mark Read Team Forum Stats Members Help
video duration0