I shouldn't be too hard. I don't have time these days, but I add this on my TODO list...-An attribute for Animated Bitmaps in which one can specify how often the animation is played
What would be the "use case" for this one?-Something like a delay function, e.g. "delay(1000);window.show()", that one can specify a delay before another command is executed
Code: Select all
animwin.show();delay(1000);animwindow.hide(),plwindow.show()
I would prefer the skins2 engine to have loop="x" because I think it's more flexible than delay="1000".2.
For the moment, animations are played forever (a neverending loop).
Could you add, for animations, a new option in order play them or forever or a number of specified times.
Let's say :
loop="0" for a neverending animation
loop="1" for an animation played only once, that would stop after all the frames are played once
loop="X" for an animation played X times
Thanks.
Code: Select all
<SubBitmap id="main-window-play_over" x="394" y="424" width="24" height="342" nbframes="18" fps="36" loop="4" />
The workaround is simple. Just create several layouts..But there is still the question when the animation will start. Will it be started anew each time the window/layout is shown, or will it just be starte when the skin is loaded and never restarted?
- the timer start time is not changed (which means that some animated bitmaps may never be seen as such if part of an invisible window/layout). That also means that a special care must be given to the first subimage (must carry a meaningful content in case animation is not seen)
erwan10 suggested to use the first frame for the static image, I would prefer the last one. It sounds more logical to me (imo).
Just let the animation end, and voila. That's the purpose of the setting "loop=1" (or loop="4" ... whatever), ... to set an ending.The problem with animated bitmaps that have a loop attribute is how VLC determines when to start/restart the animation. This problem was not there before. Before the animation just was continuously repeated. Now with animated bitmaps that have an "end" the question is, what to do once the animation has been played to the end?
Again, that's the goal of "loop=1"..Erwan10 suggested that at this point the animated bitmap turns into a static bitmap. I understand from this, that it wouldn't any more be possible to play the animation again after it has been shown once. That would not be a desirable behavior imho.
Code: Select all
<!-- BITMAP ID DECLARATIONS -->
<Bitmap id="main-window-subbitmap" file="images/main-window-subbitmap.png" alphacolor="#ff00ff">
<!-- Background -->
<SubBitmap id="main-window-background" x="153" y="830" width="435" height="216" />
<!-- pretty animation -->
<SubBitmap id="main-window_pretty-animation_auto-started" x="127" y="1" width="52" height="828" nbframes="18" fps="18" loop="1" />
<SubBitmap id="main-window_pretty-animation_when-hovered" x="180" y="1" width="52" height="828" nbframes="18" fps="18" loop="1" />
</Bitmap>
Code: Select all
<!-- POSITIONS OF ELEMENTS -->
<Window id="main-window" x="200" y="200" dragdrop="true" playondrop="false" >
<!-- **************************************** Main Window **************************************** -->
<!-- ******************** Default Layout ******************** -->
<Layout id="main-window-default-layout" width="435" height="216" >
<!-- ******************** Group ******************** -->
<Group x="0" y="0">
<!-- pretty animation -->
<Checkbox x="335" y="85"
up="main-window_pretty-animation_auto-started"
over="main-window_pretty-animation_when-hovered"
state="main-window.isVisible" action1="none" action2="none"
tooltiptext1="" tooltiptext2=""/>
</Group>
</Layout>
</Window>
Everything we need is erwan10 to add these settings to images :What I suggest now is, that each time the animated bitmap gets visible (be it through a layout change, a mouse hover or some other visibility change) the animation is played back from the beginning and, if it is shown long enough, ends with the last frame.
Well, no problem... But your English sounds good to me ...erwan10 : would there be a way to "chat" with you on IRC someday ? I would like to talk to you about this feature in french, if you don't mind.
I understand english but in french, I would be 100% sure of what's been said here.
Users browsing this forum: No registered users and 81 guests