Kodi Community Forum

Full Version: Wraplist Focus Animation Troubles..Please Help!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I have a wraplist that is have set to be available for movies, tv shows, and seasons. I have a typical focus/unfocus animation for the wraplist, and it works just fine for movies and tvshows. However when I enter the seasons node, I can not get the focus animation to work. I ran in debug mode and it shows that my wraplist has focus, but the animation will not take place. I have other animations on labels that react once the wraplist is focused that seem to be working just fine in seasons node. Below is my code and if anyone has any idea why this is happening I would love to get it corrected. Thanks to anyone who can assist!

Code:
<control type="wraplist" id="58">
            <viewtype label="Poster Slide">wrap</viewtype>
            <posx>-5</posx>
            <posy>175</posy>
            <width>1450</width>
            <height>425</height>
            <onup>SetFocus(9500)</onup>
            <ondown>SetFocus(9500)</ondown>
            <onleft>58</onleft>
            <onright>58</onright>
            <orientation>horizontal</orientation>
            <focusposition>1</focusposition>
            <scrolltime>200</scrolltime>
            <preloaditems>4</preloaditems>
            <include>Lower_SlidePoster</include>
            <visible>Container.Content(movies) | Container.Content(tvshows) | Container.Content(seasons)</visible>
            <itemlayout height="400" width="208">
                <control type="image">
                    <posx>16</posx>
                    <posy>16</posy>
                    <width>185</width>
                    <height>273</height>
                    <aspectratio scalediffuse="false" align="center">stretch</aspectratio>
                    <texture background="true" diffuse="views/wall/diffuse/poster_diffuse.png">$INFO[ListItem.Thumb]</texture>
                </control>
                <control type="image">
                    <posx>-7</posx>
                    <posy>2</posy>
                    <width>232</width>
                    <height>310</height>
                    <texture background="true">views/showcase/border.png</texture>
                </control>
            </itemlayout>
            <focusedlayout height="400" width="208">
                <control type="image">
                    <posx>16</posx>
                    <posy>16</posy>
                    <width>185</width>
                    <height>273</height>
                    <aspectratio scalediffuse="false" align="center">stretch</aspectratio>
                    <texture background="true" diffuse="views/wall/diffuse/poster_diffuse.png">$INFO[ListItem.Thumb]</texture>
                    <include>focus_SlidePoster</include>
                </control>
                <control type="image">
                    <posx>-7</posx>
                    <posy>2</posy>
                    <width>232</width>
                    <height>310</height>
                    <texture background="true">views/showcase/border.png</texture>
                    <include>focus_SlidePoster</include>
                </control>
            </focusedlayout>
        </control>

Code for the animation

<include name="focus_SlidePoster">
<animation type="focus">
<effect type="zoom" start="100,100" end="130,130" easing="Out" reversible="false" center="105,150" time="250"/>
</animation>
<animation type="unfocus">
<effect type="zoom" tween="Cubic" start="130,130" end="100,100" easing="Out" reversible="false" center="105,150" time="250" />
</animation>
</include>
Damn, I'm no expert, but it seems that portion is ok.

Just some random thought, don't you have any other animations or conditions or whatever that might be preventing or stopping that animation at season level?

I'm a noob, but I think it would be better if you show the entire xml
Just to be safe I stripped away everything but the wraplist and it still does not work.
Supposing that the coding is ok for the view as I stated before, another thing I can think off is something in MyVideoNav.
The only thing that I could think of in myvideonav was the default control. I have changed it to this view specifically and it still won't give me the focus animation within only seasons.
Have you tried putting the animation code directly in the image control?
Hitcher Wrote:Have you tried putting the animation code directly in the image control?

That was the first thing I tried. I have also now split it off into a completely seperate view for just seasons and gave it a new id, but it still does not work.

I then tried to add the view to the episode node and found out the animation does not work on that level as well. It is so strange because debug clearly shows the wraplist as having focus.

By the way I am on windows using RC1. Thanks everyone for the suggestions, but I seem to be getting no where. I am going to install RC2 and see if the problem is still there.
PM me if you're still having trouble.
Has to be something conflicting other than what you have posted. I put the code you have posted into one of my views and everything flows fine on Movie/TV and Season level...

Whats <include>Lower_SlidePoster</include>
mcborzu Wrote:Has to be something conflicting other than what you have posted. I put the code you have posted into one of my views and everything flows fine on Movie/TV and Season level...

Whats <include>Lower_SlidePoster</include>

That is an animation to lower the wraplist. That works just fine, but I also stripped that away to double check and make sure it was not causing a problem.

At this point I am thinking it has to be something with my media panel or myvideonav. I am going to try and throw the view into Confluence and see what happens when I get home.
It only seems to happen when there's less items in the list than it is wide resulting in the same items appearing two or three times. I'd personally switch to a fixedlist.
I just discovered the real KEY to this issue last night, I just about gave up but found out the answer:

remove your <preloaditems>4</preloaditems> from the list control and it will work like a charm!
Arcanthur Wrote:I just discovered the real KEY to this issue last night, I just about gave up but found out the answer:

remove your <preloaditems>4</preloaditems> from the list control and it will work like a charm!

Your are the man!

It worked and I am not a very happy that it is resolved. Is that a bug in xbmc or just incorrect coding? I have always used preloads and never had a problem in the past.
ekim232 Wrote:Your are the man!

It worked and I am not a very happy that it is resolved. Is that a bug in xbmc or just incorrect coding? I have always used preloads and never had a problem in the past.

Purely a guess it's a bug, but honestly I haven't noticed any difference with or without it Oo

We'd need someone with more coding experience than I to take a look at what causes the issue. I'm also having wierd issues with some wraplists, where on NEXT everything shows and animates properly, but on PREVIOUS some of the textures and labels don't show.
Now that you have found the problem it seems pretty obvious that at least that was wrong, I've never take a look into what it was before as I never had to deal with it, just that I've never seen it before set it higher than 1, but didnt ring any bell. Anyway, a simple search in the wiki hide a tada:

http://wiki.xbmc.org/index.php?title=Bac...age_Loader

Quote:Normal texture loading

The only textures loaded by XBMC are the ones currently visible. Nothing displays on the screen until all the images have been loaded in memory, this can result in "jerky" scrolling through panel containers. As you scroll down, XBMC will delay the scrolling animation until all of the images in the next row are loaded.

Background loading


Images are loaded one at a time in a background worker thread and are shown as soon as xbmc processes them. Has the benefit that images can be loaded into memory before they're visible, resulting in smoother scrolling and transitions.

Preloading


Used to automatically load the next items (or rows/columns in the case of a panel) while scrolling. Currently limited to 2.

Still don't see what has to do with animation or how it only affect the animation or how it only does it in season level.
Pages: 1 2