Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Old UpdateScreen with bad CGA snow
- /* extern void UpdateScreen(void);
- #pragma aux UpdateScreen = \
- "mov si, ScreenBuff" \
- "mov di, 00h" \
- "mov ax, [ScreenSeg]" \
- "mov es, ax" \
- "mov cx, SCREEN_SIZE" \
- "rep movsw" \
- modify [ax cx si di es]; */
- // This one should reduce CGA snow
- extern void UpdateScreen(void);
- #pragma aux UpdateScreen = \
- "mov si, ScreenBuff" \
- "mov di, 00h" \
- "mov ax, [ScreenSeg]" \
- "mov es, ax" \
- "mov cx, SCREEN_SIZE" \
- "mov dx, 03DAh" \
- "_blk:" \
- "in al, dx" \
- "test al, 9" \
- "jz _blk" \
- "movsw" \
- "movsw" \
- "movsw" \
- "movsw" \
- "sub cx, 4" \
- "jnz _blk" \
- modify [ax cx dx si di es];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement