Normal quotes
This commit is contained in:
parent
5e10794a24
commit
18011c595a
352 changed files with 6040 additions and 6040 deletions
18
32-02.md
18
32-02.md
|
|
@ -22,10 +22,10 @@
|
|||
READ_MAP equ 4 ;Read Map register index in GC
|
||||
SCREEN_WIDTH equ 360 ;# of pixels across screen
|
||||
WORD_OUTS_OK equ 1 ;set to 0 to assemble for
|
||||
; computers that can’t handle
|
||||
; computers that can't handle
|
||||
; word outs to indexed VGA registers
|
||||
;
|
||||
_DATAsegmentpublic byte ‘DATA’
|
||||
_DATAsegmentpublic byte ‘DATA'
|
||||
;
|
||||
; 360x480 256-color mode CRT Controller register settings.
|
||||
; (Courtesy of John Bridges.)
|
||||
|
|
@ -65,7 +65,7 @@
|
|||
endif
|
||||
endm
|
||||
;
|
||||
_TEXTsegment byte public ‘CODE’
|
||||
_TEXTsegment byte public ‘CODE'
|
||||
assumecs:_TEXT, ds:_DATA
|
||||
;
|
||||
; Sets up 360x480 256-color mode.
|
||||
|
|
@ -136,7 +136,7 @@
|
|||
;
|
||||
public _Draw360x480Dot
|
||||
_Draw360x480Dotprocnear
|
||||
push bp ;preserve caller’s BP
|
||||
push bp ;preserve caller's BP
|
||||
mov bp,sp ;point to stack frame
|
||||
push si ;preserve C register vars
|
||||
push di
|
||||
|
|
@ -150,7 +150,7 @@
|
|||
mov di,[bp+DrawX] ;get the X coordinate
|
||||
shr di,1 ;there are 4 pixels at each address
|
||||
shr di,1 ; so divide the X coordinate by 4
|
||||
add di,ax ;point to the pixel’s address
|
||||
add di,ax ;point to the pixel's address
|
||||
mov cl,byte ptr [bp+DrawX] ;get the X coordinate again
|
||||
and cl,3 ;get the plane # of the pixel
|
||||
mov ah,1
|
||||
|
|
@ -164,7 +164,7 @@
|
|||
stosb ;draw the pixel
|
||||
pop di ;restore C register vars
|
||||
pop si
|
||||
pop bp ;restore caller’s BP
|
||||
pop bp ;restore caller's BP
|
||||
ret
|
||||
_Draw360x480Dotendp
|
||||
;
|
||||
|
|
@ -184,7 +184,7 @@
|
|||
;
|
||||
public _Read360x480Dot
|
||||
_Read360x480Dotprocnear
|
||||
push bp ;preserve caller’s BP
|
||||
push bp ;preserve caller's BP
|
||||
mov bp,sp ;point to stack frame
|
||||
push si ;preserve C register vars
|
||||
push di
|
||||
|
|
@ -198,7 +198,7 @@
|
|||
mov si,[bp+DrawX] ;get the X coordinate
|
||||
shr si,1 ;there are 4 pixels at each address
|
||||
shr si,1 ; so divide the X coordinate by 4
|
||||
add si,ax ;point to the pixel’s address
|
||||
add si,ax ;point to the pixel's address
|
||||
mov ah,byte ptr [bp+DrawX] ;get the X coordinate again
|
||||
and ah,3
|
||||
;get the plane # of the pixel
|
||||
|
|
@ -210,7 +210,7 @@
|
|||
sub ah,ah ;make the return value a word for C
|
||||
pop di ;restore C register vars
|
||||
pop si
|
||||
pop bp ;restore caller’s BP
|
||||
pop bp ;restore caller's BP
|
||||
ret
|
||||
_Read360x480Dot endp
|
||||
_TEX Tends
|
||||
|
|
|
|||
Loading…
Reference in a new issue