Kodi Community Forum
[RELEASE] Artwork Downloader - Skin support - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32)
+--- Forum: Skinning (https://forum.kodi.tv/forumdisplay.php?fid=12)
+---- Forum: Skin helper addons (https://forum.kodi.tv/forumdisplay.php?fid=300)
+---- Thread: [RELEASE] Artwork Downloader - Skin support (/showthread.php?tid=115682)

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31


[RELEASE] Artwork Downloader - Skin support - Martijn - 2011-11-28

Artwork Downloader has some build-in script command functionality that can be used by skinners.

EDEN11.0 ONLY!
Version 1.0.0 and higher.

FRODO12.0 ONLY!
Version 12.0.0 and higher.
Changes in Frodo needed:
use of:
PHP Code:
dbid=$INFO[ListItem.DBID
depricated:
PHP Code:
medianame=$ESCINFO[ListItem.TVShowTitle]
medianame=$ESCINFO[ListItem.Title]
mediapath=$ESCINFO[ListItem.Path

This thread:
This thread is meant question from skinners only!
To see what features are possible see the included readme or the official user thread.
If any changes are made i will make sure to let you know through this thread.

If you have any issues please let me know.


Skin integration:
how to use in skins

Offcial user thread:
http://forum.xbmc.org/showthread.php?tid=114633

Buy me a beer.
Image


- Martijn - 2011-11-28

I still have some issues concerning the correct way of file naming the artwork. So i would like some input from skinners if there are some incorrect file names used.

My question is what are the correct namin conventions used for seasonposters and where to store them? I used the ones from the wiki http://wiki.xbmc.org/index.php?title=Thumbnails

Are these still correct?


- `Black - 2011-11-28

I had one issue with the latest version concerning the settings... if the user runs the addon for the first time it's impossible to cancel unless you edit 1 setting and 'save' it. Otherwise the script will reopen the settings if you hit esc or click the cancel button. Script should use default settings so the user does not have to set something first.

The season poster naming conventions are still correct.


- Martijn - 2011-11-28

`Black Wrote:I had one issue with the latest version concerning the settings... if the user runs the addon for the first time it's impossible to cancel unless you edit 1 setting and 'save' it. Otherwise the script will reopen the settings if you hit esc or click the cancel button. Script should use default settings so the user does not have to set something first.

The season poster naming conventions are still correct.

It was intentional so they had to choose first what they want.
If they hit OK it should just save the default values.
Will look into it some more. I am open for suggestion for better way to handle it Smile

So for exmpample season01.tbn is still the one to go?
It could be that
Quote:<tvshow>/<season>/poster.jpg
is used so that why i asked. Maybe the same way for seasonbanners?
Quote:<tvshow>/seasonbanner01.jpg
<tvshow>/<season>/banner.jpg

EDIT:
and the specials?
Quote:season-specials.tbn



- Mudislander - 2011-11-28

Quote:So for exmpample season01.tbn is still the one to go?
It could be that

Quote:
<tvshow>/<season>/poster.jpg

is used so that why i asked. Maybe the same way for seasonbanners?

Quote:
<tvshow>/seasonbanner01.jpg
<tvshow>/<season>/banner.jpg

I keep all my artwork in the TVShows directory & not in "<tvshow>/<season>/poster.jpg" so therefore "<tvshow>/season01.tbn" works for me

Obvious exceptions are the "extra*" folders.


- `Black - 2011-11-28

<tvshow>/season01.tbn is correct and the way it should be.

To the settings:
If I run RunScript(script.artwork.downloader, mediatype=movie, medianame=$INFO[ListItem.Title]) for the first time, I can't simply press ok, settings will reopen... I have to enable downloading for movies, then select one of the options, otherwise it won't work. If I change any other setting first, hit ok, I have to kill XBMC because the dialog won't close anymore.

Edit (what I would like to do):
Skin setting for extra fanart and button for downloading all fanarts for movies & tvshows. Then I would like to add a button for downloading extra fanarts for a movie or tv show in the movie/tv show information dialog. All this should work out of the box so that the user doesn't have to set anything in the settings, I would like to add specific settings via attributes (which types to download, background yes/no etc.).


- BigNoid - 2011-11-28

Is it intentional that the script forces a reload skin after fanart download? Solo mode btw.


- `Black - 2011-11-28

I think that is because otherwise a multiimage control wouldn't display the new images.


- BigNoid - 2011-11-28

Well, I don't know if that is a real nice solution. DialogVideoInfo closes on a reload skin and there is no option to download extrafanart in solo mode, only fanart.jpg, so I don't think there is a need for reloadskin in solo mode.


- Martijn - 2011-11-28

@Black
When used like
Quote:RunScript(script.artwork.downloader, mediatype=movie, medianame=$INFO[ListItem.Title])
it will use the add-on settings so it expects a valid user settings file before continuing. This way the user can chose what is automaticly downloaded and set his limits before continuing. We can set defaults however what are good ones?
I can bypass the settings check when using the GUI mode because they have nothing to do with the settings.

Why do you need the separate buttons when the user can use this dialog?
Image
Quote:RunScript(script.artwork.downloader, mode=gui, mediatype=movie, medianame=$INFO[ListItem.Title])
It is DialogSelect.xml the same as Logo-Downloader uses.
BigNoid made a very nice yes/no option for it. If NO you get the dialog and when YES it will auto download.

About the extrafanart/extrathumbs. I left it out because i needed to figure out a good way to handle this using the GUI mode. It is a bit tricky (because i'm quite new to coding). It will be downloaded when it is enabled in settings and use it like the code above.

I just tried it and when only enabled tvshow posters it continued. The problem you might have is that it found some faulty setting from the previous time you installed it. So cleaning out the userdata file can help.
I agree agree it maybe better to use a yes/no button.

The settings check was added because apperently some user were not able to understand that they needed to enable something and they complained that it didn't do anything.


Will look at adding the attributes because they will be needed anyway.


- Martijn - 2011-11-28

@Black & BigNoid
When using with the GUI dialog the cached version of the artwork will be replaced (hopefully). The skin reset is needed to reload all images so the new one will show up.
In the case of Aeon Nox for example most of the images are directly retrieved from the xbmc (thumbnail)database. This will require me to do some hacking to push those images into it. I haven't got around to that and I will need to make absolutely sure we don't crash the database of users while doing this.

This actually is the same method like Logo-Downloader uses. I copied that part of the code from it (thanks ppic Smile )

Problem still exists when user scraped with XBMC without any local NFO/artwork files present they won't be picked up. That is where the database hacking must come in. Or they will have to use the built-in 'get fanart/set thumbnail' and choose the local stored file.


- `Black - 2011-12-02

I don't want to use the gui mode in my skin. I have buttons in settings where you can download e.g. landscape thumbs for the tv guide or extra fanart for all movies / tv shows if enabled. In the video info I have a custom dialog with get thumb / get fanart buttons from XBMC and additionally (if enabled) extra fanart, for tv shows also banner, logo and showthumb. Can't do this with artwork downloader or did I miss something?

So my requests are:
  • Don't force the user to configure something if not needed
  • Add attributes so skinners can run the script like they could with logo-downloader, i.e. RunScript(script.artwork.downloader,mediatype=tvshow,showthumb=landscape.jpg)

First request should be obsolete if the second is implemented because there are no settings needed.


- Martijn - 2011-12-02

`Black Wrote:I don't want to use the gui mode in my skin. I have buttons in settings where you can download e.g. landscape thumbs for the tv guide or extra fanart for all movies / tv shows if enabled. In the video info I have a custom dialog with get thumb / get fanart buttons from XBMC and additionally (if enabled) extra fanart, for tv shows also banner, logo and showthumb. Can't do this with artwork downloader or did I miss something?

So my requests are:
  • Don't force the user to configure something if not needed
  • Add attributes so skinners can run the script like they could with logo-downloader, i.e. RunScript(script.artwork.downloader,mediatype=tvshow,showthumb=landscape.jpg)

First request should be obsolete if the second is implemented because there are no settings needed.

First one is already taken care of Smile

Second one will be implemented. TV next Aired will also need this Wink
Would it be ok if you could use something like this?:
Quote:RunScript(script.artwork.downloader,mode=custom,mediatype=tvshow,showthumb=true)
or
RunScript(script.artwork.downloader,mode=custom,mediatype=tvshow,showthumb)
with multiple items
RunScript(script.artwork.downloader,mode=custom,mediatype=tvshow,extrafanart,extrathumbs)
Only specify the ones you do need.
So without the filename and it will use the standard ones or would you like to specify it your self?


- `Black - 2011-12-03

Thanks. Smile

Second & third example is absolutely fine, I think filenames should always be default, keeps things consistent. What would you like to have for tv show next aired?


- Martijn - 2011-12-03

`Black Wrote:Thanks. Smile

Second & third example is absolutely fine, I think filenames should always be default, keeps things consistent.

Think so to about filenames. That way you won't have tons of different file laying around.

Will work on it. Will give you a bump to try it out.