Newbie Help: GetImageHash
#1
Hello Kodi Python experts.

I'm attempting to write my first add-on, and learning python as I go. I've run into a thumbnail image issue that I can't seem to figure out.

I'm attempting to set thumbnails for items from the Internet Archive (for MAME). They have a great source of free and complete data available.

I'm trying to use images from this 'base' URL:
http://ia801807.us.archive.org/zipview.p...%2Fsnap%2F

Example 1941.png

But when I set it as a thumbnail I get the debug
DEBUG: GetImageHash - unable to stat url

Assuming it's a problem with my code, I tried a different source URL just to test:
https://raw.githubusercontent.com/celso/...ame/snaps/

Example: 1941.png

URL #2 does work, but URL #1 doesn't. Are there specific limitations on using images from online sources? Is there any workaround for this?

Thanks!
Reply
#2
maybe you need getCacheThumbName , it returns the hashname for kodi thumbnail storage.

Code:
def xbmc.getCacheThumbName    (         path    )    
getCacheThumbName(path)--Returns a thumb cache filename.

path : string or unicode - path to file

example:
- thumb = xbmc.getCacheThumbName('f:\videos\movie.avi')
http://romanvm.github.io/xbmcstubs/docs/...694a7b9b3f
Image Lunatixz - Kodi / Beta repository
Image PseudoTV - Forum | Website | Youtube | Help?
Reply
#3
Thanks Lunatixz, but I don't think thats quite what I'm looking for.

After doing some reading, it seems there's likely a problem with the header response from the internet archive zipview URL.

Some additional info at this thread:
http://forum.kodi.tv/showthread.php?tid=219802

I'm wondering if there's a way to spoof the header response to placate Kodi into getting the image?
I tried to use a pipe: | and add a last modified date, but that didn't seem to do the trick. I'm not sure if it's because I'm not formatting it correctly or if this simply isn't possible. Any help on this would be greatly appreciated.

Thanks!
Reply

Logout Mark Read Team Forum Stats Members Help
Newbie Help: GetImageHash0