IAT167-Week 12 Lecture 1 and 2.docx

27 views2 pages
Week 12 Lecture 1 and 2
Bitmaps and Blitting
Re-add block events
Gameplay Solution
Programmatic Solution
Bitmap
Image file format / Memory organization
Mapped array of bits / pixels
Spatially mapped
BMP, PNG, GIF
Blitting
Blit to take a map of bits and move it around in memory
Screen memory
Sprite memory
Flash Sprites are software sprites drawn to the screen every frame
Flash uses screen invalidation to mark areas of the screen for refreshing
Full screen blit
Highest performance
Inflexible
Bitmap Tile sheet
Flexibility
Background tiles
Sprites with Transparency (PNG)
Bitmaps in Flash BitmapData
BitmapData Object
BitmapData > Object
Separates bitmap rendering operations from display updating routines, thus does not incur the
per-frame overhead of constantly redrawing vectored content
Bitmaps in Flash Bitmap Object
Bitmap Object
Bitmap > DisplayObject > EventDispatcher > Object
Can be loaded with bitmap data for display
Loading a Bitmap
[Embed]
BitmapAsset > Bitmap > DisplayObject > …
Embedding includes the asset in the SWF file
Associated the image with a variable:
Unlock document

This preview shows half of the first page of the document.
Unlock all 2 pages and 3 million more documents.

Already have an account? Log in

Get access

Grade+
$10 USD/m
Billed $120 USD annually
Homework Help
Class Notes
Textbook Notes
40 Verified Answers
Study Guides
1 Booster Class
Class+
$8 USD/m
Billed $96 USD annually
Homework Help
Class Notes
Textbook Notes
30 Verified Answers
Study Guides
1 Booster Class