mirror of https://github.com/jscrane/r65emu.git
bugfixes
This commit is contained in:
parent
12f9989a1d
commit
3af6b4d3f7
12
display.cpp
12
display.cpp
|
@ -74,6 +74,7 @@ void Display::begin(colour_t bg, colour_t fg, orientation_t orient) {
|
||||||
|
|
||||||
#if defined(USE_UTFT)
|
#if defined(USE_UTFT)
|
||||||
utft.InitLCD(orient);
|
utft.InitLCD(orient);
|
||||||
|
utft.setBackColor(_bg);
|
||||||
_dx = utft.getDisplayXSize();
|
_dx = utft.getDisplayXSize();
|
||||||
_dy = utft.getDisplayYSize();
|
_dy = utft.getDisplayYSize();
|
||||||
|
|
||||||
|
@ -107,8 +108,7 @@ void Display::begin(colour_t bg, colour_t fg, orientation_t orient) {
|
||||||
_dx = canvas.getWidth();
|
_dx = canvas.getWidth();
|
||||||
_dy = canvas.getHeight();
|
_dy = canvas.getHeight();
|
||||||
|
|
||||||
DBG(printf("w %d h %d", _dx, _dy));
|
DBG(printf("w %d h %d\r\n", _dx, _dy));
|
||||||
DBG(println());
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
setColor(fg);
|
setColor(fg);
|
||||||
|
@ -194,7 +194,7 @@ void Display::drawCircle(unsigned x, unsigned y, unsigned r, colour_t col) {
|
||||||
espi.drawCircle(x, y, r, col);
|
espi.drawCircle(x, y, r, col);
|
||||||
#elif defined(USE_VGA)
|
#elif defined(USE_VGA)
|
||||||
canvas.setPenColor(rgb(col));
|
canvas.setPenColor(rgb(col));
|
||||||
canvas.fillEllipse(x, y, r, r);
|
canvas.drawEllipse(x, y, r, r);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -208,7 +208,7 @@ void Display::fillCircle(unsigned x, unsigned y, unsigned r, colour_t col) {
|
||||||
espi.fillCircle(x, y, r, col);
|
espi.fillCircle(x, y, r, col);
|
||||||
#elif defined(USE_VGA)
|
#elif defined(USE_VGA)
|
||||||
canvas.setBrushColor(rgb(col));
|
canvas.setBrushColor(rgb(col));
|
||||||
canvas.drawEllipse(x, y, r, r);
|
canvas.fillEllipse(x, y, r, r);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -222,7 +222,7 @@ void Display::drawRectangle(unsigned x, unsigned y, unsigned w, unsigned h, colo
|
||||||
espi.drawRect(x, y, w, h, col);
|
espi.drawRect(x, y, w, h, col);
|
||||||
#elif defined(USE_VGA)
|
#elif defined(USE_VGA)
|
||||||
canvas.setPenColor(rgb(col));
|
canvas.setPenColor(rgb(col));
|
||||||
canvas.fillRectangle(x, y, x+w, y+h);
|
canvas.drawRectangle(x, y, x+w, y+h);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -236,7 +236,7 @@ void Display::fillRectangle(unsigned x, unsigned y, unsigned w, unsigned h, colo
|
||||||
espi.fillRect(x, y, w, h, col);
|
espi.fillRect(x, y, w, h, col);
|
||||||
#elif defined(USE_VGA)
|
#elif defined(USE_VGA)
|
||||||
canvas.setBrushColor(rgb(col));
|
canvas.setBrushColor(rgb(col));
|
||||||
canvas.drawRectangle(x, y, x+w, y+h);
|
canvas.fillRectangle(x, y, x+w, y+h);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue