Correct use of bitmap buffering-accelerated flash

Source: Internet
Author: User
Tags window

Bitmap buffering (Bitmap Caching)

How does a flash animation play? In fact, it is the Flash Player to the source file can see the frame of a frame of the picture, of course, before the drawing need to process each frame within the code

Flash playback speed by what decision

The speed of a flash display is determined by the FPS set by the creator, but because of the difference between the machine configuration and the operating system, the FPS may be set too high in some low configuration machines, and in fact, All set FPS is actually the maximum frame frequency that flash can play to. In the same environment, the complexity of the picture determines the speed of the drawing.

The meaning of bitmap buffering

Because most of the flash is vector computing, so when drawing a very complex picture, or frequently copy some of the screen, it is bound to use a lot of time, and these times should be omitted. Bitmap buffering design is aimed at this, he can put an MC, first draw again, The information is placed in a prepared device, and when the MC is reused without shape change, Flash player does not redraw the MC each time, but reads the information from the device and displays it, which greatly increases the speed
The usefulness of bitmap buffering

Imagine, in an application that is full of Windows components, each window can be dragged and dragged, this time if not set bitmap buffer, then it is conceivable that Flash player in each frame, all the window components to the screen, a draw, it is very scary!

Bitmap buffer points of attention

Help inside also said, for very little use of rotation, scaling, variant of the MC use bitmap buffer will greatly improve the speed, this is also because, if the above operation, it destroys the shape of the MC, Flash player has to go back to "know" the MC, the result of this, Might be worse than not having a bitmap buffer set.

Use of bitmap buffering

In the Flash IDE Select a MC,CTRL+F3 (property panel), the hook-and-click Bitmap Buffer (CACHEASBITMAP) can be as words Mc.cacheasbitmap = True can be two are connected, When Cacheasbitmap is already selected in the IDE, the Mc.cacheasbitmap in the program is already true, and vice versa

Animation understanding:http://weblogs.macromedia.com/md/archives/2005/10/flash_8_animati_3.cfm
Application Example of bitmap buffering:http://www.flashguru.co.uk/maelstrom/?example=isometric%20grid%20image
Reference article:http://mxdj.sys-con.com/read/142694.htm



Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.