0 Replies Latest reply on Jan 22, 2013 12:31 PM by Bramblethorne

    FileStream.write* takes nearly a minute and a half to write 80k to storage (in iOS mobile).

    Bramblethorne Level 1

      This freezes our app for nearly a minute and a half -EVEN IF WE USE openAsync()!


      No touch input is accepted (or rather it is queued, but not responded to).


      All other threads come to a grinding halt;  for instance, if I change the value of a string variable which is bound to a Spark Label, and then openAsync() writeWhatever(), the Label won't update until the FileStream I/O is complete.  I have to use a Timer() just to get a message to my user telling them that they will be waiting an unreasonably long time.


      A second for instance... If I have a BusyIndicator rotating its merry way, the second I initiate the file I/O, it HALTS dead.... even if the IO is Async!


      This of course makes our app completely unusable.


      Any help?  Is this iOS?   Is this AIR?  I should be able to write 80k to the solid state storage of an iPad 2 in a second or three, no more.  The internal camera can dump video streams and 5+mb image captures to disk in reasonable time.... Why can this not?


      The only possibility I haven't accounted for is that the JPEGEncoder thread is async and taking a rediculously long time to encode a 1024x768 (or even a 400x300) BitmapData object at 80% quality 3x progressive.


      Grateful for any help