Exploring Graphics Modes

Graphics mode 0/1 - Text mode
Modes 0 and 1 are called text mode (aka 1bpp tile mode). In mode 0, each bit specifies a pixel, where the color is either the foreground or background color. Foreground and background colors may be chosen from a set of 16 predefined colors. In mode 1, only a foreground color may be specified, with background being fixed. The foreground pallet is, however, expanded to 256 colors. 10 REM TODO, ADD MODE 0 EXAMPLE (IGNORE MODE 1, IS BASICALLY SAME) TODO explain example line by line

Graphics mode 2/3/4 - Tile mode
Paletted tile modes (2bpp, 4bpp, 8bpp) allow for 4, 16 or 256 colors per tile pixel. 10 REM TODO, ADD MODE 3 EXAMPLE (IGNORE 2 & 4, ARE BASICALLY SAME) TODO explain example line by line

Graphics mode 5/6/7 - Bitmap
Bitmap modes allow drawing direct pixel data in 2, 4 and 8bpp formats. The following is a small BASIC program that sets up VERA Layer 1 (foreground) in mode 6 (4bpp bitmap) and draws a line at the top of the screen. After showing the line, the program waits for the user to hit RETURN before cleaning up (turning off layer 1 and resetting screen scale). 10 PRINT "{clear}" 20 VPOKE $F,$3000,193 25 VPOKE $F,$3001,0 30 VPOKE $F,1,64:VPOKE $F,2,64 40 VPOKE $F,$3005,%01000000 60 GOSUB 1000 110 INPUT A$ 120 VPOKE $F,$3000,0 130 VPOKE $F,1,128:VPOKE $F,2,128 999 END 1000 FOR I=0 TO 159 1010 VPOKE 1,I,$11 1020 NEXT 1030 RETURN TODO explain example line by line