-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathopcodes.txt
52 lines (42 loc) · 1.44 KB
/
opcodes.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
FIF is a bytecode virtual machine based image codec.
EVERY fif file must begin with the following ASCII string "FastIF"
The 2 bytes after FastIF define OC Resolution (Actual x = 1st byte * 2, Actual y = 2nd byte * 4)
There are the following opcodes:
0x01 - Set background
Arguments:
byte - Red
byte - Green
byte - Blue
0x02 - Set foreground
Arguments:
byte - Red
byte - Green
byte - Blue
0x10 - Set line
Arguments:
byte - X
byte - Y
byte - Size
Size*byte - Pixels to start setting starting at that position.
Pixels are encoded using the lower byte of a UTF-8 braille character (U+2800 to U+28FF)
0x11 - Fill
Arguments:
byte - X
byte - Y
byte - Width
byte - Height
byte - Lower byte of a UTF-8 braille character
0x12 - Sleep
Arguments:
byte - Time * 100 (in seconds)
0x13 - Set vertical line
Argument:
byte - X
byte - Y
byte - Size
Size*byte - Pixels to start setting starting at that position.
Pixels are encoded using the lower byte of a UTF-8 braille character (U+2800 to U+28FF)
0x20 - Exit execution
0x40 - Decoder meta instruction
Argument:
8 bytes - Any data, up to the decoder to parse