flex-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alex Harui <aha...@adobe.com>
Subject Re: Flex mobile performance - Question on itemRenderers
Date Mon, 22 Jul 2013 14:53:06 GMT

On 7/22/13 6:16 AM, "Christian Kiefer" <christian.kiefer@goal-games.de>

>Turning of cacheAsBitmap
>-> Scrolling got much slower (in the renderer there is nothing
>Am I right when I think all the fxg files are cached and using bitmap
>images won't have any advantage (at least when cachingAsBitmap)?
Well, it isn't 'caching' per-se.  The fxg files should be converted to SWF
DefineSprites just like if you drew them in Flash Pro.  But because of the
excess Groups, there are a bunch more DefineSprites than you would
probably get if you did draw them in Flash Pro.

Simple test: comment out all fxg images or maybe just all but one per
renderer and see how performance changes.

Bitmaps could be faster assuming they are embedded or cached.  There is
always a trade-off between the size of the bitmaps and how fast the
renderer can draw them (which I believe is affected by whether there is
any scaling of the bitmap), and how many edges there are in the vector
description of the image.  For simple images, vector is smaller and faster
and can scale cleanly, but for complex images, the number of vectors can
bog down the renderer.  Basically it has to loop through every piece of
the paths, determine the exact pixel locations of the splines, then run
the scan-line edge detection on that database for every vertical row of
pixels.  A bitmap image only has four edges (assuming no transparency),
but if you are scaling it, it has to run image processing algorithms on
the pixels in the image.


View raw message