[RELEASE] Texture Cache Maintenance utility
Just so you get an idea of how it should work... this is my system, processing a single movie (Zombieland), with all files in a single folder, which finds and assigns the locally stored logo and clearart images (only fanart and poster are initially assigned to the movie):

This is the movie as it initially exists in the media library - only fanart and poster artwork, both using "movie-name" prefix:
Code:
[email protected]:~$ ./texturecache.py jd movies zombieland
[
  {
    "art": {
      "fanart": "image://nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-fanart.jpg/",
      "poster": "image://nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-poster.jpg/"
    },
    "file": "nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip].mkv",
    "label": "Zombieland",
    "movieid": 667,
    "title": "Zombieland"
  }
]

These are the files in the single movie folder - ie. what XBMC can "see" by directly browsing the folder. Note the clearlogo and clearart artwork, not using movie-name prefix, which are not present in the media library:
Code:
[email protected]:~$ ./texturecache.py directory nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland
FILE: nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/clearart.png
FILE: nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/logo.png
FILE: nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-fanart.jpg
FILE: nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-poster.jpg
FILE: nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip].mkv
FILE: nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip].nfo

mklocal.py will now scan the local folder and match the artwork it finds with what is specified by the movie library, making corrections as necessary (output at the end - in this case, the addition of clearlogo and clearart - which needs to be fed into "texturecache.py set"):
Code:
[email protected]:~$ ./texturecache.py jd movies zombieland | tools/mklocal.py --readonly --singlefolders --local /freenas/media --prefix nfs://192.168.0.3/mnt/share/media --artwork fanart poster clearlogo clearart --output -v
Current configuration:

  Local Path    : /freenas/media/
  Alt Local     : Not specified
  XBMC Path     : nfs://192.168.0.3/mnt/share/media/
  Read Only     : Yes
  Dry Run       : No
  Single Folder : Yes

  Artwork       : fanart       as fanart.[png,jpg]
                  poster       as poster.[png,jpg]
                  clearlogo    as logo.[png,jpg]
                  clearart     as clearart.[png,jpg]

  Checking      : Not Specified

##DEBUG## mediatype [movie]; mediatitle [Zombieland]
##DEBUG##   mediafile is [nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip].mkv]
##DEBUG##   local root name would be [/freenas/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]]
##DEBUG##   artwork type [fanart] known by XBMC as [nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-fanart.jpg]
##DEBUG##     [fanart    ] Found pre-existing local file:           /freenas/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-fanart.jpg
##DEBUG##     [fanart    ] Converting local filename to XBMC path:  nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-fanart.jpg
##DEBUG##     [fanart    ] No library change required, keeping:     nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-fanart.jpg
##DEBUG##   artwork type [poster] known by XBMC as [nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-poster.jpg]
##DEBUG##     [poster    ] Found pre-existing local file:           /freenas/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-poster.jpg
##DEBUG##     [poster    ] Converting local filename to XBMC path:  nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-poster.jpg
##DEBUG##     [poster    ] No library change required, keeping:     nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/Zombieland (2009)[BDRip]-poster.jpg
##DEBUG##   artwork type [clearlogo] known by XBMC as [None]
##DEBUG##     [clearlogo ] Found pre-existing local file:           /freenas/media/Video/MoviesHD/Zombieland/logo.png
##DEBUG##     [clearlogo ] Converting local filename to XBMC path:  nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/logo.png
##DEBUG##     [clearlogo ] Changing library value to:               nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/logo.png
##DEBUG##   artwork type [clearart] known by XBMC as [None]
##DEBUG##     [clearart  ] Found pre-existing local file:           /freenas/media/Video/MoviesHD/Zombieland/clearart.png
##DEBUG##     [clearart  ] Converting local filename to XBMC path:  nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/clearart.png
##DEBUG##     [clearart  ] Changing library value to:               nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/clearart.png

[
  {
    "items": {
      "art.clearart": "nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/clearart.png",
      "art.clearlogo": "nfs://192.168.0.3/mnt/share/media/Video/MoviesHD/Zombieland/logo.png"
    },
    "libraryid": 667,
    "type": "movie",
    "title": "Zombieland"
  }
]
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
 
Thread Rating:
  • 17 Vote(s) - 4.76 Average


Messages In This Thread
RE: [RELEASE] Texture Cache Maintenance utility - by Milhouse - 2014-01-03, 00:47
Crash on Gotham on OS X - by desepticon - 2014-05-29, 17:57
Cleaning - by AleisterHH - 2018-05-28, 22:03
RE: Cleaning - by Milhouse - 2018-05-28, 22:16
qax genre not updated - by Just-Me_A-User - 2018-06-12, 22:06
RE: qax genre not updated - by Milhouse - 2018-06-12, 23:40


Logout Mark Read Team Forum Stats Members Help
[RELEASE] Texture Cache Maintenance utility4.7617