Library to control a Graphics TFT connected to 4-wire SPI - revised for the Raio RA8875 Display Controller.
Dependents: FRDM_RA8875_mPaint RA8875_Demo RA8875_KeyPadDemo SignalGenerator ... more
Fork of SPI_TFT by
See Components - RA8875 Based Display
Enhanced touch-screen support - where it previous supported both the Resistive Touch and Capacitive Touch based on the FT5206 Touch Controller, now it also has support for the GSL1680 Touch Controller.
Offline Help Manual (Windows chm)
/media/uploads/WiredHome/ra8875.zip.bin (download, rename to .zip and unzip)
Diff: GraphicsDisplay.cpp
- Revision:
- 136:224e03d5c31f
- Parent:
- 122:79e431f98fa9
- Child:
- 142:6e9bff59878a
- Child:
- 145:5eb2492acdda
--- a/GraphicsDisplay.cpp Sun Nov 13 02:06:30 2016 +0000 +++ b/GraphicsDisplay.cpp Wed Nov 16 02:48:45 2016 +0000 @@ -336,8 +336,8 @@ // Define window for top to bottom and left to right so writing auto-wraps rect_t restore = windowrect; window(x,y, PixelWidth,PixelHeight); - SetGraphicsCursor(x, y); - _StartGraphicsStream(); +// SetGraphicsCursor(x, y); +// _StartGraphicsStream(); //start_data = BMP_Info.bfOffBits; //HexDump("Raw Data", (uint8_t *)&start_data, 32); @@ -353,8 +353,7 @@ uint8_t dPix = lineBuffer[i/8]; uint8_t bMask = 0x80 >> (i % 8); uint8_t bit = (bMask & dPix) ? 0 : 1; - //INFO("%02X & %02X ? => %02X", dPix, bMask, bit); - pixelBuffer[i] = RGBQuadToRGB16(colorPalette, bit); + pixelBuffer[i] = RGBQuadToRGB16(colorPalette, bit); } else if (BPP_t == 4) { uint8_t dPix = lineBuffer[i/2]; if ((i & 1) == 0) @@ -373,7 +372,7 @@ } pixelStream(pixelBuffer, PixelWidth, x, y++); } - _EndGraphicsStream(); +// _EndGraphicsStream(); window(restore); free(pixelBuffer); // don't leak memory free(lineBuffer); @@ -419,7 +418,8 @@ INFO("jd_prepare returned %d", r); if (r == noerror) { - SetGraphicsCursor(x,y); + img_x = x; // save the origin for the privOutput function + img_y = y; r = (RetCode_t)jd_decomp(jdec, NULL, 0); } else { r = not_supported_format; // error("jd_prepare error:%d", r);