Kodi Community Forum
Artwork Downloader - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Program Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=151)
+---- Thread: Artwork Downloader (/showthread.php?tid=114633)



RE: Artwork Downloader - Milhouse - 2015-07-09

On texturecache,py you can create a log with @logfile=c:\tc.log. There's no log for mklocal.py apart from what you see on the screen, but if you add "--dryrun" then it shouldn't make any changes to the file system (changes to the media library only happen if you run the output from mklocal.py through "texturecache.py set").


RE: Artwork Downloader - Dave the Minion - 2015-07-09

(2015-07-09, 01:23)Glorious1 Wrote: You're right, it doesn't make a difference. So just name it disc.png and clearart.png, tell Artwork Downloader to import it to Kodi, and you're done. I don't see what the big problem is. Kodi does not recognize the extra artwork automatically, so people who download their own local artwork still need to use AD.

The difference is I don't need to run Artwork Downloader to scan through my entire library (over 10,000 items) just to add 3 pieces of artwork to 1 new movie. So I do it manually. It's my choice to do it manually and I enjoy doing it manually. But that's the reason I need files Kodi will recognize as well as files Artwork Downloader will find. To combine the 2 into 1 is the goal of my first post. Still working on that solution for myself which I hope to share with others and who knows if it can be worked into the add-on itself.


RE: Artwork Downloader - diedrichg - 2015-07-16

Hello authors, I am having an issue in Isengard 15.0 RC2 where I am unable to update the Thumb because the "Thumb 16:9" menu item is not the same as Thumb which is the image that is being displayed. You can see this by viewing Movies and setting the view to List. I'm not seeing a nice, large poster of the movie and am rather seeing some obscure image or movie clip.


RE: Artwork Downloader - masinad - 2015-07-22

(2013-05-25, 06:54)Milhouse Wrote: @Ghostdivision - do you have cron?

There's probably other scripts that can automate add-on execution but I've added such support to Texture Cache Maintenance utility:

Code:
cron@12:00: ./texturecache.py exec script.artwork.downloader silent=true mediatype=movie
cron@12:30: ./texturecache.py exec script.artwork.downloader silent=true mediatype=tvshow
and subsequently pre-loading your cache won't hurt either:
Code:
cron@01:00:./texturecache.py c video

Alternatively, you can write a script that is able to detect when each AD run has finished so that calls to AD can be run serialised without any delay.

Here's an example bash script that I use which initiates a video library scan, followed by calls to AD for movies then tvshows, and finally the texture cache is pre-loaded if any new items have been added (either a full library pre-load or just incremental depending on whether AD has added any new items).

Code:
#!/bin/bash
LOGFILE=/var/log/xbmcscan.log

function _log {
  [ -z "$1" ] && echo >> $LOGFILE || $PRINTF "$(date +"%Y-%m-%d %H:%M:%S"): $1\n" >> $LOGFILE
}

function waitForAD {
  XBMC="/mnt/share/xbmc/rpi1/Storage/.xbmc"
  XBMC_LOG="${XBMC}/temp/xbmc.log"
  AD_REPORT="${XBMC}/userdata/addon_data/script.artwork.downloader/downloadreport.txt"

  tail -fn0 "${XBMC_LOG}" | \
    while read line; do
      if [ -n "$(echo "$line" | grep "Artwork Downloader: script stopped")" ]; then
        kill $(ps -o pid,args | grep -v grep | grep "tail -fn0 ${XBMC_LOG}" | awk '{ print $1 }') 2>/dev/null
        break
      fi
    done

  echo $(grep -e '^ - Total Artwork: 0$' "${AD_REPORT}" | awk '{ print $4 }')
}

NEWITEMS=0

_log "$(/mnt/share/bin/texturecache.py update 2>/dev/null)"
VSCAN="$(/mnt/share/bin/texturecache.py vscan 2>/dev/null)"
RESULT=$?
_log "$(echo "${VSCAN}")"

/mnt/share/bin/texturecache.py exec script.artwork.downloader silent=true mediatype=movie
NEWITEMS=$(($NEWITEMS + $(waitForAD "movies")))
/mnt/share/bin/texturecache.py exec script.artwork.downloader silent=true mediatype=tvshow
NEWITEMS=$(($NEWITEMS + $(waitForAD "tvshows")))

if [ ${NEWITEMS} -ne 0 ]; then
  _log "New AD items downloaded - performing a full cache pre-load"
  _log "\n$(/mnt/share/bin/texturecache.py c movies 2>/dev/null)"
  _log "\n$(/mnt/share/bin/texturecache.py c tvshows 2>/dev/null)"
elif [ ${RESULT} -ne 0 ]; then
  _log "No new AD items - performing a partial cache pre-load"
  _log "\n$(/mnt/share/bin/texturecache.py lc movies 2>/dev/null)"
  _log "\n$(/mnt/share/bin/texturecache.py lc tvshows 2>/dev/null)"
else
  _log "Skipping cache pre-load - no new artwork items added"
fi

touch /tmp/texturecache.lastrun

/mnt/share/bin/texturecache.cfg:
Code:
xbmc.host=192.168.0.202
userdata=/mnt/share/xbmc/rpi1/Storage/.xbmc/userdata
cache.castthumb = yes
logfile=+/tmp/texturecache.log
lastrunfile=/tmp/texturecache.lastrun

I run this script automatically on a remote FreeNAS system that I rsync new media to, so it only runs once the new media has hit the remote server - a Raspberry Pi running OpenELEC with its /storage partition mounted on NFS is connected to the NAS.

