'=========================================================================== ' Subject: TGA VIEWER (320X200) Date: 02-10-94 (11:50) ' Author: Jeff Lawson Code: QB, QBasic, PDS ' Origin: x2ftp.oulu.fi Packet: GRAPHICS.ABC '=========================================================================== DEFINT A-Z CONST FontHeight = 23 CONST ScreenWidth = 320 / 4 SCREEN 13 'display the bitmap OPEN "BIGHEART.TGA" FOR BINARY AS #1 SEEK #1, 19 FOR Attr = 0 TO 255 Value$ = SPACE$(3) GET #1, , Value$ Red& = ASC(MID$(Value$, 3)) Green& = ASC(MID$(Value$, 2)) Blue& = ASC(MID$(Value$, 1)) OUT &H3C8, Attr OUT &H3C9, Red& OUT &H3C9, Green& OUT &H3C9, Blue& 'PALETTE Attr, 65535 * Blue& + 256 * Green& + Red& NEXT Attr SEEK #1, 19 + 768: A$ = " " FOR Row = 0 TO 199 FOR Col = 0 TO 319 GET #1, , A$ PSET (Col, Row), ASC(A$) NEXT Col NEXT Row CLOSE #1