在查阅的资料中,发现大多都是一些前版本的wxpython使用gif图,从而导入失败。
import wx.animate
在新的wx中已不再适用。所以需导入
from wx.adv import AnimationCtrl
#在frame中使用
self.animation = AnimationCtrl(self)
self.animation.LoadFile(r'test.gif')
self.animation.Play()
在查阅的资料中,发现大多都是一些前版本的wxpython使用gif图,从而导入失败。
import wx.animate
在新的wx中已不再适用。所以需导入
from wx.adv import AnimationCtrl
#在frame中使用
self.animation = AnimationCtrl(self)
self.animation.LoadFile(r'test.gif')
self.animation.Play()