Alpha Please Test: Experimental Recource Addon - Character Poster with Actor label matching
#1
Download here -> Download Install and implementation instructions on post #2
Showcase on Marvel Stuff:


Got a lot of feedback on the Character Poster Set Project. Also some Skins already implemented and it's also part of the artwork type wiki. -> https://kodi.wiki/view/Artwork_types#pos...oster_sets
Thanks!
Tons of well cared sorted catalogized content is already there -> https://youtu.be/PpaNeO2JnPk
Although it is already available in the KyraDB API, it is still rather uncertain whether @rmrector  will implemented in the near future so that it can be used in bulk/batch without manual paste copy.
Lot's of feedback that members liked it but also too much work the manual copy paste procedure for each movie.
Now i made a prototype of an easy to use addon if the codes are in the skin.
In contrast to the original project, where the posters are part of the movie as artwork type, here they are part of the movie and at the same time part of an actor in it.
It similar like the .actors folder aka actor icons but cause this is hardcoded in kodi core it's bypassed via Resource Addon.

The experimental addon has some nice features includes wich need to be tested and also the code is functional on other Kodi versions and builts (i am still on 17.6)
It would be a big fail if i port all the content fitting to Recource Content and then a have to change afterwards the concept. So i provide now for testing a basice Set about 50+ newer AAA movies.

Features
  • As in Video on top, mainly for DialogVideoInfo: Showing Character Posters matching to a specific movie to a specific actor on focus.
  • Could alternative also used as Multiimage Sideshow everywhere.

Special Features

Multiimage:
  • There are cases when one actor is playing multiple roles also character poster avaiable. The addon is prepared to also support that. Look Showcase -> https://youtu.be/3ItvBXwq-yU
Multiple Choosing Options:
Would be much appreciated to everyone with basic .xml knowledge for testing out and give feedback on the functional side of content preparation.
Codes an install instructions here on post #2
Reply
#2
I'm really no coder guy, it took me almost 1 week to get this code together and also working as inteded, please don't blame me if some stuff is maybe primitive or dirty. 
Great thanks @manfeed & @jurialmunkey to get the main codes i needed for that.

Please test out the Multirole Multiimage feature on the Movies "Suspiria (2018)" - Tilda Swinton, "The Lego Movie 2 (2019)" - Chris Pratt"Beauty and the Beast (2017)" - Dan Stevens
And the Multiple Set Selection on Pets 2 (2019)Solo: A Star Wars Story (2018)Justice League (2017)

Install:
Download the addon. You can not install immediately cause it's i .rar. First unpack then install the ZIP and after install put the resource folder into the already installed Resource Addon.
This is cause when installing the content with it all Special Character will be falsified. For example the name "Françoise Dorléac" will get "FranBLAoise DorlBLAac" so it's corrupting the files making label matching not possible anymore...
A common still unsolved problem...

Implementation:

Toggle Button to switch between alternative Sets of a Movie with Fallback.
If Choosen Alternative 4, then 4, if not falling back to 3, if not falling back to 2, if not falling back to Main.

In my skin IncludesTopMenu.xml

Code:
                    <control type="button" id="93154">
                    <label>Dialogoe Character Poster</label>
                    <label2>$VAR[DialogCharacterPosterToggle]</label2>
                    <include>TopMenuButton</include>  
                    <onclick condition="String.IsEqual(skin.string(characterposter_toggle),Main)">Skin.SetString(characterposter_toggle,Alternative1)</onclick>
                    <onclick condition="String.IsEqual(skin.string(characterposter_toggle),Alternative1)">Skin.SetString(characterposter_toggle,Alternative2)</onclick>
                    <onclick condition="String.IsEqual(skin.string(characterposter_toggle),Alternative2)">Skin.SetString(characterposter_toggle,Alternative3)</onclick>                    
                    <onclick condition="String.IsEqual(skin.string(characterposter_toggle),Alternative3)">Skin.SetString(characterposter_toggle,Alternative4)</onclick>                                            
                    <onclick condition="String.IsEqual(skin.string(characterposter_toggle),Alternative4)">Skin.SetString(characterposter_toggle,Off)</onclick>                    
                    <onclick condition="String.IsEqual(skin.string(characterposter_toggle),Off)|String.IsEmpty(skin.string(characterposter_toggle))">Skin.SetString(characterposter_toggle,Main)</onclick>
                    <visible>Container.Content(movies)</visible>
                </control>

