android - Running Several asynctask in my MainActivity -
android - Running Several asynctask in my MainActivity -
i'm displaying 5 big bitmaps in mainactivity next google instructions avoid memory leaks , not freeze ui thread.
http://developer.android.com/training/displaying-bitmaps/process-bitmap.html
so, i'm starting 1 asynctask
each 1 of 5 big bitmaps in oncreate
method...
i'm not freezing ui thread (good) because i'm running long processes in 1 thread each 1 "my problem" these 5 big bitmaps part of same figure (face) , when app starts user can see how different layers beingness loaded @ different time.
i've thought in splash screen until images loaded i'd know if best way (because splash needed maybe less 1 second) or there improve way, notify ui thread when lastly image loaded , show images...or maybe seek load images in same asynctask
?
thanks in advance,
paola.
finally, i've loaded 5 big bitmaps in same asynctask. i've loaded them in doinbackground method , display of them @ 1 time in onpostexecute of asynctask.
i thinking siddharth lele's reply , wanted understood got same result calling 1 asynctask onpostexecute of other asynctask , waiting lastly asynctask display imageviews doing in doinbackground method 1 asynctask , waiting postexecute of asynctask until bitmaps loaded, , think it's more efficient because have not more threads need...
let me know if there other consideration approach.
thanks!
android bitmap android-asynctask
Comments
Post a Comment