Skip navigation
Currently Being Moderated

Help deciding whether to use vector/bitmap when using createjs to export to html5

Apr 18, 2013 12:07 AM

I am trying to use the createjs exporter to create an html5 click and explore application. I am trying to educate myself on whether to use bitmap or vector for my various componenets I see general information that bitmap creates extra memory and vector is processor intensive (especially on mobil), but I'd like to have a deeper understanding so I can make better decisions.  I also see support for drop-shadow and perhaps some layer blending - and I'm curious how that impacts perfomance as well.  This project will basically be a background image with various multiframe sprites animating on screen. Is there any instance where I should use vector for my background image - or is that a death sentence for mobile devices? Are there any circumstances where its prefeable to use vector in my animations?  What's worse on mobile performance - a fullscreen vector background or a small multi-frame vector sprite? 

 

I'm ready to start this project (which is intended to display in both PC and mobile as html5), but I'm trying to decide if its wise to do any of this in vector, or just convert everything to bitmap.

 

Does anyone either have any advice or have any existing discussions or documentation you can refer me to?

 

Thank you.

 
Replies
  • kglad
    72,188 posts
    Jul 21, 2002
    Currently Being Moderated
    Apr 18, 2013 6:40 AM   in reply to gigasaurus

    the only way to know whether adding a feature (like drop-shadow) will ruin your app is to try it.

     

    there's probably no instance where a vector background image will perform as well a bitmap.  but, your bitmap's memory requirements can't exceed the available memory and, to call something a background image means, the background image is always in the background and its bitmap representation doesn't change frequently.

     

    because it's so much easier to use vectors with flash, you would usually create a mostly vectorized app (using the cacheAsBitmap and cacheAsBitmapMatrix everywhere it's helpful but being mindful of the limited memory you can use) and test performance frequently during development.  if performance is adequate, you're good. 

     

    if performance is unacceptable, you'll need to check if you're exceeding the available memory and losing the benefit of cacheAsBitmap or if you're putting to much strain on the processor using vector manipulations.

     
    |
    Mark as:
  • kglad
    72,188 posts
    Jul 21, 2002
    Currently Being Moderated
    Apr 18, 2013 11:29 AM   in reply to gigasaurus

    yes, they apply to apps made for mobiles and desktops/laptops.

     

    the biggest difference between creating apps for mobiles and non-mobiles is you're much more likely to need to optimize when creating mobile apps because mobiles have poor performance and limited memory compared to desktops/laptops.

     
    |
    Mark as:

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points