3 Variables, for the toggle Button, Single Image, Multi Image, in my Skin IncludesVariables.xml

Code:
    <variable name="DialogCharacterPosterToggle">
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Main)">Main</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative1)">Altern 1</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative2)">Altern 2</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative3)">Altern 3</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4)">Altern 4</value>    
    <value condition="String.IsEqual(Skin.string(characterposter_toggle),Off)">Off</value>
    </variable>
 

Code:
    <variable name="DialogCharacterPosterImageSingle">
    <!--MAIN-->    
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Main)">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label].jpg</value>
    <!--ALTERNATIVE 1-->        
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative1) + String.IsEmpty(Control.GetLabel(102002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative1) + !String.IsEmpty(Control.GetLabel(102002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#2/$INFO[Container(50).ListItem.Label].jpg</value>
    <!--ALTERNATIVE 2-->    
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative2) + String.IsEmpty(Control.GetLabel(103002)) + String.IsEmpty(Control.GetLabel(102002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative2) + String.IsEmpty(Control.GetLabel(103002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#2/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative2) + !String.IsEmpty(Control.GetLabel(103002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#3/$INFO[Container(50).ListItem.Label].jpg</value>
    <!--ALTERNATIVE 3-->
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(104002)) + String.IsEmpty(Control.GetLabel(103002)) + String.IsEmpty(Control.GetLabel(102002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label].jpg</value>    
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(104002)) + String.IsEmpty(Control.GetLabel(103002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#2/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(104002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#3/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative3) + !String.IsEmpty(Control.GetLabel(104002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#4/$INFO[Container(50).ListItem.Label].jpg</value>    
    <!--ALTERNATIVE 4-->
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(105002)) + String.IsEmpty(Control.GetLabel(104002)) + String.IsEmpty(Control.GetLabel(103002)) + String.IsEmpty(Control.GetLabel(102002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label].jpg</value>    
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(105002)) + String.IsEmpty(Control.GetLabel(104002)) + String.IsEmpty(Control.GetLabel(103002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#2/$INFO[Container(50).ListItem.Label].jpg</value>    
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(105002)) + String.IsEmpty(Control.GetLabel(104002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#3/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(105002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#4/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4) + !String.IsEmpty(Control.GetLabel(105002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#5/$INFO[Container(50).ListItem.Label].jpg</value>        
    </variable>    

Code:
    <variable name="DialogCharacterPosterImageMulti">    
    <!--MAIN-->        
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Main)">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label]</value>
    <!--ALTERNATIVE 1-->
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative1) + String.IsEmpty(Control.GetLabel(102002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative1) + !String.IsEmpty(Control.GetLabel(102002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#2/$INFO[Container(50).ListItem.Label]</value>
    <!--ALTERNATIVE 2-->    
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative2) + String.IsEmpty(Control.GetLabel(103002)) + String.IsEmpty(Control.GetLabel(102002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative2) + String.IsEmpty(Control.GetLabel(103002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#2/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative2) + !String.IsEmpty(Control.GetLabel(103002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#3/$INFO[Container(50).ListItem.Label]</value>
    <!--ALTERNATIVE 3-->
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(104002)) + String.IsEmpty(Control.GetLabel(103002)) + String.IsEmpty(Control.GetLabel(102002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label]</value>    
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(104002)) + String.IsEmpty(Control.GetLabel(103002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#2/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(104002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#3/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative3) + !String.IsEmpty(Control.GetLabel(104002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#4/$INFO[Container(50).ListItem.Label]</value>    
    <!--ALTERNATIVE 4-->
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(105002)) + String.IsEmpty(Control.GetLabel(104002)) + String.IsEmpty(Control.GetLabel(103002)) + String.IsEmpty(Control.GetLabel(102002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label]</value>    
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(105002)) + String.IsEmpty(Control.GetLabel(104002)) + String.IsEmpty(Control.GetLabel(103002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#2/$INFO[Container(50).ListItem.Label]</value>    
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(105002)) + String.IsEmpty(Control.GetLabel(104002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#3/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(105002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#4/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(characterposter_toggle),Alternative4) + !String.IsEmpty(Control.GetLabel(105002))">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#5/$INFO[Container(50).ListItem.Label]</value>        
    </variable>

Main Code for DialogVideoInfo.xml

Code:
            <!--Character Poster BEGIN CODE-->
            <!--Character Poster Single Character
                PATH: resource://resource.images.characterposter/IMDBnumber/actorname.jpg
            -->                
            <control type="image" id="101000">            
                <left>1482</left>
                <top>123</top>
                <width>393</width>            
                <height>575</height>
                <aspectratio aligny="left">stretch</aspectratio>
                <texture background="true">$VAR[DialogCharacterPosterImageSingle]</texture>
                <fadetime>FanartCrossFadeTime</fadetime>                        
                <animation effect="fade" start="0" end="100" time="500" delay="0">Visible</animation>
                <animation effect="fade" start="100" end="0" time="500" delay="0">Hidden</animation>                
                <visible>!Control.Hasfocus(149) + !Control.Hasfocus(160) + Container.Content(movies)</visible>
            </control>
            <!--Character Poster Multi Character
                PATH: resource://resource.images.characterposter/IMDBnumber/actorname/
                If a actor has multiple roles where a Character Poster set is there (for example Chris Pratt in "The LEGO Movie 2 (2019)" or Tilda Swinton in "Suspiria (2018)")...
                instead of a actor filename "actorname.jpg" there is a actor folder "actorname" deposited. Inside the first name is "actorname.jpg" for the matching of the next Code passage (Fake Image)
                The second name is "actorname1.jpg". So you can run multi-image also in integer mode you'll get the main role first and the the second role second in multiimage.
                
                Note, if you want to use the addon not with label matching, instead more like a multi image artwork type like extrafanart, there is a also a copy of the multi character images beside the other characters.
                The names are there falsified actorname0.jpg and actorname1.jpg to not get a muddle for labing matching and you can't anyway do label matching if want to use this way.
            -->    
            <control type="multiimage">
                <left>1482</left>
                <top>123</top>
                <width>393</width>    
                <height>575</height>
                <timeperimage>6000</timeperimage>
                <randomize>false</randomize>    
                <aspectratio aligny="left">stretch</aspectratio>        
                <imagepath background="true">$VAR[DialogCharacterPosterImageMulti]</imagepath>
                <fadetime>FanartCrossFadeTime</fadetime>                        
                <animation effect="fade" start="0" end="100" time="500" delay="0">Visible</animation>
                <animation effect="fade" start="100" end="0" time="500" delay="0">Hidden</animation>
                <visible>!Control.Hasfocus(149) + !Control.Hasfocus(160) + Container.Content(movies) + 
                [!String.IsEmpty(Control.GetLabel(101001)) | !String.IsEmpty(Control.GetLabel(102001)) | !String.IsEmpty(Control.GetLabel(103001)) | !String.IsEmpty(Control.GetLabel(104001)) | !String.IsEmpty(Control.GetLabel(105001))]</visible>                
            </control>
            <!--Character Poster Multi Image Character Fake Image
                PATH: resource://resource.images.characterposter/IMDBnumber/actorname/actorname.jpg (and actorname1.jpg for the following)        
                DESCRIPTION: 
                This creates fake images outside your screen directed to the first actor Image in Subfolder for Multi-Image in Resource Addon. 
                Cause the dialogvideoinfo is most static it should not be that resource consuming.
                This is dirty but is necessary that multi-image is also disappearing and not "get stuck"
                A bit more advanced Skinner than me could do the multiimage run in a list and not a controly type multiimage so this would maybe not necessary anymore.                    
            -->                
            <!--MAIN-->
            <control type="image" id="101001">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <aspectratio aligny="bottom">keep</aspectratio>
                <texture background="true">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]/$INFO[Container(50).ListItem.Label]/$INFO[Container(50).ListItem.Label].jpg</texture>
            </control>
            <!--ALTERNATIVE 1-->
            <control type="image" id="102001">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <aspectratio aligny="bottom">keep</aspectratio>
                <texture background="true">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#2/$INFO[Container(50).ListItem.Label]/$INFO[Container(50).ListItem.Label].jpg</texture>
            </control>
            <!--ALTERNATIVE 2-->
            <control type="image" id="103001">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <aspectratio aligny="bottom">keep</aspectratio>
                <texture background="true">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#3/$INFO[Container(50).ListItem.Label]/$INFO[Container(50).ListItem.Label].jpg</texture>
            </control>            
            <!--ALTERNATIVE 3-->
            <control type="image" id="104001">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <aspectratio aligny="bottom">keep</aspectratio>
                <texture background="true">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#4/$INFO[Container(50).ListItem.Label]/$INFO[Container(50).ListItem.Label].jpg</texture>
            </control>            
            <!--ALTERNATIVE 4-->
            <control type="image" id="105001">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <aspectratio aligny="bottom">keep</aspectratio>
                <texture background="true">resource://resource.images.characterposter/$INFO[ListItem.IMDBNumber]#5/$INFO[Container(50).ListItem.Label]/$INFO[Container(50).ListItem.Label].jpg</texture>
            </control>
            <!--Detector of Multiple Character Poster Sets    
                PATH: resource://resource.images.characterposter/detector/IMDBnumber#(2-5).jpg        
                DESCRIPTION: 
                This creates also fake images outside your screen. 
                Cause if a Movie have more Character Poster Sets Versions avaiable it's a detecting indicator with the "IMDBnumber#(2-5)" fake files deposited in the Resource addon.
                If choosen in the options to prefer an Alternative Character Poster set version, the 2 variables in the IncludesVariables.xml detects if multiple sets are there and if not it's falling back.                    
            -->                
            <!--ALTERNATIVE 1-->
            <control type="image" id="102002">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <texture background="true">resource://resource.images.characterposter/detector/$INFO[ListItem.IMDBNumber]#2.jpg</texture>
            </control>
            <!--ALTERNATIVE 2-->
            <control type="image" id="103002">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <texture background="true">resource://resource.images.characterposter/detector/$INFO[ListItem.IMDBNumber]#3.jpg</texture>
            </control>
            <!--ALTERNATIVE 3-->
            <control type="image" id="104002">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <texture background="true">resource://resource.images.characterposter/detector/$INFO[ListItem.IMDBNumber]#4.jpg</texture>
            </control>
            <!--ALTERNATIVE 4-->
            <control type="image" id="105002">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <texture background="true">resource://resource.images.characterposter/detector/$INFO[ListItem.IMDBNumber]#5.jpg</texture>
            </control>
            <!--Character Poster END CODE-->
Reply
#3
reserved for resource addon structure description
Reply
#4
Nice Work,I got it!Open IncludesTopMenu.xml with Notepad ++, search for 93153, and copy the new code under 93153. The other two pieces of code open the corresponding file and add the bottom of the code.
We hope you can improve this feature as soon as possible. We haven't found any errors at this time.
My skin is Aeon MQ8 Muilt-Mod
Image
Reply
#5
@"chrissix" 

Looks very goodWink

I have a question.

How can I add all these movie reviews like you did?
Image

Would be grateful if you could tell me.
Reply
#6
(2020-01-30, 06:31)qizhouzhangsheng Wrote: Nice Work,I got it!Open IncludesTopMenu.xml with Notepad ++, search for 93153, and copy the new code under 93153. The other two pieces of code open the corresponding file and add the bottom of the code.
We hope you can improve this feature as soon as possible. We haven't found any errors at this time.
In the rarest of cases you can simply copy paste a code. Every skin is different, it usually needs adjustments. In this case simply choose another suitable ID.
But the multiimage function and the alternative version function with fallback works without bugs?
 
(2020-01-30, 10:22)latioboy Wrote: How can I add all these movie reviews like you did?
Look at @latts9923 Aeon MQ skin mods projects.
Reply
#7
i need some advice regarding texture (artwork) compression from (team kodi) members familiar with the kodi engine.
Every artwork from media equal or called with ListItem.artworktype or ListItem Foldername on multiimage gets a in engine "aftertreatment and calibration",
for example tooo high resolution images will get automate downscaled/downrendered to look native and not pixelated.

But this is not the case on images via resource addons. Am i right? Is there a workaround to to so or any plans to implement in next kodi version?
It this cause artwork from media gets cached in optimum size and from resources it doesn't get cached at all?

This is the best example what i mean its both the equal same image:

Auto compressed (or rendered) in optimum size:
Image
Complete native without any touching:
Image

Maybe @ronie or @DarrenHill can clarify?
Reply
#8
i'm not 100% sure, but i think only remote artwork is being cached.
since resource addons are installed locally, there's no reason to cache them i guess.

kodi isn't very good at downscaling images.
if an images needs to be scaled just a tiny bit, the result will be ok,
but if you have a 1024x1024px source images that will be shown in the skin at 150x150px the result will be poor.
reason is, kodi uses a very fast (but low quality) scaling algorithm.

you can select a high quality (but slower) scaling algorithm in advancedsetiings.xml,
but if i understand the wiki correctly, that will only be used when caching images.
so that might not help in this case...
https://kodi.wiki/view/Advancedsettings....galgorithm
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
#9
@ronie great thanks for the informative reply!
I'm actually very happy with the scaling.
The problem is that there is no scaling at all with resource content (also not on skin textures i think), it's really only happening on artwork content.

Do you know wich Team Kodi member is the responsible mate for this kind of topic?
Who is the right to ask for future kodi if it's a good idea for some kind of texture and resource cache?

Ok so i think the only actual workaround is to scale down in resolution the resource image content in a compromise way so that's not pixelated when resolution is too high and not blurry when resolution is too low.
Reply
#10
(2020-01-31, 01:09)ronie Wrote: you can select a high quality (but slower) scaling algorithm in advancedsetiings.xml,

https://kodi.wiki/view/Advancedsettings....galgorithm
Out of the algorithms listed in the wiki, do you (or anybody) know which one would produce the best results? Assume that hardware specs are not an issue.

xml:
fast_bilinear
bilinear
bicubic
experimental
nearest_neighbor
averaging_area
bicublin
gaussian
sinc
lanczos
bicubic_spline
My Signature
Links to : Official:Forum rules (wiki) | Official:Forum rules/Banned add-ons (wiki) | Debug Log (wiki)
Links to : HOW-TO:Create Music Library (wiki) | HOW-TO:Create_Video_Library (wiki)  ||  Artwork (wiki) | Basic controls (wiki) | Import-export library (wiki) | Movie sets (wiki) | Movie universe (wiki) | NFO files (wiki) | Quick start guide (wiki)
Reply
#11
Image
When look at the hair...

The left image is the original image with 2500 pixel height and coming via artwork type.
The right image is already downscaled to 1500 pixel hight and coming from a resource.

In conclusion there is a huge difference!
So i will more concentrate on a artwork type solution. But i will still provide a resource solution cause the work is done in once.
Except on the ".actors" folder there is no artwork special provided for actors.
It seems to me more logical name a folder ".actorsposter" instead of the movie general artwork folders "extrafanart" or "extrathumbs" naming it "characterposter".

Pros of this solution: 
  • Images get again scaled/rendered
Cons of this solution:
  • It's a lot of copy/paste work again
  • It's slower than the resource solution
  • Hard drives are accessed again, so it's more for dialogvideoinfo and not normal views on scroll.

Pros of the resource solution:
  • It was intend as a kind of "fire and forget solution", just install and no more work.
  • Faster
  • No access to hard drives
Cons of the resource solution:
  • As in the screenshot, no scaling/rendering of the images
  • A few hunded mb of storage space on the drive kodi is installed
Reply
#12
Cause of the scaling problems new approach is now make it an movie artwork type instead of resource again:
For the following code the files habe to be this structure.

Cause it is similar working like the .actors folder i named the folder .characterposter
But instead of putting the files direct into the folder making a subfolder that different sets can be togglet with fallback (set0, set1,...)

It can be work with both, on dialogvideoinfo with cast list label matching or also in a simple sideshow in normal views.
But it's not replacing the Character Poster artwork type (poster1,poster2,...) 
Cause this new approach is only for poster with actor/character roles on it and on the normal character poster there more other stuff on it like this -> https://i.ibb.co/LJ7PsVq/Unbenannt-1.jpg

.actors (folder)
.characterposter (folder)
  ->set0 (folder)
    -->actorname.jpg
    ...
  ->set1 (folder)
    -->actorname.jpg
    ...
  ->set0.jpg (fakefile)
  ->set1.jpg (fakefile)

The fakefiles are in my case simple copies of the poster.jpg.
The fakefiles are for 2 purposes:
An indicator if a set is there and also for fallback.
To make multiimage work good with the normal multiimage control.
____

IncludesVariables.xml

Code:
    <variable name="FolderCharacterPosterImageSingle">
    <!--MAIN-->    
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Main)">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label].jpg</value>
    <!--ALTERNATIVE 1-->        
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative1) + String.IsEmpty(Control.GetLabel(112002))">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative1) + !String.IsEmpty(Control.GetLabel(112002))">$INFO[ListItem.Path].characterposter/set1/$INFO[Container(50).ListItem.Label].jpg</value>
    <!--ALTERNATIVE 2-->    
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative2) + String.IsEmpty(Control.GetLabel(113002)) + String.IsEmpty(Control.GetLabel(112002))">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative2) + String.IsEmpty(Control.GetLabel(113002))">$INFO[ListItem.Path].characterposter/set1/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative2) + !String.IsEmpty(Control.GetLabel(113002))">$INFO[ListItem.Path].characterposter/set2/$INFO[Container(50).ListItem.Label].jpg</value>
    <!--ALTERNATIVE 3-->
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(114002)) + String.IsEmpty(Control.GetLabel(113002)) + String.IsEmpty(Control.GetLabel(102002))">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label].jpg</value>    
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(114002)) + String.IsEmpty(Control.GetLabel(113002))">$INFO[ListItem.Path].characterposter/set1/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(114002))">$INFO[ListItem.Path].characterposter/set2/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative3) + !String.IsEmpty(Control.GetLabel(114002))">$INFO[ListItem.Path].characterposter/set3/$INFO[Container(50).ListItem.Label].jpg</value>    
    <!--ALTERNATIVE 4-->
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(115002)) + String.IsEmpty(Control.GetLabel(114002)) + String.IsEmpty(Control.GetLabel(113002)) + String.IsEmpty(Control.GetLabel(102002))">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label].jpg</value>    
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(115002)) + String.IsEmpty(Control.GetLabel(114002)) + String.IsEmpty(Control.GetLabel(113002))">$INFO[ListItem.Path].characterposter/set1/$INFO[Container(50).ListItem.Label].jpg</value>    
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(115002)) + String.IsEmpty(Control.GetLabel(114002))">$INFO[ListItem.Path].characterposter/set2/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(115002))">$INFO[ListItem.Path].characterposter/set3/$INFO[Container(50).ListItem.Label].jpg</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative4) + !String.IsEmpty(Control.GetLabel(115002))">$INFO[ListItem.Path].characterposter/set4/$INFO[Container(50).ListItem.Label].jpg</value>        
    </variable>    

    <variable name="FolderCharacterPosterImageMulti">    
    <!--MAIN-->        
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Main)">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label]</value>
    <!--ALTERNATIVE 1-->
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative1) + String.IsEmpty(Control.GetLabel(112002))">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative1) + !String.IsEmpty(Control.GetLabel(112002))">$INFO[ListItem.Path].characterposter/set1/$INFO[Container(50).ListItem.Label]</value>
    <!--ALTERNATIVE 2-->    
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative2) + String.IsEmpty(Control.GetLabel(113002)) + String.IsEmpty(Control.GetLabel(112002))">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative2) + String.IsEmpty(Control.GetLabel(113002))">$INFO[ListItem.Path].characterposter/set1/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative2) + !String.IsEmpty(Control.GetLabel(113002))">$INFO[ListItem.Path].characterposter/set2/$INFO[Container(50).ListItem.Label]</value>
    <!--ALTERNATIVE 3-->
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(114002)) + String.IsEmpty(Control.GetLabel(113002)) + String.IsEmpty(Control.GetLabel(112002))">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label]</value>    
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(114002)) + String.IsEmpty(Control.GetLabel(113002))">resource://resource.images.characterposter/$INFO[ListItem.Path].characterposter/set1/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative3) + String.IsEmpty(Control.GetLabel(114002))">resource://resource.images.characterposter/$INFO[ListItem.Path].characterposter/set2/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative3) + !String.IsEmpty(Control.GetLabel(114002))">resource://resource.images.characterposter/$INFO[ListItem.Path].characterposter/set3/$INFO[Container(50).ListItem.Label]</value>    
    <!--ALTERNATIVE 4-->
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(115002)) + String.IsEmpty(Control.GetLabel(114002)) + String.IsEmpty(Control.GetLabel(113002)) + String.IsEmpty(Control.GetLabel(102002))">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label]</value>    
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(115002)) + String.IsEmpty(Control.GetLabel(114002)) + String.IsEmpty(Control.GetLabel(113002))">$INFO[ListItem.Path].characterposter/set1/$INFO[Container(50).ListItem.Label]</value>    
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(115002)) + String.IsEmpty(Control.GetLabel(114002))">$INFO[ListItem.Path].characterposter/set2/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative4) + String.IsEmpty(Control.GetLabel(115002))">$INFO[ListItem.Path].characterposter/set3/$INFO[Container(50).ListItem.Label]</value>
    <value condition="String.IsEqual(Skin.String(foldercharacterposter_toggle),Alternative4) + !String.IsEmpty(Control.GetLabel(115002))">$INFO[ListItem.Path].characterposter/set4/$INFO[Container(50).ListItem.Label]</value>
    </variable> 

