1. Download our Official Android App: Forums for Android!

Apps Map with 5+ Overlay Items causing massive lag

Discussion in 'Android Development' started by R*BOMB, May 6, 2010.

  1. R*BOMB

    R*BOMB Lurker
    Thread Starter

    Apr 18, 2010
    I am writing a simple GPS app that will plot the points and draw the path of wherever you go... however once more than 5 points are drawn onto the map and the associated path is drawn the app becomes more or less unusable as it nearly locks up completely... which really is not fun. I believe i know what the problem is but i am unsure how i would... solve the issue. As it stands I only update the coordinates and what not when the application resumes, meaning i only really need to draw the items once... at least i hope so. I Override the onDraw() method in Itemized Overlay, in hopes that that would only be called once, however it appears it is called every time anything changes on the UI....

    Is there anyway i can avoid this lag from happening, or prevent onDraw from being called, or anything which would solve my issues? : /

    Thank you in advance



Share This Page