// 在窗口内绘制线框,黑色边框 tft.drawFastHLine(0, 34, 240, TFT_BLACK); // 在屏幕上从(0,34)这个点开始,绘制一条长度为240像素,颜色为黑色的水平线条 tft.drawFastVLine(150, 0, 34, TFT_BLACK); // 在屏幕上从(150,0)这个点开始,绘制一条长度为34像素,颜色为黑色的垂直线条 tft.d
void setViewport(int32_t x, int32_t y, int32_t w, int32_t h, bool vpDatum = true); //设置 TFT 屏幕的裁剪区域 bool checkViewport(int32_t x, int32_t y, int32_t w, int32_t h); //检查指定区域在窗口中是否可见 int32_t getViewportX(void); int32_t getViewportY(void); int...
240 x 320 83 - #define TFT_HEIGHT 240 // GC9A01 240 x 240 85 + // #defineTFTHEIGHT 240 // GC9A01 240 x240 8685 87 // For ST7735 ONLY, define the type of display, originally this was based on the 86 88// colour of the tab on the screenprotector film but ...
"Viewport_Demo" sketch void setViewport(int32_t x, int32_t y, int32_t w, int_t h, bool vpDatum = true); bool checkViewport(int_t x, int32_ y, int32_t w,32_t h); int32_t getViewportX(void); int32_t getViewportY(void;...
Viewports can now be applied to sprites e.g. spr.setViewport(5, 5, 20, 20); so graphics can be restricted to a particular area of the sprite. This operates in the same way as the TFT viewports, see 5. below. The library now provides a "viewport" capability. See "Viewport_Demo" an...
"Viewport_Demo" sketch void setViewport(int32_t x, int32_t y, int32_t w, int_t h, bool vpDatum = true); bool checkViewport(int_t x, int32_ y, int32_t w,int32_t h); int32_t getViewportX(void); int32_t getViewportY(void; int32_t getViewportWidth(void);...
0,0,watchtop, sizeof(watchtop)); TJpgDec.drawJpg(0,220,watchbottom, sizeof(watchbottom)); //绘制一个视口 tft.setViewport(0, 20, 240, 200); tft.fillScreen(0x0000); tft.fillRoundRect(0,0,240,200,5,bgColor);//实心圆角矩形 //tft.resetViewport(); //绘制线框 tft.drawFastHLine(0...
Demo" sketch void setViewport(int32_t x, int32_t y, int32_t , int32_t h, bool vpDatum = true); bool checkViewport(int32_t x, int32_t y, int32_t w, int32_th); int32_t getViewportX(void); int32_t getViewportY(void); int32_t getViewportWidth(void); ...