Home / Topic / Comic Project Running out of memory on Android

Comic Project Running out of memory on Android

Home Kwiksher Forums Bug reporting (RETIRED) Comic Project Running out of memory on Android

Viewing 4 posts - 1 through 4 (of 4 total)
  • #9387

    (sorry, realized this is in the wrong forum after I posted.  This is about K1, not K2)Using the default setup for a universal comic app, on one Android device I get Force Closes due to running out of memory.  On newer Android devices, once the app runs out of memory, all the pages stop loading and just show up as white boxes.I'm guessing this is because the Lua script generated never uses display.removeObject to remove the loaded pages.  Here's my quick fix that seems to work:Modified Reader:loadPage function:

    Code:
    function Reader:loadPage( pageNum, frameNum )            if(pageNum > 0)then            local pageToRemove = pageNum - 1            display.remove(self.book.pages[pageToRemove])            self.book.pages[pageToRemove] = nil                        pageToRemove = pageNum + 1            display.remove(self.book.pages[pageToRemove])            self.book.pages[pageToRemove] = nil        end

    Anonymous
    #12462

    The Comic project in Kwik uses Corona Comics SDK “as is” and, honestly, shouldn't be used for real projects due the several known memory issues with that. In fact, this option (comics) will not be available in Kwik 2.About your suggestion, can you please forward me your full Reader.lua file with your changes? Also, I strongly suggest your to use JPG images instead PNG. Doing that, modify line:

    Code:
    page = display.newImage( basename .. ".png" )

    to ".jpg" instead.Alex

    #12463

    PNG is working quite well for me.  My artwork has a limited palette, and using PNG-8 allows me to save almost 80% filesize compared to PNG-24 or JPG.  Staying under the 50MB limit for android is pretty challenging!  I sent you an email with some updated files (still under construction).

    Anonymous
    #12464

    I know how hard is to code for Android, that's why I suggested the JPG.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

Privacy Preference Center

Strictly Necessary

these coolies are for WP-SpamShield, gdpr-wp, woocommerce, paypal

PHPSESSID, SJECT16, JCS_INENREF, JCS_INENTIM, gdpr, woocommerce_cart_hash, woocommerce_items_in_cart, woocommerce_recently_viewed, wordpress_, wordpress_logged_in_, wordpress_sec_, wordpress_test_cookie, wp_woocommerce_session_, AKDC, akavpau_ppsd

Functionality

WordPress cookie created when auto-saving a post in the editor.

wp-saving-post, wp-settings-, wp-settings-time-

Performance

google analytic

__utma,__utmb,__utmc,__utmz,_ga,_gid,_gat

Advertising