-
Notifications
You must be signed in to change notification settings - Fork 42
Expand file tree
/
Copy pathTMS9918A.java
More file actions
90 lines (74 loc) · 3.18 KB
/
TMS9918A.java
File metadata and controls
90 lines (74 loc) · 3.18 KB
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
/**
* Java Grinder
* Author: Michael Kohn
* Email: mike@mikekohn.net
* Web: https://www.mikekohn.net/
* License: GPL
*
* Copyright 2014-2023 by Michael Kohn
*
*/
package net.mikekohn.java_grinder;
abstract public class TMS9918A
{
public static final int COLOR_TRANSPARENT = 0;
public static final int COLOR_BLACK = 1;
public static final int COLOR_MEDIUM_GREEN = 2;
public static final int COLOR_LIGHT_GREEN = 3;
public static final int COLOR_DARK_BLUE = 4;
public static final int COLOR_LIGHT_BLUE = 5;
public static final int COLOR_DARK_RED = 6;
public static final int COLOR_CYAN = 7;
public static final int COLOR_MEDIUM_RED = 8;
public static final int COLOR_LIGHT_RED = 9;
public static final int COLOR_DARK_YELLOW = 10;
public static final int COLOR_LIGHT_YELLOW = 11;
public static final int COLOR_DARK_GREEN = 12;
public static final int COLOR_MAGENTA = 13;
public static final int COLOR_GRAY = 14;
public static final int COLOR_WHITE = 15;
public static final int SPRITE_SIZE_8X8_SMALL = 0;
public static final int SPRITE_SIZE_8X8_BIG = 1;
public static final int SPRITE_SIZE_16X16_SMALL = 2;
public static final int SPRITE_SIZE_16X16_BIG = 3;
/** Standard Mode (Text) (32x24) */
public static final int MODE_0 = 0;
/** Text Mode (40x24) */
public static final int MODE_1 = 1;
/** Multicolor mode (64x48) */
public static final int MODE_2 = 2;
/** Bitmap mode (?) */
public static final int MODE_3 = 3;
protected TMS9918A() { }
//public static void clearScreen() { }
public static void print(String text) { }
public static void printChar(char c) { }
public static void setCursor(int x, int y) { }
public static void setGraphicsMode(int mode) { }
public static void clearScreen() { }
public static void plot(int x, int y, int color) { }
/** For mode 0, remove characters and set colors for drawing */
public static void initDisplay() { }
/** Set an 8x8 tile (8 bits) in the pattern table that can drawn to the
screen. */
public static void setPattern(int index, byte[] data) { }
/** Color table is 32 colors indexed from 0 to 31. The color is
8 bits where the upper 4 bits is color_1 and lower 4 bits are
color_0. */
public static void setColor(int index, int color) { }
/** Set the text color (in the upper 4 bits) and the background color
in the lower 4 bits. */
public static void setTextBackdropColor(int color) { }
/** Change visibility of a sprite. Sprite index can be between 0 and 32.
there are restrictions on the number of sprites that can be displayed
on a line. */
public static void setSpriteVisible(int index, boolean visible) { }
/** Sets what a sprite looks like. Takes an array of 8 or 32 bytes. */
public static void setSpriteImage(int index, byte[] image) { }
/** Sets the position on the screen where a sprite is seen. */
public static void setSpritePos(int index, int x, int y) { }
/** Sets the color (between 0 and 15) of the sprite. */
public static void setSpriteColor(int index, int color) { }
/** Sets if the sprite is 8x8 or 16x16 pixels. */
public static void setSpriteSize(int size) { }
}