Flasher Archive

[Previous] [Next] - [Index] [Thread Index] - [Previous in Thread] [Next in Thread]


Subject: Re: FLASH: OT: bmp image scaling
From: Laura Mollett
Date: Sun, 27 Jun 1999 14:16:25 +0100

Hi John,

>> > How are you supposed to scale something with bitmaps?
>> > They get ugly.
> This is definately a possibility.

I don't believe I said it wasn't... that doesn't, however, preclude the
possibility of finding a technique that does allow some scaling of bmp
images.

>> Recently someone (Burt and I'm sorry I've lost his last name somehow) on the
>> hwg-techniques list put up a page with graphics that scale without too much
>> quality loss (there is still some) by allowing the browser to resize the
>> image (using %s in the width tag).
> Bitmaps unlike vectors do NOT scale well. The problem is compound by
> computer and browser differences. Bitmaps are created and optimized to
> display at a certain size. At their natural size they will display the
> best. Bitmaps in gif, png, jpeg whether inside Flash or not will behave
> and look their best when displayed at their natural size.

I'm aware of this. There are still occasions where flashers and non-flashers
alike would *like* to be able to allow a bmp image to be re-sized to fit
browser screens/resolution, and the solution Burt used works better than any
I've seen before.

> Checking how a
> bitmap scales on an individual computer is kind of irrelevant since that
> is just one case in thousands. Also, some bitmap pictures scale better
> than others and a pixel or two in the scale can make a lot of
> difference. Bitmaps in Flash often scale better than individual gifs and
> jpegs but this is not always the case.

Who said anything about an 'individual computer'? The 'test' was put up
*for* test on a list with at least as great a participancy as this one and
the results were uniformly found to be better. (Note, I did not say perfect,
but *I* find better to be an advantage.) Did you look at it? It works well
for me on both my computer at home and mine at work, and with my own images
previously used on other web sites. If it doesn't work for you, and on what
occasions it doesn't, I'd like to hear it, so there is a possibility of
getting better results. For example, some people on the list responded that
it did not work as well when the images are enlarged as it does when they're
scaled down. They suggested if the images were created as large as possible,
so they look well at that size, this might work somewhat better.

>> The trick seems to have been to provide a
>> width percentage but not height, keeping the proportions the same but
>> allowing scaling.
> Keeping porportions the same is not a trick but a requirement.

I used the term 'trick' rather loosely, but the point is, the method of use
seems to be to ask the browser to scale width but not height, which *does*
keep the proportions the same while scaling the image to fit the viewers
browser window.

> If scale
> doesn't work out evenly, it may be better to use only one parameter but
> this may slow down displaying the graphic in some cases.

I didn't find any noticeable difference in speed, but I didn't test for that
either. If it does slow down the display, that could certainly be a problem,
especially in flash movies where quick display is so important, but it's
certainly worth trying and determining if the speed trade-off is worth the
ability to resize or not.

> If this trick allows better overall web display of bitmaps by allowing
> browsers to calculate the height it has nothing to do with bitmaps in
> Flash.

Doesn't it? I did put an OT header in the subject line. However, when we
export flash movies and we want them to scale, we do so by telling the width
and height of the browser screen to be 100% x 100% in order to fill the
window with the movie. There is no reason I can see that it could not be
told to be width=100% and nothing for height, if the flash movie contains
bitmap backgrounds. I intend to try it in any case, because as much as I
enjoy vectors, I find there are occasions when I need to use bmps and I
would like to allow some scaling of those movies if at all possible. If the
need for the browser to calculate the height slows the load down
significantly, then I would need to weigh how slow it is against how badly I
want the movie to scale, but I do think it's worth some effort to find out.

> I expect that this 'trick' has the value I have been placing on
> it and it is better than scaling using numbers are not at the exact same
> ratio.

I'm sorry, but I'm having trouble parsing this sentence. Do you mean you
think it will or won't work better?

> A picture should scale well from 200x400 to 100x200.
> But if you need to reduce 177x231 by half there is no exact pixel
> numbers. You have to be off.

Yes, and you somehow need to allow the browser to determine whether the
movie should be displayed at 100x200 or 200x400 for a specific user.
Unfortunately 100% x 100% makes a mess of bmp images. However, if the
browser can be made to calculate the proportions and keep them in scale
without unduly slowing down the process, then you will always have a
proportionate image for the viewer. You would need to make sure your images
or your movie space works well on screen, which is wider than it is tall, or
you'll end up with scrollbars, but then we should be designing for that
anyway.

I have, to this point, been exporting flash movies at 100% x 100% to fill
the screen only if they are completely vector, and chosing an absolute size
(usually the default size to make sure the movie is small enough for some of
our banks which are still using very tiny screens) when it includes bmp
images. I would like to be able to allow a movie with bmp background images
(when the bank tells me, 'I don't care if vectors are better, we want a
photos of our community in there') to scale and there are ways to build
images so that they do not require extreme sharpness to make up for some
degredation of images. However, what one gets when one allows
out-of-proportion scaling of bmps (100% x 100%) is not acceptable even in
these cases. This method, which keeps the images in proportion, might work.
My personal testing of it is still in the baby stage, but I thought other
people might like to try it as well.

Laura

------------------------------------------------------------------------
To UNSUBSCRIBE send: unsubscribe flasher in the body of an
email to list-manageratshocker [dot] com. Problems to: owneratshocker [dot] com
N.B. Email address must be the same as the one you used to subscribe.
For info on digest mode send: info flasher to list-manageratshocker [dot] com


[Previous] [Next] - [Index] [Thread Index] - [Next in Thread] [Previous in Thread]