; CSC 111 Assignment 3: The Truth is Out There ; ; Due Wednesday 3/13/02 ; ; 1. (warmup). Write a program using vga mode 13h to make the entire screen ; blue. For this part, you should take advantage of the fact that you ; have a 32-bit machine and transfer the bytes four at a time. ; 2. Write a procedure to display a 256-color bitmap onto the screen. ; The first 4 bytes of the bitmap represents the dimensions of the bit ; map (two bytes for height, followed by two bytes for width - see example ; below for clarification). Bytes with value 0 should be interpreted as ; transparent. Your procedure should work with bitmaps of any dimension. ; It should take in as parameters the starting address of the bitmap, and ; the x,y coordinates of the top left corner where the bitmap should be ; displayed. ; 3. Animate the flying saucer bitmap below by having it move up the ; screen smoothly. Use a delay between frames. To animate, you need ; to erase the old image before drawing the new image in a new position. ; You must preserve the original background. You may consider drawing ; a blue rectangle, or simply repaint the entire background. If you're ; ambitious you can try double-buffering and other techniques. ; You are free to add more complexity to the animation (of course). You ; can also alter the bitmap and/or use more than one bitmap. ; flying saucer bitmap .data ; use this 24x9 bit map for the shape of a flying saucer (you can ; change it of course). Can you figure out a way to interpret 00 as ; transparent instead of as color black? shape db 9,0,24,0 db 00,00,00,00,00,00,00,00,00,00,04,04,04,04,04,00,00,00,00,00,00,00,00,00 db 00,00,00,00,00,00,00,00,04,04,04,04,04,04,04,04,04,00,00,00,00,00,00,00 db 00,00,00,00,00,00,00,00,04,04,04,04,04,04,04,04,04,00,00,00,00,00,00,00 db 00,00,00,00,00,00,04,04,04,04,02,04,02,04,02,04,04,04,04,00,00,00,00,00 db 00,00,04,04,04,04,04,04,04,04,02,04,04,04,02,04,04,04,04,04,04,04,04,00 db 00,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04 db 00,00,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,04,00 db 00,00,00,00,00,00,00,04,00,00,00,00,00,00,00,00,00,04,00,00,00,00,00,00 db 00,00,00,00,00,00,04,00,00,00,00,00,00,00,00,00,00,00,04,00,00,00,00,00