DialogVideoInfo.xml

Code:
               <control type="group">    
                <visible>String.IsEqual(Skin.String(topmenucharacterposter_toggle),Folder)</visible>            
            <control type="image">            
                <left>1482</left>
                <top>123</top>
                <width>393</width>            
                <height>575</height>
                <aspectratio aligny="left">stretch</aspectratio>
                <texture background="true">$VAR[FolderCharacterPosterImageSingle]</texture>
                <fadetime>FanartCrossFadeTime</fadetime>                        
                <animation effect="fade" start="0" end="100" time="500" delay="0">Visible</animation>
                <animation effect="fade" start="100" end="0" time="500" delay="0">Hidden</animation>                
                <visible>!Control.Hasfocus(149) + !Control.Hasfocus(160) + Container.Content(movies)</visible>
            </control>    
            <control type="multiimage">
                <left>1482</left>
                <top>123</top>
                <width>393</width>    
                <height>575</height>
                <timeperimage>6000</timeperimage>
                <randomize>false</randomize>    
                <aspectratio aligny="left">stretch</aspectratio>        
                <imagepath background="true">$VAR[FolderCharacterPosterImageMulti]</imagepath>
                <fadetime>FanartCrossFadeTime</fadetime>                        
                <animation effect="fade" start="0" end="100" time="500" delay="0">Visible</animation>
                <animation effect="fade" start="100" end="0" time="500" delay="0">Hidden</animation>
                <visible>!Control.Hasfocus(149) + !Control.Hasfocus(160) + Container.Content(movies) + [!String.IsEmpty(Control.GetLabel(111001)) | !String.IsEmpty(Control.GetLabel(112001)) | !String.IsEmpty(Control.GetLabel(113001)) | !String.IsEmpty(Control.GetLabel(114001)) | !String.IsEmpty(Control.GetLabel(115001))]</visible>                
            </control>
            <!--MAIN-->
            <control type="image" id="111001">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <aspectratio aligny="bottom">keep</aspectratio>
                <texture background="true">$INFO[ListItem.Path].characterposter/set0/$INFO[Container(50).ListItem.Label]/$INFO[Container(50).ListItem.Label].jpg</texture>
            </control>
            <!--ALTERNATIVE 1-->
            <control type="image" id="112001">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <aspectratio aligny="bottom">keep</aspectratio>
                <texture background="true">$INFO[ListItem.Path].characterposter/set1/$INFO[Container(50).ListItem.Label]/$INFO[Container(50).ListItem.Label].jpg</texture>
            </control>
            <!--ALTERNATIVE 2-->
            <control type="image" id="113001">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <aspectratio aligny="bottom">keep</aspectratio>
                <texture background="true">$INFO[ListItem.Path].characterposter/set2/$INFO[Container(50).ListItem.Label]/$INFO[Container(50).ListItem.Label].jpg</texture>
            </control>            
            <!--ALTERNATIVE 3-->
            <control type="image" id="114001">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <aspectratio aligny="bottom">keep</aspectratio>
                <texture background="true">$INFO[ListItem.Path].characterposter/set3/$INFO[Container(50).ListItem.Label]/$INFO[Container(50).ListItem.Label].jpg</texture>
            </control>            
            <!--ALTERNATIVE 4-->
            <control type="image" id="115001">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <aspectratio aligny="bottom">keep</aspectratio>
                <texture background="true">$INFO[ListItem.Path].characterposter/set4/$INFO[Container(50).ListItem.Label]/$INFO[Container(50).ListItem.Label].jpg</texture>
            </control>            
            <!--ALTERNATIVE 1-->
            <control type="image" id="112002">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <texture background="true">$INFO[ListItem.Path].characterposter/set1.jpg</texture>
            </control>
            <!--ALTERNATIVE 2-->
            <control type="image" id="113002">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <texture background="true">$INFO[ListItem.Path].characterposter/set2.jpg</texture>
            </control>
            <!--ALTERNATIVE 3-->
            <control type="image" id="114002">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <texture background="true">$INFO[ListItem.Path].characterposter/set3.jpg</texture>
            </control>
            <!--ALTERNATIVE 4-->
            <control type="image" id="115002">            
                <left>-1</left>
                <top>-1</top>
                <width>1</width>
                <height>1</height>
                <texture background="true">$INFO[ListItem.Path].characterposter/set4.jpg</texture>
            </control>    
            </control>    

This code is for DialogVideoInfo.xml cast list label matching.
If want to use a simple multiimage sideshow the code needs to be a bit adapted that the multiimage will not "hung".
​​​​​​​(also include set0.jpg fakefile on visible condition)
Reply
#13
@latts9923 Just FYI post below
Reply
#14
This is insane, fantastic work!
Image
Reply
#15
@"chrissix"
Hey bud, I got the new code working in Video Info. Looks good!
Reply

Logout Mark Read Team Forum Stats Members Help
Please Test: Experimental Recource Addon - Character Poster with Actor label matching0