projects
/
eradicate
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
menu
[eradicate]
/
src
/
dos
/
vga.h
1
#ifndef VGA_H_
2
#define VGA_H_
3
4
#include "inttypes.h"
5
6
int vga_setmode(int mode);
7
8
#ifdef __WATCOMC__
9
void vga_setpal(int16_t idx, uint8_t r, uint8_t g, uint8_t b);
10
#pragma aux vga_setpal = \
11
"test ax, 0x8000" \
12
"jnz skip_dacaddr" \
13
"mov dx, 0x3c8" \
14
"out dx, al" \
15
"skip_dacaddr:" \
16
"mov dx, 0x3c9" \
17
"mov al, bl" \
18
"shr al, 2" \
19
"out dx, al" \
20
"mov al, bh" \
21
"shr al, 2" \
22
"out dx, al" \
23
"mov al, cl" \
24
"shr al, 2" \
25
"out dx, al" \
26
parm[ax][bl][bh][cl] \
27
modify[dx];
28
#endif /* __WATCOMC__ */
29
30
#endif /* VGA_H_ */