How do I animate a switch between two different images (both in the art map) ? - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32) +--- Forum: Skinning (https://forum.kodi.tv/forumdisplay.php?fid=12) +--- Thread: How do I animate a switch between two different images (both in the art map) ? (/showthread.php?tid=351258) |
How do I animate a switch between two different images (both in the art map) ? - black_eagle - 2020-01-25 What I want to be able to do is show the front cover of a CD and then after some seconds, spin it/fade it/just replace it to show the back cover (if it exists). I've seen this effect in at least one other skin. but my skinning knowledge is slim to say the least so I was wondering if someone could post some simple example code that can do this. I can't use a simple multi-image control as the art is not in a directory but in the art map. Manfeed's Aeon-tajo skin does this, along with sliding the entire CD case to the right and then sliding left with the back cover displayed. It then spins around after a few seconds to display the front again. I've looked at the xml but there are a bunch of stacked animations and grouped stuff and I don't find it easy to see what does what, hence my asking for a simpler example. Cheers for any help anyone can offer. RE: How do I animate a switch between two different images (both in the art map) ? - the_other_guy - 2020-01-26 this is what i use to spin a thumb to a poster https://forum.kodi.tv/showthread.php?tid=345420 RE: How do I animate a switch between two different images (both in the art map) ? - black_eagle - 2020-01-26 @the_other_guy Thanks, I think! How do I connect this up to the two images ? If it helps, what I want to do is spin the album cover in DialogMusicInfo.xml to show the back cover if there is one. Base skin is Estuary. RE: How do I animate a switch between two different images (both in the art map) ? - jurialmunkey - 2020-01-27 @black_eagle Try this:
In the animation center="250,0" value must be half of width of image group. I've used Art(poster) and Art(fanart) here, but the images can be anything. What happens: 1. Image01 rotates from -90 degrees to 0 degrees (takes 2000ms) 2. Image01 waits at 0 degrees for 2000ms 3. Image01 rotates to 90 degrees (takes 2000ms) and then hides (delayed fade animation) 4. Image02 becomes visible (delayed fade animation) and rotates from -90 degrees to 0 degrees (takes 2000ms) 5. Image02 waits at 0 degrees for 2000ms 6. Image02 rotates to 90 degrees (takes 2000ms) and then hides RE: How do I animate a switch between two different images (both in the art map) ? - black_eagle - 2020-01-27 @jurialmunkey Thank you so much! The comments in the code and the explanation are much appreciated. I doubt I would ever have worked out how to do it myself. |