summaryrefslogtreecommitdiffstats
path: root/lib/gui/2d-primitives.c
Commit message (Collapse)AuthorAgeFilesLines
* 2d-primitives: fix no previous prototype warningSam Ravnborg2019-01-031-0/+2
| | | | | | | | | | | | | | | | Fix the following warnings: lib/gui/2d-primitives.c:88:6: warning: no previous prototype for ‘gu_draw_line’ [-Wmissing-prototypes] void gu_draw_line(struct screen *sc, ^~~~~~~~~~~~ lib/gui/2d-primitives.c:174:6: warning: no previous prototype for ‘gu_draw_circle’ [-Wmissing-prototypes] void gu_draw_circle(struct screen *sc, ^~~~~~~~~~~~~~ Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* 2d-primitives: fix typos in function names in commentsNikita Yushchenko2017-11-031-3/+3
| | | | | | | | This fixes gl_* -> gu_* in several places. Reported-by: Chris Healy <cphealy@gmail.com> Signed-off-by: Nikita Yushchenko <nikita.yoush@cogentembedded.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* 2d-primitives: fix missing pixel in gu_draw_line()Nikita Yushchenko2017-10-161-2/+2
| | | | | | | | | When drawing line from (x1, y1) to (x2, y2), pixel at (x2, y2) should be included. Signed-off-by: Nikita Yushchenko <nikita.yoush@cogentembedded.com> Tested-by: Chris Healy <[1]cphealy@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* 2d-primitives: check dimensions in __illuminateBastian Stender2017-02-241-0/+3
| | | | | | | | gl_draw_circle draws outside of the screen if the resolution is too low. This lead to memory corruption. Check the dimensions before drawing. Signed-off-by: Bastian Stender <bst@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* GUI: Add code to draw simple graphicsAndrey Smirnov2016-06-301-0/+199
Add code to draw simple graphics, namely lines(solid or dashed) and circles. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>