Optimal bitmap size

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Optimal bitmap size

Jon...
Just a quick question for the techy's who know anything about the internals of the current crop of flash players (8,9 or 10).
Is there an optimal size for bitmaps (powers of 2, less than 1024 etc) when using them as a BitmapData class.
 
I've decided to use Hugh's method of one Bitmap per screen and using the PixelCopy function to "blit" my "sprite" data about,
before I go through all the hassle of laying out my tpage(s) and generating rectangle coords I was just wondering if there
was any particular size I should aim for / things to be aware of.
 
TIA
 
Jon...
 

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Optimal bitmap size

Kelvin Luck
On Mon, 17 Nov 2008 07:24:07 -0800, Jon... <[hidden email]> wrote:

> Just a quick question for the techy's who know anything about the internals
> of the current crop of flash players (8,9 or 10).
> Is there an optimal size for bitmaps (powers of 2, less than 1024 etc) when
> using them as a BitmapData class.
>
> I've decided to use Hugh's method of one Bitmap per screen and using the
> PixelCopy function to "blit" my "sprite" data about,
> before I go through all the hassle of laying out my tpage(s) and generating
> rectangle coords I was just wondering if there
> was any particular size I should aim for / things to be aware of.
>
> TIA
>
> Jon...
>

The only thing that I'm aware of is that for mip-mapping to work in flash player 9+ then your image size need to be a power of 2:

http://www.kaourantin.net/2007/06/mip-map-what.html

Only relevant if you are planning on scaling any of your images down significantly...

Cheers,

Kelvin :)

--
haXe - an open source web programming language
http://haxe.org
Reply | Threaded
Open this post in threaded view
|

Re: Optimal bitmap size

Tony Polinelli
Might not help you, but we're working on a game which requires the rasterization of pretty huge background vector artwork, which is scrolled. We found that cutting the tiles as big as possible - about 2000px square gave the best game performance - compared to a greater number of smaller tiles. Larger tiles took longer to rasterize, and waay longer to apply effects, but overall best performance, so dont be scared of larger bitmaps in flsh it seems




On Tue, Nov 18, 2008 at 3:40 AM, Kelvin Luck <[hidden email]> wrote:
On Mon, 17 Nov 2008 07:24:07 -0800, Jon... <[hidden email]> wrote:

> Just a quick question for the techy's who know anything about the internals
> of the current crop of flash players (8,9 or 10).
> Is there an optimal size for bitmaps (powers of 2, less than 1024 etc) when
> using them as a BitmapData class.
>
> I've decided to use Hugh's method of one Bitmap per screen and using the
> PixelCopy function to "blit" my "sprite" data about,
> before I go through all the hassle of laying out my tpage(s) and generating
> rectangle coords I was just wondering if there
> was any particular size I should aim for / things to be aware of.
>
> TIA
>
> Jon...
>

The only thing that I'm aware of is that for mip-mapping to work in flash player 9+ then your image size need to be a power of 2:

http://www.kaourantin.net/2007/06/mip-map-what.html

Only relevant if you are planning on scaling any of your images down significantly...

Cheers,

Kelvin :)

--
haXe - an open source web programming language
http://haxe.org



--
Tony Polinelli
http://www.touchmypixel.com

--
haXe - an open source web programming language
http://haxe.org