MIDI Control Surface library for Arduino
|
Go to the documentation of this file.
31 virtual void clear() = 0;
38 virtual void drawPixel(int16_t x, int16_t y, uint16_t color) = 0;
45 virtual void setCursor(int16_t x, int16_t y) = 0;
54 size_t write(uint8_t c)
override = 0;
57 virtual void drawLine(int16_t x0, int16_t y0, int16_t x1, int16_t y1,
67 virtual void drawXBitmap(int16_t x, int16_t y,
const uint8_t bitmap[],
68 int16_t w, int16_t h, uint16_t color) = 0;
71 virtual void fillRect(int16_t x, int16_t y, int16_t w, int16_t h,
75 virtual void drawCircle(int16_t x0, int16_t y0, int16_t r, uint16_t color);
78 virtual void fillCircle(int16_t x0, int16_t y0, int16_t r, uint16_t color);
88 ERROR(
F(
"Error: This display is already enabled."), 0x1214);
98 ERROR(
F(
"Error: This display is already disabled."), 0x1215);
virtual void display()=0
Write the frame buffer to the display.
bool isEnabled()
Check if this display is enabled.
static DoublyLinkedList< DisplayInterface > elements
virtual void drawLine(int16_t x0, int16_t y0, int16_t x1, int16_t y1, uint16_t color)=0
Draw a line between two points.
virtual void clear()=0
Clear the frame buffer or display.
An interface for displays.
static void beginAll()
Initialize all displays.
virtual ~DisplayInterface()
virtual void drawPixel(int16_t x, int16_t y, uint16_t color)=0
Paint a single pixel with the given color.
size_t write(uint8_t c) override=0
Write a character to the display.
virtual void setCursor(int16_t x, int16_t y)=0
Set the cursor position.
#define BEGIN_CS_NAMESPACE
void append(Node *node)
Append a node to a linked list.
void enable()
Enable this display: insert it into the linked list of instances, so it gets updated automatically.
#define ERROR(msg, errc)
Print the error message and error code, and stop the execution if FATAL_ERRORS are enabled.
virtual void fillCircle(int16_t x0, int16_t y0, int16_t r, uint16_t color)
Draw a disk (filled circle).
void remove(Node *node)
Remove a node from the linked list.
virtual void drawFastVLine(int16_t x, int16_t y, int16_t h, uint16_t color)=0
Draw a vertical line.
void disable()
Disable this display: remove it from the linked list of instances, so it no longer gets updated autom...
virtual void drawXBitmap(int16_t x, int16_t y, const uint8_t bitmap[], int16_t w, int16_t h, uint16_t color)=0
Draw a bitmap to the display.
virtual void setTextColor(uint16_t color)=0
Set the text color.
virtual void begin()
Initialize the display.
void clearAndDrawBackground()
Clear the frame buffer, and draw the custom background.
A class that can be inherited from to allow inserting into a DoublyLinkedList.
virtual void fillRect(int16_t x, int16_t y, int16_t w, int16_t h, uint16_t color)
Draw a filled rectangle.
virtual void drawBackground()
Draw a custom background.
virtual void drawFastHLine(int16_t x, int16_t y, int16_t w, uint16_t color)=0
Draw a horizontal line.
bool couldContain(Node *node)
Check if the linked list could contain the given node.
virtual void setTextSize(uint8_t size)=0
Set the text size.
virtual void drawCircle(int16_t x0, int16_t y0, int16_t r, uint16_t color)
Draw a circle.