Posts: 361
Joined: May 2010
Reputation:
1
2017-10-09, 19:41
(This post was last modified: 2017-10-09, 19:42 by ZERO <ibis>.)
It does not work, in order to support reading from extrafanart folders you must point to the directory directly. This is from the first implementation of extrafanart folders from years back. Later on some scrappers support pulling images directly into the database but such a feature is not supported for anime. The only way to have extrafanart for that is to add it yourself.
There is also a problem with the Image_Background when used at the episode level. Because the method uses ListItem.Art(fanart) it returns "Returns the fanart image of the currently selected item", as a result if you select the back button in the episode view it will not load the correct image (I assume it will load the fall back image in this case if configured). To correct this the variable Fanart.Image must be used in it's place as that will load " Fanart image for the parent TV Show ". When using Fanart.Image instead of Image_Background the content loads as expected. I can modify Image_Background (adding at line 170) to have the following line added for compatibility if you want:
<value condition="Control.IsVisible(513)">$INFO[Fanart.Image]</value>
I just wanted to avoid modifying any stock includes unless explicitly told to do so.
Unfortunately, it is impossible for me to test any other way of loading extrafanart images. From what I see many of those fanart download mods that auto download content are able to place it or do place the files in an extrafanart folder at the local directory of the media if configured to do so. This is the only implementation of extra fan art I can support. If users do not have this folder it will not effect the skin, they will just get one image in this display mode instead of multiple ones.
If someone wants to add a control to support another way of loading extrafan art they can once I post the final code up; unfortunately it is irresponsible for me to try to add code for something that I can not test and verify works.
Posts: 361
Joined: May 2010
Reputation:
1
I tried using it in the default view types without it working. I will do some more testing to see if I can figure anything out. For reference the way I always have used extra fan art is as follows:
Structure: Drive Letter:/shows/snowname/extrafanart
Content: image files with literally any image filetype and name (usually .png images)
I have tested replacing all images with jpg and naming them things like fanart0 fanart1 ect.
Also note that some of my fanart folders can contain hundreds of images.
Worst case I can make it so that both are supported. As I currently have it displays the results of Image_Background for the image and uses the contents of the /extrafanart folder if available. I can just as easily make the Image_Background support use the same multi image item the rest of the skin uses and fall back to my method for /extrafanart when it has content. This way the content still gets displayed if present.
Posts: 361
Joined: May 2010
Reputation:
1
2017-10-10, 12:22
(This post was last modified: 2017-10-10, 13:11 by ZERO <ibis>.)
Ok, I figured it out. You are correct it does work by default just inconsistently which is what made me think it did not work. Currently it will only load from that in the ep level view on the default view types. So when I was testing on the tvshow level I thought it was not working. I tested with the view mode "RightList". It works in Ep level view but not tvshow level.
I will read over the related code now and start to reverse engineer.
*Or not there was a bug in my code that was causing it to run in this view mode.
Ok so reading the code for Image_Background more clearly I see the reference to script.artwork.beef but this script was not listed in the addons list within the skin in its settings view. However, when I went to the first page of the thread and double checked the addons I found it listed. I did not expect there to be addons listed in the forums that were not within the skins listing itself. I will install that and it will likely fix the problem.
Ok I have also read about how that addon is intended to work and looked at the code from <control type="fadelabel" id="4420"> to verify. This method apparently allows this addon to "grab artwork from the wonderful web services fanart.tv, TheTVDB.com, and The Movie Database." As a result there is no support for the /extrafanart folder. Still though this is a nice service and I will test to see if it works at all. I think you are correct though that the best thing to do would be to build support for the /extrafanart folder directly into the mod. It would require an additional setting because users should be able to select if they want to use the folder option to override if available. Otherwise you would always get 2 options:
A) if there is content in /extrafanart you will always see this content over the content from Control.Getlabel(4420)
B) if Control.Getlabel(4420) can run it always will even if there is content in /extrafanart it will be ignored.
I will set it up to work like option A by default. This way you can add a setting to allow it to also work like option B if you would like. This may not matter because if a user does not want /extrafanrt to load they could just rename the folder or remove its contents.
Posts: 662
Joined: Aug 2015
Reputation:
73
2017-10-10, 13:15
(This post was last modified: 2017-10-10, 13:20 by Alanon.)
Artwork Beef is not a requirement, and the author of the add-on explicitly stated that it not be included in any skin's dependency lists, so I complied. It's an alternative to Artwork Downloader, and if you switch to it, you'll have to change the way in which you handle artworks. The code that I've made for Artwork Beef is separate from Skin Helper, due to the fact that Artwork Beef does not download any artwork in a physical form. That's also why I've made it so that it will only activate if the add-on is present.
I personally prefer Artwork Beef because it has automatic management of movie set artwork, but it is different in both implementation and behaviour, so I'd advise being careful when reading the documentation, so as not to cause massive problems with your own artwork setup. There is Artwork Downloader compatibility mode within Artwork Beef, but there's still a chance of things going wrong with the database.
You might say that the add-on is supported, insofar as it will work once used, but it's in no way required, as Skin Helper + Artwork Downloader is the way 90% of Kodi users prefer to manage their artwork. Skin Helper's behaviour does not change based on whether Artwork Beef is there or not. In fact, Skin Helper's fanart functionality is switched off when it is present, but on the surface, there should be little to no difference with regards to actual performance (image rotation on all levels, etc).
While I suspect that Artwork Beef would generally be more suitable to your requirements, as I've found it to be more flexible, you'll lose features like automatic extrafanart folders, as Artwork Beef simply decided not to download artwork into the library as a design point. That feature exists only in Artwork Downloader. Of course, Artwork Beef can piggyback on existing local extrafanart if it is present, it will not place it in those folders in future artwork updates. You can find most such details in the dedicated thread.
Posts: 361
Joined: May 2010
Reputation:
1
Ah that makes sense.
Just want to verify the conditions here:
!System.HasAddon(script.artwork.beef) + Skin.HasSetting(SkinHelperExtrafanart) + !String.IsEmpty(Window(Home).Property(SkinHelper.ListItem.Art.ExtraFanArt)) + !Skin.HasSetting(global.fanart)
So for me to see it show up correctly I need to remove the script.artwork.beef (which is now called script.artwork.helper).
Turn on Extra Fan Art in settings (have had this on already)
Turn off Fan Art (have tried this setting, just get a black screen when this is off)
So my conclusion is there is something strange going on in SkinHelper.
Also for some reason my version if SkinHelper is requiring that I install script.module.cherrypy is this normal? BTW I am on windows 10... also when script.module.cherrypy Kodi hangs on exit.
Posts: 662
Joined: Aug 2015
Reputation:
73
Artwork Beef is the main addon, script.artwork.helper is a support add-on for it adding some minor features. As far as I've tested it, it is not really needed, as my label control mimics the "smartseries" functionality that the support addon provides. Also, keep in mind that merely installing Artwork Beef will not do anything - you still need to rescan the library for artwork from the addon for its properties to be properly registered. A black screen is usually an indication that either the artwork is not yet cached by Kodi, or that every other bit of variable has been bypassed/not working and the black screen is all you have left for background choices. No matter what you do with your artwork, Kodi has to take a snapshot of the image and place it in its cache for future reference. If you have lots of artwork, that may be a part of the problem.
As far as the conditions - the first is there to ensure that Beef is not installed, as that's one of the points of difference which separates the two implementations. The second confirms that the extrafanart setting is on, the third backs it up to make sure that it is not empty in order to activate the Skin Helper mechanism. That, in turn, makes sure that if you have it set up in any way - if SH detected either an extrafanart folder or cached images in the Kodi cache, it would be triggered, as the property would be filled. That's why I was so puzzled with your issues.
I have no control over Skin Helper's dependencies, whatever the addon demands it needs to get. You certainly need the module for the addon to function properly, as a host of operations is provided and performed by the Skin Helper family of add-ons. It's the single most important thing you must have working for Kodi to work with modern skins. In fact, if Skin Helper backgrounds were inconsistent, it might have been because of a dependency glitch. I'd track down that dependency manually, and either unzip it into the addons folder directly or install it as zip. Many folks have had issues with dependency installations, but that's due to Kodi's internal mechanics, add-on servers, and general OS differences and quirks. If you couldn't get Skin Helper to work in any view-type properly, then that's a signal that it's something a bit more problematic than both our view-type coding.
From the code you've posted, the only thing that I can see that's potentially problematic is that the image background variable also needs to be multiimage control. Also, there are skin settings for the rotation times embedded in the controls (the rotation limit includes), so it would be nice to copy that over as well, to keep things consistent. Also, there are settings that allow for playing video to replace the background, so the visibility conditions should be transferred as well. I still believe that if you get Skin Helper to work properly, you won't need to go through all the trouble of creating a backend, as it should all work out of the box, as it does for the vast majority. Everything keeps coming back to Skin Helper it seems.
Posts: 361
Joined: May 2010
Reputation:
1
I have the required modules loaded so Skin Helper runs properly. I will do some more testing and also make some posts on the related thread to see what the problem is.
Posts: 361
Joined: May 2010
Reputation:
1
2017-10-20, 14:46
(This post was last modified: 2017-10-20, 14:57 by ZERO <ibis>.)
Ok, so I have not heard anything for the extrafanart support on skin helper so I have set it in my view mode that it will only enable detection of that folder if the extrafanart option is selected in the menu. I guess you could think of it as a fail over for when the skin helper does not find the extrafanart folder this part of the code will attempt to display the extrafanart folder contents if there is any.
I see the issue you brought up about playback. I got it to display the video box but I also need to get it to display the now playing info as well. If you happen to know the names of these things for me to look up the code for in the skin it would save me some time.
Hopefully, once I get the video and playing info added into the views it will be ready for prime time.
Also there is one thing I have runinto in the skin itself that I am not sure if there is a toggle for or perhaps something that could be updated. The contex menu does not "wrap" and as a result navigation is slower and clunkier than needed. If I could press the left key once to simply loop to the last item rather than needing to spam the right key it would be more functional.
Posts: 21
Joined: Aug 2017
Reputation:
0
When I enable an intro video in Skin Settins>Extras...
There is a blank screen pause for a few seconds before it starts on boot, how do I stop this pause?