blob: aa8490e6a91485f7f90fab5d8fcbed769b7ffd40 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
module src/renderer
/*
The Renderer for the Chip8 emulator.
To support multiple backends, we define a Renderer interface.
Every backend must implement this interface.
*/
import bytearray
interface Renderer {
def init(run: (ByteArray) => Unit at {io, global}): Unit
def clear(): Unit
def draw(x: Int, y: Int): Unit
def fill(color: String): Unit
def update(): Unit
def log(msg: String): Unit
}
|