This gives me some errors. some1 help me to fix this?

Code:
htpc@htpc-desktop:~/Kodi_scripts/Bash/Auto.call.scripts$ sudo ./Organice.library.v2.sh
./Organice.library.v2.sh: line 5: 2015-07-22 20:47:25: Rescanning library...\n: command not found
./Organice.library.v2.sh: line 5: 2015-07-22 20:47:52: Skipping cache pre-load - no new artwork items added\n: command not found



RE: Artwork Downloader - Milhouse - 2015-07-22

There's an error in the script, add PRINTF=printf at line 3. You also need to change the various filepaths to reflect your own system - this was an example/proof of concept (not particularly well written, I admit) based on my system at the time, so paths such as /mnt/share/bin/texturecache.py won't work on your system. Blindly copying the script won't work, you really need to understand what it's doing and adapt it to your own set up.


RE: Artwork Downloader - masinad - 2015-07-22

Thank you, got it working now Smile

--EDIT--

Maybe you will find time and make an update for your old script NodAngel.
Is really useful, using this script whit xbmc.callbacks2 script.

Also thank you Blush


RE: Artwork Downloader - kazak - 2015-07-22

In some cases, AD doesn't grab the most downloaded, highest rated poster. It some cases, it downloads the poster with 0 votes and almost no downloads. Why is it doing this and how can I change this behavior? I would like all my other addons and media clients using the same posters (most common ones) without any issue.


RE: Artwork Downloader - Nukles - 2015-07-27

Hi all. After having to re-install Kodi from the start, my Artwork Downloader seems not to be working properly anymore. Previously after installing AEON MQ5, I got all the Logos/Clearart and Disc Arts downloaded automatically for all the Movies and TV Shows in my collection. Now this doesn't happen anymore and I don't know what I am doing wrong...

In order to get the Disc Art and Logo/Clearart, I have to do the following:
- For each Movie / TV Show
- Select the Movie
- Click on "C" (context menu)
- Click on "Get Logo/Clearart GUI Mode"
- Select the favourite Disc Art or Logo

So it's a manual process that needs to be done for each movie.

Is there a way to do it once and for all for all movies in my collection? I tried to remove the Movie Source and re-add it, selecting Themoviedb as a scraper, but it didn't work.

Thanks!


Re: RE: Artwork Downloader - Frozin - 2015-07-27

(2015-07-27, 08:06)Nukles Wrote: Hi all. After having to re-install Kodi from the start, my Artwork Downloader seems not to be working properly anymore. Previously after installing AEON MQ5, I got all the Logos/Clearart and Disc Arts downloaded automatically for all the Movies and TV Shows in my collection. Now this doesn't happen anymore and I don't know what I am doing wrong...

In order to get the Disc Art and Logo/Clearart, I have to do the following:
- For each Movie / TV Show
- Select the Movie
- Click on "C" (context menu)
- Click on "Get Logo/Clearart GUI Mode"
- Select the favourite Disc Art or Logo

So it's a manual process that needs to be done for each movie.

Is there a way to do it once and for all for all movies in my collection? I tried to remove the Movie Source and re-add it, selecting Themoviedb as a scraper, but it didn't work.

Thanks!

Go to programs and click on artwork downloaded and it will download all art


RE: Artwork Downloader - Dave the Minion - 2015-07-31

I am having a new problem and I'm not sure if it's AD related or an issue with the Universal Scraper.

When I scrape a new movie into my database when I've already created all the local extra art I want (logo, clearart and disc) AD would easily allow me to manually add these arts and when I accessed the artwork options I only had 2; local art or browse:

When I run AD in automatic mode the proper local art is added no problem.

Now when I go to quickly add these arts I've given a ton of options in these arts that all seem to be posters and banners and others things that are not the proper types of art let alone anything local. Is it AD doing something odd, or, as I susspect, the Universal Scraper populating thumbnail fields incorrectly?

Thanks!


RE: Artwork Downloader - frank75 - 2015-08-04

Started artwork downloader and downloaded almost everything.
In the Transparency i cant find the folder where this is downloaded. Also search C: and D: without finding anything.
Anybody knows where these files are filed?

Thx in advance


RE: Artwork Downloader - Namoi - 2015-08-04

They should be downloaded in your library AFAIK.


RE: Artwork Downloader - rmrector - 2015-08-05

@frank75

Most artwork is downloaded straight to the thumbnail cache under 'userdata/Thumbnails/', probably '%APPDATA%/Kodi/userdata/Thumbnails/', while extrafanart and extrathumbs go in the folders 'extrafanart'/'extrathumbs' in the movie/TV show folder alongside the videos.


Re: RE: Artwork Downloader - Milhouse - 2015-08-05

(2015-08-05, 01:05)rmrector Wrote: Most artwork is downloaded straight to the thumbnail cache under 'userdata/Thumbnails/', probably '%APPDATA%/Kodi/userdata/Thumbnails/',

This is not correct. If AD is downloading artwork it will be placed alongside your movies - artwork is never written directly into the Thumbnails folder by any add-on (including AD).


RE: Artwork Downloader - rmrector - 2015-08-05

That isn't what I said.

Artwork Downloader adds the artwork URLs into the database, and when a skin tries to display that artwork, Kodi downloads it and adds it to the texture cache. Most artwork doesn't get downloaded anywhere else, except extrafanart/extrathumbs.

Edit: unless you enable 'use local files', in which case it works as Namoi and Milhouse have said.