Asynchronous loading

Hi! I would like to show an animation while a big model is being loaded, but I can’t. I’m using Panda3D 1.9.2. Here is the code:

import direct.directbase.DirectStart
from direct.gui.OnscreenText import OnscreenText
OnscreenText('loading').hprInterval(1, (0, 0, 359)).loop()
def on_end_loading(model): print 'loaded ' + model.getName()
loader.loadModel('track', callback=on_end_loading)
base.run()

The application freezes until the model is fully loaded, so I can’t see the rotating printing during the loading. What am I missing here? Thank you very much!

Hey flavio!!! How are you?
I think this might be related to this bug:
https://bugs.launchpad.net/panda3d/+bug/1019599

rdb already fixed it, so it might be interesting to update your panda version or just replicate the fix if you don’t want collaterals :slight_smile:

Hi heek! :slight_smile: Thank you for the info, I’ll test it asap! :slight_smile: