wx.SplashScreen and animated GIF

Hannes MŸueller hannes.mueller at gmail.com
Thu Mar 8 00:43:36 PST 2007


Robin Dunn wrote:
> Hannes MŸueller wrote:
>> Christopher Barker wrote:
>>>
>>> Hannes MŸueller wrote:
>>> He would like to have some kind of animated GIF playing,
>>>> while the application initializes.
>>>>
>>>> Is there any way to accomplish this?
>>>
>>> wx.animate.GIFAnimationCtrl()
>>>
>>> might help.
>>>
>>>
>>> -Chris
>>>
>>
>> Thanks, I found the GIF animation demo. Do you have an Idea how to 
>> implement something like a splash screen with it?
>> I tried already, but did not reach a working solution yet...
> 
> The main thing to keep in mind is that GIFAnimationCtrl relies on timers 
> to know when to show the next frame, and also needs to get paint events, 
> so the MainLoop needs to be running and dispatching events at a steady 
> rate.  This contrasts a bit with the typical use of a splash screen, 
> which is to show it and then go off and do time consuming things to 
> initialize the App, and all of this before app.MainLoop is called.  So 
> for the animation to work well you'll need to have already started the 
> main loop, and not do anything in the gui thread that would be 
> time-consuming and would block events from being delivered.
> 
> 

Thanks! That's info I can work with :)
I will talk to the client about this animation business, perhaps we can 
find another solution :)

Hannes





More information about the wxpython-users mailing list