aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorinmarket <andrewh@inmarket.com.au>2013-07-22 17:05:42 +1000
committerinmarket <andrewh@inmarket.com.au>2013-07-22 17:05:42 +1000
commit25a01150144aa713a92c24535e0ed64755f5ea5c (patch)
tree3d65709e1fa4fc146b6320a564f0dcd59a87b3a4 /include
parent79612419893f14bb5026e977d2e569519096b4fd (diff)
downloaduGFX-25a01150144aa713a92c24535e0ed64755f5ea5c.tar.gz
uGFX-25a01150144aa713a92c24535e0ed64755f5ea5c.tar.bz2
uGFX-25a01150144aa713a92c24535e0ed64755f5ea5c.zip
This image wrapper really is meant to be there and is used by some demo apps (notepad-2)
Diffstat (limited to 'include')
-rw-r--r--include/gwin/gwin.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/include/gwin/gwin.h b/include/gwin/gwin.h
index de4b6387..372ece9c 100644
--- a/include/gwin/gwin.h
+++ b/include/gwin/gwin.h
@@ -766,6 +766,39 @@ extern "C" {
#endif
/*-------------------------------------------------
+ * Image functions
+ *-------------------------------------------------*/
+
+ #if GDISP_NEED_IMAGE || defined(__DOXYGEN__)
+ /**
+ * @brief Draw the image
+ * @return GDISP_IMAGE_ERR_OK (0) on success or an error code.
+ *
+ * @param[in] gh The window handle
+ * @param[in] img The image structure
+ * @param[in] x,y The window location to draw the image
+ * @param[in] cx,cy The area on the screen to draw
+ * @param[in] sx,sy The image position to start drawing at
+ *
+ * @pre gdispImageOpen() must have returned successfully.
+ *
+ * @note If sx,sy + cx,cy is outside the image boundaries the area outside the image
+ * is simply not drawn.
+ * @note If @p gdispImageCache() has been called first for this frame, this routine will draw using a
+ * fast blit from the cached frame. If not, it reads the input and decodes it as it
+ * is drawing. This may be significantly slower than if the image has been cached (but
+ * uses a lot less RAM)
+ *
+ * @api
+ */
+ gdispImageError gwinDrawImage(GHandle gh, gdispImage *img, coord_t x, coord_t y, coord_t cx, coord_t cy, coord_t sx, coord_t sy);
+ #endif
+
+#ifdef __cplusplus
+}
+#endif
+
+/*-------------------------------------------------
* Additional functionality
*-------------------------------------------------*/