microui  3.0.0
microui
ui_drawing_stub.h
1 /*
2  * Copyright 2023 MicroEJ Corp. All rights reserved.
3  * Use of this source code is governed by a BSD-style license that can be found with this software.
4  */
5 
6 #ifndef UI_DRAWING_STUB_H
7 #define UI_DRAWING_STUB_H
8 #ifdef __cplusplus
9 extern "C" {
10 #endif
11 
12 /*
13  * @file
14  * @brief Implementation of all drawing functions of ui_drawing.h (MicroUI and Drawing libraries).
15  * These are stubbed implementations, there is no error but the drawings are not performed. Useful to
16  * stub a drawing on a custom destination (custom GraphicsContext format not supported by the Graphics
17  * Engine).
18  * @author MicroEJ Developer Team
19  * @version 3.0.0
20  */
21 
22 // --------------------------------------------------------------------------------
23 // Includes
24 // --------------------------------------------------------------------------------
25 
26 #include "ui_drawing.h"
27 
28 // --------------------------------------------------------------------------------
29 // Public API
30 // --------------------------------------------------------------------------------
31 
32 /*
33  * @brief Stubbed implementation of writePixel. See ui_drawing.h
34  */
35 DRAWING_Status UI_DRAWING_STUB_writePixel(MICROUI_GraphicsContext* gc, jint x, jint y);
36 
37 /*
38  * @brief Stubbed implementation of drawLine. See ui_drawing.h
39  */
40 DRAWING_Status UI_DRAWING_STUB_drawLine(MICROUI_GraphicsContext* gc, jint startX, jint startY, jint endX, jint endY);
41 
42 /*
43  * @brief Stubbed implementation of drawHorizontalLine. See ui_drawing.h
44  */
45 DRAWING_Status UI_DRAWING_STUB_drawHorizontalLine(MICROUI_GraphicsContext* gc, jint x1, jint x2, jint y);
46 
47 /*
48  * @brief Stubbed implementation of drawVerticalLine. See ui_drawing.h
49  */
50 DRAWING_Status UI_DRAWING_STUB_drawVerticalLine(MICROUI_GraphicsContext* gc, jint x, jint y1, jint y2);
51 
52 /*
53  * @brief Stubbed implementation of drawRectangle. See ui_drawing.h
54  */
55 DRAWING_Status UI_DRAWING_STUB_drawRectangle(MICROUI_GraphicsContext* gc, jint x1, jint y1, jint x2, jint y2);
56 
57 /*
58  * @brief Stubbed implementation of fillRectangle. See ui_drawing.h
59  */
60 DRAWING_Status UI_DRAWING_STUB_fillRectangle(MICROUI_GraphicsContext* gc, jint x1, jint y1, jint x2, jint y2);
61 
62 /*
63  * @brief Stubbed implementation of drawRoundedRectangle. See ui_drawing.h
64  */
65 DRAWING_Status UI_DRAWING_STUB_drawRoundedRectangle(MICROUI_GraphicsContext* gc, jint x, jint y, jint width, jint height, jint cornerEllipseWidth, jint cornerEllipseHeight);
66 
67 /*
68  * @brief Stubbed implementation of fillRoundedRectangle. See ui_drawing.h
69  */
70 DRAWING_Status UI_DRAWING_STUB_fillRoundedRectangle(MICROUI_GraphicsContext* gc, jint x, jint y, jint width, jint height, jint cornerEllipseWidth, jint cornerEllipseHeight);
71 
72 /*
73  * @brief Stubbed implementation of drawCircleArc. See ui_drawing.h
74  */
75 DRAWING_Status UI_DRAWING_STUB_drawCircleArc(MICROUI_GraphicsContext* gc, jint x, jint y, jint diameter, jfloat startAngle, jfloat arcAngle);
76 
77 /*
78  * @brief Stubbed implementation of drawEllipseArc. See ui_drawing.h
79  */
80 DRAWING_Status UI_DRAWING_STUB_drawEllipseArc(MICROUI_GraphicsContext* gc, jint x, jint y, jint width, jint height, jfloat startAngle, jfloat arcAngle);
81 
82 /*
83  * @brief Stubbed implementation of fillCircleArc. See ui_drawing.h
84  */
85 DRAWING_Status UI_DRAWING_STUB_fillCircleArc(MICROUI_GraphicsContext* gc, jint x, jint y, jint diameter, jfloat startAngle, jfloat arcAngle);
86 
87 /*
88  * @brief Stubbed implementation of fillEllipseArc. See ui_drawing.h
89  */
90 DRAWING_Status UI_DRAWING_STUB_fillEllipseArc(MICROUI_GraphicsContext* gc, jint x, jint y, jint width, jint height, jfloat startAngle, jfloat arcAngle);
91 
92 /*
93  * @brief Stubbed implementation of drawEllipse. See ui_drawing.h
94  */
95 DRAWING_Status UI_DRAWING_STUB_drawEllipse(MICROUI_GraphicsContext* gc, jint x, jint y, jint width, jint height);
96 
97 /*
98  * @brief Stubbed implementation of fillEllipse. See ui_drawing.h
99  */
100 DRAWING_Status UI_DRAWING_STUB_fillEllipse(MICROUI_GraphicsContext* gc, jint x, jint y, jint width, jint height);
101 
102 /*
103  * @brief Stubbed implementation of drawCircle. See ui_drawing.h
104  */
105 DRAWING_Status UI_DRAWING_STUB_drawCircle(MICROUI_GraphicsContext* gc, jint x, jint y, jint diameter);
106 
107 /*
108  * @brief Stubbed implementation of fillCircle. See ui_drawing.h
109  */
110 DRAWING_Status UI_DRAWING_STUB_fillCircle(MICROUI_GraphicsContext* gc, jint x, jint y, jint diameter);
111 
112 /*
113  * @brief Stubbed implementation of drawImage. See ui_drawing.h
114  */
115 DRAWING_Status UI_DRAWING_STUB_drawImage(MICROUI_GraphicsContext* gc, MICROUI_Image* img, jint regionX, jint regionY, jint width, jint height, jint x, jint y, jint alpha);
116 
117 /*
118  * @brief Stubbed implementation of copyImage. See ui_drawing.h
119  */
120 DRAWING_Status UI_DRAWING_STUB_copyImage(MICROUI_GraphicsContext* gc, MICROUI_Image* img, jint regionX, jint regionY, jint width, jint height, jint x, jint y);
121 
122 /*
123  * @brief Stubbed implementation of drawRegion. See ui_drawing.h
124  */
125 DRAWING_Status UI_DRAWING_STUB_drawRegion(MICROUI_GraphicsContext* gc, jint regionX, jint regionY, jint width, jint height, jint x, jint y, jint alpha);
126 
127 /*
128  * @brief Stubbed implementation of drawThickFadedPoint. See ui_drawing.h
129  */
130 DRAWING_Status UI_DRAWING_STUB_drawThickFadedPoint(MICROUI_GraphicsContext* gc, jint x, jint y, jint thickness, jint fade);
131 
132 /*
133  * @brief Stubbed implementation of drawThickFadedLine. See ui_drawing.h
134  */
135 DRAWING_Status UI_DRAWING_STUB_drawThickFadedLine(MICROUI_GraphicsContext* gc, jint startX, jint startY, jint endX, jint endY, jint thickness, jint fade, DRAWING_Cap startCap, DRAWING_Cap endCap);
136 
137 /*
138  * @brief Stubbed implementation of drawThickFadedCircle. See ui_drawing.h
139  */
140 DRAWING_Status UI_DRAWING_STUB_drawThickFadedCircle(MICROUI_GraphicsContext* gc, jint x, jint y, jint diameter, jint thickness, jint fade);
141 
142 /*
143  * @brief Stubbed implementation of drawThickFadedCircleArc. See ui_drawing.h
144  */
145 DRAWING_Status UI_DRAWING_STUB_drawThickFadedCircleArc(MICROUI_GraphicsContext* gc, jint x, jint y, jint diameter, jfloat startAngle, jfloat arcAngle, jint thickness, jint fade, DRAWING_Cap start, DRAWING_Cap end);
146 
147 /*
148  * @brief Stubbed implementation of drawThickFadedEllipse. See ui_drawing.h
149  */
150 DRAWING_Status UI_DRAWING_STUB_drawThickFadedEllipse(MICROUI_GraphicsContext* gc, jint x, jint y, jint width, jint height, jint thickness, jint fade);
151 
152 /*
153  * @brief Stubbed implementation of drawThickLine. See ui_drawing.h
154  */
155 DRAWING_Status UI_DRAWING_STUB_drawThickLine(MICROUI_GraphicsContext* gc, jint startX, jint startY, jint endX, jint endY, jint thickness);
156 
157 /*
158  * @brief Stubbed implementation of drawThickCircle. See ui_drawing.h
159  */
160 DRAWING_Status UI_DRAWING_STUB_drawThickCircle(MICROUI_GraphicsContext* gc, jint x, jint y, jint diameter, jint thickness);
161 
162 /*
163  * @brief Stubbed implementation of drawThickEllipse. See ui_drawing.h
164  */
165 DRAWING_Status UI_DRAWING_STUB_drawThickEllipse(MICROUI_GraphicsContext* gc, jint x, jint y, jint width, jint height, jint thickness);
166 
167 /*
168  * @brief Stubbed implementation of drawThickCircleArc. See ui_drawing.h
169  */
170 DRAWING_Status UI_DRAWING_STUB_drawThickCircleArc(MICROUI_GraphicsContext* gc, jint x, jint y, jint diameter, jfloat startAngle, jfloat arcAngle, jint thickness);
171 
172 /*
173  * @brief Stubbed implementation of drawFlippedImage. See ui_drawing.h
174  */
175 DRAWING_Status UI_DRAWING_STUB_drawFlippedImage(MICROUI_GraphicsContext* gc, MICROUI_Image* img, jint regionX, jint regionY, jint width, jint height, jint x, jint y, DRAWING_Flip transformation, jint alpha);
176 
177 /*
178  * @brief Stubbed implementation of drawRotatedImageNearestNeighbor. See ui_drawing.h
179  */
180 DRAWING_Status UI_DRAWING_STUB_drawRotatedImageNearestNeighbor(MICROUI_GraphicsContext* gc, MICROUI_Image* img, jint x, jint y, jint rotationX, jint rotationY, jfloat angle, jint alpha);
181 
182 /*
183  * @brief Stubbed implementation of drawRotatedImageBilinear. See ui_drawing.h
184  */
185 DRAWING_Status UI_DRAWING_STUB_drawRotatedImageBilinear(MICROUI_GraphicsContext* gc, MICROUI_Image* img, jint x, jint y, jint rotationX, jint rotationY, jfloat angle, jint alpha);
186 
187 /*
188  * @brief Stubbed implementation of drawScaledImageNearestNeighbor. See ui_drawing.h
189  */
190 DRAWING_Status UI_DRAWING_STUB_drawScaledImageNearestNeighbor(MICROUI_GraphicsContext* gc, MICROUI_Image* img, jint x, jint y, jfloat factorX, jfloat factorY, jint alpha);
191 
192 /*
193  * @brief Stubbed implementation of drawScaledImageBilinear. See ui_drawing.h
194  */
195 DRAWING_Status UI_DRAWING_STUB_drawScaledImageBilinear(MICROUI_GraphicsContext* gc, MICROUI_Image* img, jint x, jint y, jfloat factorX, jfloat factorY, jint alpha);
196 
197 // --------------------------------------------------------------------------------
198 // EOF
199 // --------------------------------------------------------------------------------
200 
201 #ifdef __cplusplus
202 }
203 #endif
204 #endif // UI_DRAWING_STUB_H