Debian Codegraph @

lvgl/src/draw/sw/blend/helium/lv_blend_helium.h

raw symbols SCIP
1 /**
2 * @file lv_blend_helium.h
3 *
4 */
5
6 #ifndef LV_BLEND_HELIUM_H
7 #define LV_BLEND_HELIUM_H
8
9 #ifdef __cplusplus
10 extern "C" {
11 #endif
12
13 /*********************
14 * INCLUDES
15 *********************/
16
17 #if defined(_RTE_)
18 #include "Pre_Include_Global.h"
19 #include "lv_conf_cmsis.h"
20 #endif
21
22 #include "../../../../lv_conf_internal.h"
23
24 /* detect whether helium is available based on arm compilers' standard */
25 #if defined(__ARM_FEATURE_MVE) && __ARM_FEATURE_MVE
26
27 #ifdef LV_DRAW_SW_HELIUM_CUSTOM_INCLUDE
28 #include LV_DRAW_SW_HELIUM_CUSTOM_INCLUDE
29 #endif
30
31 #if !defined(__ASSEMBLY__)
32
33 #if __GNUC__ >= 4
34 #define LVGL_HIDDEN __attribute__((visibility("hidden")))
35 #else
36 #define LVGL_HIDDEN
37 #endif
38
39 /* Use arm2d functions if present */
40 #include "../arm2d/lv_blend_arm2d.h"
41
42 /*********************
43 * DEFINES
44 *********************/
45
46 #if LV_USE_NATIVE_HELIUM_ASM
47
48 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_RGB565
49 #define LV_DRAW_SW_COLOR_BLEND_TO_RGB565(dsc) \
50 lv_color_blend_to_rgb565_helium(dsc)
51 #endif
52
53 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_RGB565_WITH_OPA
54 #define LV_DRAW_SW_COLOR_BLEND_TO_RGB565_WITH_OPA(dsc) \
55 lv_color_blend_to_rgb565_with_opa_helium(dsc)
56 #endif
57
58 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_RGB565_WITH_MASK
59 #define LV_DRAW_SW_COLOR_BLEND_TO_RGB565_WITH_MASK(dsc) \
60 lv_color_blend_to_rgb565_with_mask_helium(dsc)
61 #endif
62
63 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_RGB565_MIX_MASK_OPA
64 #define LV_DRAW_SW_COLOR_BLEND_TO_RGB565_MIX_MASK_OPA(dsc) \
65 lv_color_blend_to_rgb565_mix_mask_opa_helium(dsc)
66 #endif
67
68 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB565
69 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB565(dsc) \
70 lv_rgb565_blend_normal_to_rgb565_helium(dsc)
71 #endif
72
73 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB565_WITH_OPA
74 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB565_WITH_OPA(dsc) \
75 lv_rgb565_blend_normal_to_rgb565_with_opa_helium(dsc)
76 #endif
77
78 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB565_WITH_MASK
79 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB565_WITH_MASK(dsc) \
80 lv_rgb565_blend_normal_to_rgb565_with_mask_helium(dsc)
81 #endif
82
83 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB565_MIX_MASK_OPA
84 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB565_MIX_MASK_OPA(dsc) \
85 lv_rgb565_blend_normal_to_rgb565_mix_mask_opa_helium(dsc)
86 #endif
87
88 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB565
89 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB565(dsc, src_px_size) \
90 lv_rgb888_blend_normal_to_rgb565_helium(dsc, src_px_size)
91 #endif
92
93 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB565_WITH_OPA
94 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB565_WITH_OPA(dsc, src_px_size) \
95 lv_rgb888_blend_normal_to_rgb565_with_opa_helium(dsc, src_px_size)
96 #endif
97
98 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB565_WITH_MASK
99 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB565_WITH_MASK(dsc, src_px_size) \
100 lv_rgb888_blend_normal_to_rgb565_with_mask_helium(dsc, src_px_size)
101 #endif
102
103 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB565_MIX_MASK_OPA
104 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB565_MIX_MASK_OPA(dsc, src_px_size) \
105 lv_rgb888_blend_normal_to_rgb565_mix_mask_opa_helium(dsc, src_px_size)
106 #endif
107
108 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB565
109 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB565(dsc) \
110 lv_argb8888_blend_normal_to_rgb565_helium(dsc)
111 #endif
112
113 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB565_WITH_OPA
114 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB565_WITH_OPA(dsc) \
115 lv_argb8888_blend_normal_to_rgb565_with_opa_helium(dsc)
116 #endif
117
118 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB565_WITH_MASK
119 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB565_WITH_MASK(dsc) \
120 lv_argb8888_blend_normal_to_rgb565_with_mask_helium(dsc)
121 #endif
122
123 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB565_MIX_MASK_OPA
124 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB565_MIX_MASK_OPA(dsc) \
125 lv_argb8888_blend_normal_to_rgb565_mix_mask_opa_helium(dsc)
126 #endif
127
128 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_RGB888
129 #define LV_DRAW_SW_COLOR_BLEND_TO_RGB888(dsc, dst_px_size) \
130 lv_color_blend_to_rgb888_helium(dsc, dst_px_size)
131 #endif
132
133 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_RGB888_WITH_OPA
134 #define LV_DRAW_SW_COLOR_BLEND_TO_RGB888_WITH_OPA(dsc, dst_px_size) \
135 lv_color_blend_to_rgb888_with_opa_helium(dsc, dst_px_size)
136 #endif
137
138 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_RGB888_WITH_MASK
139 #define LV_DRAW_SW_COLOR_BLEND_TO_RGB888_WITH_MASK(dsc, dst_px_size) \
140 lv_color_blend_to_rgb888_with_mask_helium(dsc, dst_px_size)
141 #endif
142
143 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_RGB888_MIX_MASK_OPA
144 #define LV_DRAW_SW_COLOR_BLEND_TO_RGB888_MIX_MASK_OPA(dsc, dst_px_size) \
145 lv_color_blend_to_rgb888_mix_mask_opa_helium(dsc, dst_px_size)
146 #endif
147
148 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB888
149 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB888(dsc, dst_px_size) \
150 lv_rgb565_blend_normal_to_rgb888_helium(dsc, dst_px_size)
151 #endif
152
153 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB888_WITH_OPA
154 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB888_WITH_OPA(dsc, dst_px_size) \
155 lv_rgb565_blend_normal_to_rgb888_with_opa_helium(dsc, dst_px_size)
156 #endif
157
158 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB888_WITH_MASK
159 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB888_WITH_MASK(dsc, dst_px_size) \
160 lv_rgb565_blend_normal_to_rgb888_with_mask_helium(dsc, dst_px_size)
161 #endif
162
163 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB888_MIX_MASK_OPA
164 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_RGB888_MIX_MASK_OPA(dsc, dst_px_size) \
165 lv_rgb565_blend_normal_to_rgb888_mix_mask_opa_helium(dsc, dst_px_size)
166 #endif
167
168 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB888
169 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB888(dsc, dst_px_size, src_px_size) \
170 lv_rgb888_blend_normal_to_rgb888_helium(dsc, dst_px_size, src_px_size)
171 #endif
172
173 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB888_WITH_OPA
174 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB888_WITH_OPA(dsc, dst_px_size, src_px_size) \
175 lv_rgb888_blend_normal_to_rgb888_with_opa_helium(dsc, dst_px_size, src_px_size)
176 #endif
177
178 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB888_WITH_MASK
179 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB888_WITH_MASK(dsc, dst_px_size, src_px_size) \
180 lv_rgb888_blend_normal_to_rgb888_with_mask_helium(dsc, dst_px_size, src_px_size)
181 #endif
182
183 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB888_MIX_MASK_OPA
184 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_RGB888_MIX_MASK_OPA(dsc, dst_px_size, src_px_size) \
185 lv_rgb888_blend_normal_to_rgb888_mix_mask_opa_helium(dsc, dst_px_size, src_px_size)
186 #endif
187
188 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB888
189 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB888(dsc, dst_px_size) \
190 lv_argb8888_blend_normal_to_rgb888_helium(dsc, dst_px_size)
191 #endif
192
193 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB888_WITH_OPA
194 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB888_WITH_OPA(dsc, dst_px_size) \
195 lv_argb8888_blend_normal_to_rgb888_with_opa_helium(dsc, dst_px_size)
196 #endif
197
198 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB888_WITH_MASK
199 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB888_WITH_MASK(dsc, dst_px_size) \
200 lv_argb8888_blend_normal_to_rgb888_with_mask_helium(dsc, dst_px_size)
201 #endif
202
203 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB888_MIX_MASK_OPA
204 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_RGB888_MIX_MASK_OPA(dsc, dst_px_size) \
205 lv_argb8888_blend_normal_to_rgb888_mix_mask_opa_helium(dsc, dst_px_size)
206 #endif
207
208 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_ARGB8888
209 #define LV_DRAW_SW_COLOR_BLEND_TO_ARGB8888(dsc) \
210 lv_color_blend_to_argb8888_helium(dsc)
211 #endif
212
213 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_ARGB8888_WITH_OPA
214 #define LV_DRAW_SW_COLOR_BLEND_TO_ARGB8888_WITH_OPA(dsc) \
215 lv_color_blend_to_argb8888_with_opa_helium(dsc)
216 #endif
217
218 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_ARGB8888_WITH_MASK
219 #define LV_DRAW_SW_COLOR_BLEND_TO_ARGB8888_WITH_MASK(dsc) \
220 lv_color_blend_to_argb8888_with_mask_helium(dsc)
221 #endif
222
223 #ifndef LV_DRAW_SW_COLOR_BLEND_TO_ARGB8888_MIX_MASK_OPA
224 #define LV_DRAW_SW_COLOR_BLEND_TO_ARGB8888_MIX_MASK_OPA(dsc) \
225 lv_color_blend_to_argb8888_mix_mask_opa_helium(dsc)
226 #endif
227
228 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_ARGB8888
229 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_ARGB8888(dsc) \
230 lv_rgb565_blend_normal_to_argb8888_helium(dsc)
231 #endif
232
233 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_ARGB8888_WITH_OPA
234 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_ARGB8888_WITH_OPA(dsc) \
235 lv_rgb565_blend_normal_to_argb8888_with_opa_helium(dsc)
236 #endif
237
238 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_ARGB8888_WITH_MASK
239 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_ARGB8888_WITH_MASK(dsc) \
240 lv_rgb565_blend_normal_to_argb8888_with_mask_helium(dsc)
241 #endif
242
243 #ifndef LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_ARGB8888_MIX_MASK_OPA
244 #define LV_DRAW_SW_RGB565_BLEND_NORMAL_TO_ARGB8888_MIX_MASK_OPA(dsc) \
245 lv_rgb565_blend_normal_to_argb8888_mix_mask_opa_helium(dsc)
246 #endif
247
248 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_ARGB8888
249 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_ARGB8888(dsc, src_px_size) \
250 lv_rgb888_blend_normal_to_argb8888_helium(dsc, src_px_size)
251 #endif
252
253 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_ARGB8888_WITH_OPA
254 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_ARGB8888_WITH_OPA(dsc, src_px_size) \
255 lv_rgb888_blend_normal_to_argb8888_with_opa_helium(dsc, src_px_size)
256 #endif
257
258 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_ARGB8888_WITH_MASK
259 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_ARGB8888_WITH_MASK(dsc, src_px_size) \
260 lv_rgb888_blend_normal_to_argb8888_with_mask_helium(dsc, src_px_size)
261 #endif
262
263 #ifndef LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_ARGB8888_MIX_MASK_OPA
264 #define LV_DRAW_SW_RGB888_BLEND_NORMAL_TO_ARGB8888_MIX_MASK_OPA(dsc, src_px_size) \
265 lv_rgb888_blend_normal_to_argb8888_mix_mask_opa_helium(dsc, src_px_size)
266 #endif
267
268 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_ARGB8888
269 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_ARGB8888(dsc) \
270 lv_argb8888_blend_normal_to_argb8888_helium(dsc)
271 #endif
272
273 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_ARGB8888_WITH_OPA
274 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_ARGB8888_WITH_OPA(dsc) \
275 lv_argb8888_blend_normal_to_argb8888_with_opa_helium(dsc)
276 #endif
277
278 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_ARGB8888_WITH_MASK
279 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_ARGB8888_WITH_MASK(dsc) \
280 lv_argb8888_blend_normal_to_argb8888_with_mask_helium(dsc)
281 #endif
282
283 #ifndef LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_ARGB8888_MIX_MASK_OPA
284 #define LV_DRAW_SW_ARGB8888_BLEND_NORMAL_TO_ARGB8888_MIX_MASK_OPA(dsc) \
285 lv_argb8888_blend_normal_to_argb8888_mix_mask_opa_helium(dsc)
286 #endif
287
288 /**********************
289 * TYPEDEFS
290 **********************/
291
292 typedef struct {
293 uint32_t opa;
294 void * dst_buf;
295 uint32_t dst_w;
296 uint32_t dst_h;
297 uint32_t dst_stride;
298 const void * src_buf;
299 uint32_t src_stride;
300 const lv_opa_t * mask_buf;
301 uint32_t mask_stride;
302 } asm_dsc_t;
303 /**********************
304 * GLOBAL PROTOTYPES
305 **********************/
306
307 extern LVGL_HIDDEN void _lv_color_blend_to_rgb565_helium(asm_dsc_t * dsc);
308 static inline lv_result_t lv_color_blend_to_rgb565_helium(lv_draw_sw_blend_fill_dsc_t * dsc)
309 {
310 asm_dsc_t asm_dsc = {
311 .dst_buf = dsc->dest_buf,
312 .dst_w = dsc->dest_w,
313 .dst_h = dsc->dest_h,
314 .dst_stride = dsc->dest_stride,
315 .src_buf = &dsc->color
316 };
317
318 _lv_color_blend_to_rgb565_helium(&asm_dsc);
319 return LV_RESULT_OK;
320 }
321
322 extern LVGL_HIDDEN void _lv_color_blend_to_rgb565_with_opa_helium(asm_dsc_t * dsc);
323 static inline lv_result_t lv_color_blend_to_rgb565_with_opa_helium(lv_draw_sw_blend_fill_dsc_t * dsc)
324 {
325 asm_dsc_t asm_dsc = {
326 .opa = dsc->opa,
327 .dst_buf = dsc->dest_buf,
328 .dst_w = dsc->dest_w,
329 .dst_h = dsc->dest_h,
330 .dst_stride = dsc->dest_stride,
331 .src_buf = &dsc->color
332 };
333 _lv_color_blend_to_rgb565_with_opa_helium(&asm_dsc);
334 return LV_RESULT_OK;
335 }
336
337 extern LVGL_HIDDEN void _lv_color_blend_to_rgb565_with_mask_helium(asm_dsc_t * dsc);
338 static inline lv_result_t lv_color_blend_to_rgb565_with_mask_helium(lv_draw_sw_blend_fill_dsc_t * dsc)
339 {
340 asm_dsc_t asm_dsc = {
341 .dst_buf = dsc->dest_buf,
342 .dst_w = dsc->dest_w,
343 .dst_h = dsc->dest_h,
344 .dst_stride = dsc->dest_stride,
345 .src_buf = &dsc->color,
346 .mask_buf = dsc->mask_buf,
347 .mask_stride = dsc->mask_stride
348 };
349 _lv_color_blend_to_rgb565_with_mask_helium(&asm_dsc);
350 return LV_RESULT_OK;
351 }
352
353 extern LVGL_HIDDEN void _lv_color_blend_to_rgb565_mix_mask_opa_helium(asm_dsc_t * dsc);
354 static inline lv_result_t lv_color_blend_to_rgb565_mix_mask_opa_helium(lv_draw_sw_blend_fill_dsc_t * dsc)
355 {
356 asm_dsc_t asm_dsc = {
357 .opa = dsc->opa,
358 .dst_buf = dsc->dest_buf,
359 .dst_w = dsc->dest_w,
360 .dst_h = dsc->dest_h,
361 .dst_stride = dsc->dest_stride,
362 .src_buf = &dsc->color,
363 .mask_buf = dsc->mask_buf,
364 .mask_stride = dsc->mask_stride
365 };
366 _lv_color_blend_to_rgb565_mix_mask_opa_helium(&asm_dsc);
367 return LV_RESULT_OK;
368 }
369
370 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_rgb565_helium(asm_dsc_t * dsc);
371 static inline lv_result_t lv_rgb565_blend_normal_to_rgb565_helium(lv_draw_sw_blend_image_dsc_t * dsc)
372 {
373 asm_dsc_t asm_dsc = {
374 .dst_buf = dsc->dest_buf,
375 .dst_w = dsc->dest_w,
376 .dst_h = dsc->dest_h,
377 .dst_stride = dsc->dest_stride,
378 .src_buf = dsc->src_buf,
379 .src_stride = dsc->src_stride
380 };
381 _lv_rgb565_blend_normal_to_rgb565_helium(&asm_dsc);
382 return LV_RESULT_OK;
383 }
384
385 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_rgb565_with_opa_helium(asm_dsc_t * dsc);
386 static inline lv_result_t lv_rgb565_blend_normal_to_rgb565_with_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc)
387 {
388 asm_dsc_t asm_dsc = {
389 .opa = dsc->opa,
390 .dst_buf = dsc->dest_buf,
391 .dst_w = dsc->dest_w,
392 .dst_h = dsc->dest_h,
393 .dst_stride = dsc->dest_stride,
394 .src_buf = dsc->src_buf,
395 .src_stride = dsc->src_stride
396 };
397 _lv_rgb565_blend_normal_to_rgb565_with_opa_helium(&asm_dsc);
398 return LV_RESULT_OK;
399 }
400
401 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_rgb565_with_mask_helium(asm_dsc_t * dsc);
402 static inline lv_result_t lv_rgb565_blend_normal_to_rgb565_with_mask_helium(lv_draw_sw_blend_image_dsc_t * dsc)
403 {
404 asm_dsc_t asm_dsc = {
405 .dst_buf = dsc->dest_buf,
406 .dst_w = dsc->dest_w,
407 .dst_h = dsc->dest_h,
408 .dst_stride = dsc->dest_stride,
409 .src_buf = dsc->src_buf,
410 .src_stride = dsc->src_stride,
411 .mask_buf = dsc->mask_buf,
412 .mask_stride = dsc->mask_stride
413 };
414 _lv_rgb565_blend_normal_to_rgb565_with_mask_helium(&asm_dsc);
415 return LV_RESULT_OK;
416 }
417
418 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_rgb565_mix_mask_opa_helium(asm_dsc_t * dsc);
419 static inline lv_result_t lv_rgb565_blend_normal_to_rgb565_mix_mask_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc)
420 {
421 asm_dsc_t asm_dsc = {
422 .opa = dsc->opa,
423 .dst_buf = dsc->dest_buf,
424 .dst_w = dsc->dest_w,
425 .dst_h = dsc->dest_h,
426 .dst_stride = dsc->dest_stride,
427 .src_buf = dsc->src_buf,
428 .src_stride = dsc->src_stride,
429 .mask_buf = dsc->mask_buf,
430 .mask_stride = dsc->mask_stride
431 };
432 _lv_rgb565_blend_normal_to_rgb565_mix_mask_opa_helium(&asm_dsc);
433 return LV_RESULT_OK;
434 }
435
436 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_rgb565_helium(asm_dsc_t * dsc);
437 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_rgb565_helium(asm_dsc_t * dsc);
438 static inline lv_result_t lv_rgb888_blend_normal_to_rgb565_helium(lv_draw_sw_blend_image_dsc_t * dsc,
439 uint32_t src_px_size)
440 {
441 asm_dsc_t asm_dsc = {
442 .dst_buf = dsc->dest_buf,
443 .dst_w = dsc->dest_w,
444 .dst_h = dsc->dest_h,
445 .dst_stride = dsc->dest_stride,
446 .src_buf = dsc->src_buf,
447 .src_stride = dsc->src_stride
448 };
449 if(src_px_size == 3) {
450 _lv_rgb888_blend_normal_to_rgb565_helium(&asm_dsc);
451 }
452 else {
453 _lv_xrgb8888_blend_normal_to_rgb565_helium(&asm_dsc);
454 }
455 return LV_RESULT_OK;
456 }
457
458 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_rgb565_with_opa_helium(asm_dsc_t * dsc);
459 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_rgb565_with_opa_helium(asm_dsc_t * dsc);
460 static inline lv_result_t lv_rgb888_blend_normal_to_rgb565_with_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc,
461 uint32_t src_px_size)
462 {
463 asm_dsc_t asm_dsc = {
464 .opa = dsc->opa,
465 .dst_buf = dsc->dest_buf,
466 .dst_w = dsc->dest_w,
467 .dst_h = dsc->dest_h,
468 .dst_stride = dsc->dest_stride,
469 .src_buf = dsc->src_buf,
470 .src_stride = dsc->src_stride
471 };
472 if(src_px_size == 3) {
473 _lv_rgb888_blend_normal_to_rgb565_with_opa_helium(&asm_dsc);
474 }
475 else {
476 _lv_xrgb8888_blend_normal_to_rgb565_with_opa_helium(&asm_dsc);
477 }
478 return LV_RESULT_OK;
479 }
480
481 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_rgb565_with_mask_helium(asm_dsc_t * dsc);
482 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_rgb565_with_mask_helium(asm_dsc_t * dsc);
483 static inline lv_result_t lv_rgb888_blend_normal_to_rgb565_with_mask_helium(lv_draw_sw_blend_image_dsc_t * dsc,
484 uint32_t src_px_size)
485 {
486 asm_dsc_t asm_dsc = {
487 .dst_buf = dsc->dest_buf,
488 .dst_w = dsc->dest_w,
489 .dst_h = dsc->dest_h,
490 .dst_stride = dsc->dest_stride,
491 .src_buf = dsc->src_buf,
492 .src_stride = dsc->src_stride,
493 .mask_buf = dsc->mask_buf,
494 .mask_stride = dsc->mask_stride
495 };
496 if(src_px_size == 3) {
497 _lv_rgb888_blend_normal_to_rgb565_with_mask_helium(&asm_dsc);
498 }
499 else {
500 _lv_xrgb8888_blend_normal_to_rgb565_with_mask_helium(&asm_dsc);
501 }
502 return LV_RESULT_OK;
503 }
504
505 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_rgb565_mix_mask_opa_helium(asm_dsc_t * dsc);
506 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_rgb565_mix_mask_opa_helium(asm_dsc_t * dsc);
507 static inline lv_result_t lv_rgb888_blend_normal_to_rgb565_mix_mask_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc,
508 uint32_t src_px_size)
509 {
510 asm_dsc_t asm_dsc = {
511 .opa = dsc->opa,
512 .dst_buf = dsc->dest_buf,
513 .dst_w = dsc->dest_w,
514 .dst_h = dsc->dest_h,
515 .dst_stride = dsc->dest_stride,
516 .src_buf = dsc->src_buf,
517 .src_stride = dsc->src_stride,
518 .mask_buf = dsc->mask_buf,
519 .mask_stride = dsc->mask_stride
520 };
521 if(src_px_size == 3) {
522 _lv_rgb888_blend_normal_to_rgb565_mix_mask_opa_helium(&asm_dsc);
523 }
524 else {
525 _lv_xrgb8888_blend_normal_to_rgb565_mix_mask_opa_helium(&asm_dsc);
526 }
527 return LV_RESULT_OK;
528 }
529
530 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_rgb565_helium(asm_dsc_t * dsc);
531 static inline lv_result_t lv_argb8888_blend_normal_to_rgb565_helium(lv_draw_sw_blend_image_dsc_t * dsc)
532 {
533 asm_dsc_t asm_dsc = {
534 .dst_buf = dsc->dest_buf,
535 .dst_w = dsc->dest_w,
536 .dst_h = dsc->dest_h,
537 .dst_stride = dsc->dest_stride,
538 .src_buf = dsc->src_buf,
539 .src_stride = dsc->src_stride
540 };
541 _lv_argb8888_blend_normal_to_rgb565_helium(&asm_dsc);
542 return LV_RESULT_OK;
543 }
544
545 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_rgb565_with_opa_helium(asm_dsc_t * dsc);
546 static inline lv_result_t lv_argb8888_blend_normal_to_rgb565_with_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc)
547 {
548 asm_dsc_t asm_dsc = {
549 .opa = dsc->opa,
550 .dst_buf = dsc->dest_buf,
551 .dst_w = dsc->dest_w,
552 .dst_h = dsc->dest_h,
553 .dst_stride = dsc->dest_stride,
554 .src_buf = dsc->src_buf,
555 .src_stride = dsc->src_stride
556 };
557 _lv_argb8888_blend_normal_to_rgb565_with_opa_helium(&asm_dsc);
558 return LV_RESULT_OK;
559 }
560
561 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_rgb565_with_mask_helium(asm_dsc_t * dsc);
562 static inline lv_result_t lv_argb8888_blend_normal_to_rgb565_with_mask_helium(lv_draw_sw_blend_image_dsc_t * dsc)
563 {
564 asm_dsc_t asm_dsc = {
565 .dst_buf = dsc->dest_buf,
566 .dst_w = dsc->dest_w,
567 .dst_h = dsc->dest_h,
568 .dst_stride = dsc->dest_stride,
569 .src_buf = dsc->src_buf,
570 .src_stride = dsc->src_stride,
571 .mask_buf = dsc->mask_buf,
572 .mask_stride = dsc->mask_stride
573 };
574 _lv_argb8888_blend_normal_to_rgb565_with_mask_helium(&asm_dsc);
575 return LV_RESULT_OK;
576 }
577
578 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_rgb565_mix_mask_opa_helium(asm_dsc_t * dsc);
579 static inline lv_result_t lv_argb8888_blend_normal_to_rgb565_mix_mask_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc)
580 {
581 asm_dsc_t asm_dsc = {
582 .opa = dsc->opa,
583 .dst_buf = dsc->dest_buf,
584 .dst_w = dsc->dest_w,
585 .dst_h = dsc->dest_h,
586 .dst_stride = dsc->dest_stride,
587 .src_buf = dsc->src_buf,
588 .src_stride = dsc->src_stride,
589 .mask_buf = dsc->mask_buf,
590 .mask_stride = dsc->mask_stride
591 };
592 _lv_argb8888_blend_normal_to_rgb565_mix_mask_opa_helium(&asm_dsc);
593 return LV_RESULT_OK;
594 }
595
596 extern LVGL_HIDDEN void _lv_color_blend_to_rgb888_helium(asm_dsc_t * dsc);
597 extern LVGL_HIDDEN void _lv_color_blend_to_xrgb8888_helium(asm_dsc_t * dsc);
598 static inline lv_result_t lv_color_blend_to_rgb888_helium(lv_draw_sw_blend_fill_dsc_t * dsc, uint32_t dst_px_size)
599 {
600 asm_dsc_t asm_dsc = {
601 .dst_buf = dsc->dest_buf,
602 .dst_w = dsc->dest_w,
603 .dst_h = dsc->dest_h,
604 .dst_stride = dsc->dest_stride,
605 .src_buf = &dsc->color
606 };
607 if(dst_px_size == 3) {
608 _lv_color_blend_to_rgb888_helium(&asm_dsc);
609 }
610 else {
611 _lv_color_blend_to_xrgb8888_helium(&asm_dsc);
612 }
613 return LV_RESULT_OK;
614 }
615
616 extern LVGL_HIDDEN void _lv_color_blend_to_rgb888_with_opa_helium(asm_dsc_t * dsc);
617 extern LVGL_HIDDEN void _lv_color_blend_to_xrgb8888_with_opa_helium(asm_dsc_t * dsc);
618 static inline lv_result_t lv_color_blend_to_rgb888_with_opa_helium(lv_draw_sw_blend_fill_dsc_t * dsc,
619 uint32_t dst_px_size)
620 {
621 asm_dsc_t asm_dsc = {
622 .opa = dsc->opa,
623 .dst_buf = dsc->dest_buf,
624 .dst_w = dsc->dest_w,
625 .dst_h = dsc->dest_h,
626 .dst_stride = dsc->dest_stride,
627 .src_buf = &dsc->color
628 };
629 if(dst_px_size == 3) {
630 _lv_color_blend_to_rgb888_with_opa_helium(&asm_dsc);
631 }
632 else {
633 _lv_color_blend_to_xrgb8888_with_opa_helium(&asm_dsc);
634 }
635 return LV_RESULT_OK;
636 }
637
638 extern LVGL_HIDDEN void _lv_color_blend_to_rgb888_with_mask_helium(asm_dsc_t * dsc);
639 extern LVGL_HIDDEN void _lv_color_blend_to_xrgb8888_with_mask_helium(asm_dsc_t * dsc);
640 static inline lv_result_t lv_color_blend_to_rgb888_with_mask_helium(lv_draw_sw_blend_fill_dsc_t * dsc,
641 uint32_t dst_px_size)
642 {
643 asm_dsc_t asm_dsc = {
644 .dst_buf = dsc->dest_buf,
645 .dst_w = dsc->dest_w,
646 .dst_h = dsc->dest_h,
647 .dst_stride = dsc->dest_stride,
648 .src_buf = &dsc->color,
649 .mask_buf = dsc->mask_buf,
650 .mask_stride = dsc->mask_stride
651 };
652 if(dst_px_size == 3) {
653 _lv_color_blend_to_rgb888_with_mask_helium(&asm_dsc);
654 }
655 else {
656 _lv_color_blend_to_xrgb8888_with_mask_helium(&asm_dsc);
657 }
658 return LV_RESULT_OK;
659 }
660
661 extern LVGL_HIDDEN void _lv_color_blend_to_rgb888_mix_mask_opa_helium(asm_dsc_t * dsc);
662 extern LVGL_HIDDEN void _lv_color_blend_to_xrgb8888_mix_mask_opa_helium(asm_dsc_t * dsc);
663 static inline lv_result_t lv_color_blend_to_rgb888_mix_mask_opa_helium(lv_draw_sw_blend_fill_dsc_t * dsc,
664 uint32_t dst_px_size)
665 {
666 asm_dsc_t asm_dsc = {
667 .opa = dsc->opa,
668 .dst_buf = dsc->dest_buf,
669 .dst_w = dsc->dest_w,
670 .dst_h = dsc->dest_h,
671 .dst_stride = dsc->dest_stride,
672 .src_buf = &dsc->color,
673 .mask_buf = dsc->mask_buf,
674 .mask_stride = dsc->mask_stride
675 };
676 if(dst_px_size == 3) {
677 _lv_color_blend_to_rgb888_mix_mask_opa_helium(&asm_dsc);
678 }
679 else {
680 _lv_color_blend_to_xrgb8888_mix_mask_opa_helium(&asm_dsc);
681 }
682 return LV_RESULT_OK;
683 }
684
685 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_rgb888_helium(asm_dsc_t * dsc);
686 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_xrgb8888_helium(asm_dsc_t * dsc);
687 static inline lv_result_t lv_rgb565_blend_normal_to_rgb888_helium(lv_draw_sw_blend_image_dsc_t * dsc,
688 uint32_t dst_px_size)
689 {
690 asm_dsc_t asm_dsc = {
691 .dst_buf = dsc->dest_buf,
692 .dst_w = dsc->dest_w,
693 .dst_h = dsc->dest_h,
694 .dst_stride = dsc->dest_stride,
695 .src_buf = dsc->src_buf,
696 .src_stride = dsc->src_stride
697 };
698 if(dst_px_size == 3) {
699 _lv_rgb565_blend_normal_to_rgb888_helium(&asm_dsc);
700 }
701 else {
702 _lv_rgb565_blend_normal_to_xrgb8888_helium(&asm_dsc);
703 }
704 return LV_RESULT_OK;
705 }
706
707 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_rgb888_with_opa_helium(asm_dsc_t * dsc);
708 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_xrgb8888_with_opa_helium(asm_dsc_t * dsc);
709 static inline lv_result_t lv_rgb565_blend_normal_to_rgb888_with_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc,
710 uint32_t dst_px_size)
711 {
712 asm_dsc_t asm_dsc = {
713 .opa = dsc->opa,
714 .dst_buf = dsc->dest_buf,
715 .dst_w = dsc->dest_w,
716 .dst_h = dsc->dest_h,
717 .dst_stride = dsc->dest_stride,
718 .src_buf = dsc->src_buf,
719 .src_stride = dsc->src_stride
720 };
721 if(dst_px_size == 3) {
722 _lv_rgb565_blend_normal_to_rgb888_with_opa_helium(&asm_dsc);
723 }
724 else {
725 _lv_rgb565_blend_normal_to_xrgb8888_with_opa_helium(&asm_dsc);
726 }
727 return LV_RESULT_OK;
728 }
729
730 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_rgb888_with_mask_helium(asm_dsc_t * dsc);
731 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_xrgb8888_with_mask_helium(asm_dsc_t * dsc);
732 static inline lv_result_t lv_rgb565_blend_normal_to_rgb888_with_mask_helium(lv_draw_sw_blend_image_dsc_t * dsc,
733 uint32_t dst_px_size)
734 {
735 asm_dsc_t asm_dsc = {
736 .dst_buf = dsc->dest_buf,
737 .dst_w = dsc->dest_w,
738 .dst_h = dsc->dest_h,
739 .dst_stride = dsc->dest_stride,
740 .src_buf = dsc->src_buf,
741 .src_stride = dsc->src_stride,
742 .mask_buf = dsc->mask_buf,
743 .mask_stride = dsc->mask_stride
744 };
745 if(dst_px_size == 3) {
746 _lv_rgb565_blend_normal_to_rgb888_with_mask_helium(&asm_dsc);
747 }
748 else {
749 _lv_rgb565_blend_normal_to_xrgb8888_with_mask_helium(&asm_dsc);
750 }
751 return LV_RESULT_OK;
752 }
753
754 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_rgb888_mix_mask_opa_helium(asm_dsc_t * dsc);
755 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_xrgb8888_mix_mask_opa_helium(asm_dsc_t * dsc);
756 static inline lv_result_t lv_rgb565_blend_normal_to_rgb888_mix_mask_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc,
757 uint32_t dst_px_size)
758 {
759 asm_dsc_t asm_dsc = {
760 .opa = dsc->opa,
761 .dst_buf = dsc->dest_buf,
762 .dst_w = dsc->dest_w,
763 .dst_h = dsc->dest_h,
764 .dst_stride = dsc->dest_stride,
765 .src_buf = dsc->src_buf,
766 .src_stride = dsc->src_stride,
767 .mask_buf = dsc->mask_buf,
768 .mask_stride = dsc->mask_stride
769 };
770 if(dst_px_size == 3) {
771 _lv_rgb565_blend_normal_to_rgb888_mix_mask_opa_helium(&asm_dsc);
772 }
773 else {
774 _lv_rgb565_blend_normal_to_xrgb8888_mix_mask_opa_helium(&asm_dsc);
775 }
776 return LV_RESULT_OK;
777 }
778
779 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_rgb888_helium(asm_dsc_t * dsc);
780 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_xrgb8888_helium(asm_dsc_t * dsc);
781 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_rgb888_helium(asm_dsc_t * dsc);
782 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_xrgb8888_helium(asm_dsc_t * dsc);
783 static inline lv_result_t lv_rgb888_blend_normal_to_rgb888_helium(lv_draw_sw_blend_image_dsc_t * dsc,
784 uint32_t dst_px_size,
785 uint32_t src_px_size)
786 {
787 asm_dsc_t asm_dsc = {
788 .dst_buf = dsc->dest_buf,
789 .dst_w = dsc->dest_w,
790 .dst_h = dsc->dest_h,
791 .dst_stride = dsc->dest_stride,
792 .src_buf = dsc->src_buf,
793 .src_stride = dsc->src_stride
794 };
795 if(dst_px_size == 3) {
796 if(src_px_size == 3) {
797 _lv_rgb888_blend_normal_to_rgb888_helium(&asm_dsc);
798 }
799 else {
800 _lv_xrgb8888_blend_normal_to_rgb888_helium(&asm_dsc);
801 }
802 }
803 else {
804 if(src_px_size == 3) {
805 _lv_rgb888_blend_normal_to_xrgb8888_helium(&asm_dsc);
806 }
807 else {
808 _lv_xrgb8888_blend_normal_to_xrgb8888_helium(&asm_dsc);
809 }
810 }
811 return LV_RESULT_OK;
812 }
813
814 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_rgb888_with_opa_helium(asm_dsc_t * dsc);
815 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_xrgb8888_with_opa_helium(asm_dsc_t * dsc);
816 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_rgb888_with_opa_helium(asm_dsc_t * dsc);
817 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_xrgb8888_with_opa_helium(asm_dsc_t * dsc);
818 static inline lv_result_t lv_rgb888_blend_normal_to_rgb888_with_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc,
819 uint32_t dst_px_size, uint32_t src_px_size)
820 {
821 asm_dsc_t asm_dsc = {
822 .opa = dsc->opa,
823 .dst_buf = dsc->dest_buf,
824 .dst_w = dsc->dest_w,
825 .dst_h = dsc->dest_h,
826 .dst_stride = dsc->dest_stride,
827 .src_buf = dsc->src_buf,
828 .src_stride = dsc->src_stride
829 };
830 if(dst_px_size == 3) {
831 if(src_px_size == 3) {
832 _lv_rgb888_blend_normal_to_rgb888_with_opa_helium(&asm_dsc);
833 }
834 else {
835 _lv_xrgb8888_blend_normal_to_rgb888_with_opa_helium(&asm_dsc);
836 }
837 }
838 else {
839 if(src_px_size == 3) {
840 _lv_rgb888_blend_normal_to_xrgb8888_with_opa_helium(&asm_dsc);
841 }
842 else {
843 _lv_xrgb8888_blend_normal_to_xrgb8888_with_opa_helium(&asm_dsc);
844 }
845 }
846 return LV_RESULT_OK;
847 }
848
849 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_rgb888_with_mask_helium(asm_dsc_t * dsc);
850 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_xrgb8888_with_mask_helium(asm_dsc_t * dsc);
851 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_rgb888_with_mask_helium(asm_dsc_t * dsc);
852 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_xrgb8888_with_mask_helium(asm_dsc_t * dsc);
853 static inline lv_result_t lv_rgb888_blend_normal_to_rgb888_with_mask_helium(lv_draw_sw_blend_image_dsc_t * dsc,
854 uint32_t dst_px_size, uint32_t src_px_size)
855 {
856 asm_dsc_t asm_dsc = {
857 .dst_buf = dsc->dest_buf,
858 .dst_w = dsc->dest_w,
859 .dst_h = dsc->dest_h,
860 .dst_stride = dsc->dest_stride,
861 .src_buf = dsc->src_buf,
862 .src_stride = dsc->src_stride,
863 .mask_buf = dsc->mask_buf,
864 .mask_stride = dsc->mask_stride
865 };
866 if(dst_px_size == 3) {
867 if(src_px_size == 3) {
868 _lv_rgb888_blend_normal_to_rgb888_with_mask_helium(&asm_dsc);
869 }
870 else {
871 _lv_xrgb8888_blend_normal_to_rgb888_with_mask_helium(&asm_dsc);
872 }
873 }
874 else {
875 if(src_px_size == 3) {
876 _lv_rgb888_blend_normal_to_xrgb8888_with_mask_helium(&asm_dsc);
877 }
878 else {
879 _lv_xrgb8888_blend_normal_to_xrgb8888_with_mask_helium(&asm_dsc);
880 }
881 }
882 return LV_RESULT_OK;
883 }
884
885 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_rgb888_mix_mask_opa_helium(asm_dsc_t * dsc);
886 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_xrgb8888_mix_mask_opa_helium(asm_dsc_t * dsc);
887 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_rgb888_mix_mask_opa_helium(asm_dsc_t * dsc);
888 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_xrgb8888_mix_mask_opa_helium(asm_dsc_t * dsc);
889 static inline lv_result_t lv_rgb888_blend_normal_to_rgb888_mix_mask_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc,
890 uint32_t dst_px_size, uint32_t src_px_size)
891 {
892 asm_dsc_t asm_dsc = {
893 .opa = dsc->opa,
894 .dst_buf = dsc->dest_buf,
895 .dst_w = dsc->dest_w,
896 .dst_h = dsc->dest_h,
897 .dst_stride = dsc->dest_stride,
898 .src_buf = dsc->src_buf,
899 .src_stride = dsc->src_stride,
900 .mask_buf = dsc->mask_buf,
901 .mask_stride = dsc->mask_stride
902 };
903 if(dst_px_size == 3) {
904 if(src_px_size == 3) {
905 _lv_rgb888_blend_normal_to_rgb888_mix_mask_opa_helium(&asm_dsc);
906 }
907 else {
908 _lv_xrgb8888_blend_normal_to_rgb888_mix_mask_opa_helium(&asm_dsc);
909 }
910 }
911 else {
912 if(src_px_size == 3) {
913 _lv_rgb888_blend_normal_to_xrgb8888_mix_mask_opa_helium(&asm_dsc);
914 }
915 else {
916 _lv_xrgb8888_blend_normal_to_xrgb8888_mix_mask_opa_helium(&asm_dsc);
917 }
918 }
919 return LV_RESULT_OK;
920 }
921
922 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_rgb888_helium(asm_dsc_t * dsc);
923 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_xrgb8888_helium(asm_dsc_t * dsc);
924 static inline lv_result_t lv_argb8888_blend_normal_to_rgb888_helium(lv_draw_sw_blend_image_dsc_t * dsc,
925 uint32_t dst_px_size)
926 {
927 asm_dsc_t asm_dsc = {
928 .dst_buf = dsc->dest_buf,
929 .dst_w = dsc->dest_w,
930 .dst_h = dsc->dest_h,
931 .dst_stride = dsc->dest_stride,
932 .src_buf = dsc->src_buf,
933 .src_stride = dsc->src_stride
934 };
935 if(dst_px_size == 3) {
936 _lv_argb8888_blend_normal_to_rgb888_helium(&asm_dsc);
937 }
938 else {
939 _lv_argb8888_blend_normal_to_xrgb8888_helium(&asm_dsc);
940 }
941 return LV_RESULT_OK;
942 }
943
944 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_rgb888_with_opa_helium(asm_dsc_t * dsc);
945 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_xrgb8888_with_opa_helium(asm_dsc_t * dsc);
946 static inline lv_result_t lv_argb8888_blend_normal_to_rgb888_with_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc,
947 uint32_t dst_px_size)
948 {
949 asm_dsc_t asm_dsc = {
950 .opa = dsc->opa,
951 .dst_buf = dsc->dest_buf,
952 .dst_w = dsc->dest_w,
953 .dst_h = dsc->dest_h,
954 .dst_stride = dsc->dest_stride,
955 .src_buf = dsc->src_buf,
956 .src_stride = dsc->src_stride
957 };
958 if(dst_px_size == 3) {
959 _lv_argb8888_blend_normal_to_rgb888_with_opa_helium(&asm_dsc);
960 }
961 else {
962 _lv_argb8888_blend_normal_to_xrgb8888_with_opa_helium(&asm_dsc);
963 }
964 return LV_RESULT_OK;
965 }
966
967 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_rgb888_with_mask_helium(asm_dsc_t * dsc);
968 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_xrgb8888_with_mask_helium(asm_dsc_t * dsc);
969 static inline lv_result_t lv_argb8888_blend_normal_to_rgb888_with_mask_helium(lv_draw_sw_blend_image_dsc_t * dsc,
970 uint32_t dst_px_size)
971 {
972 asm_dsc_t asm_dsc = {
973 .dst_buf = dsc->dest_buf,
974 .dst_w = dsc->dest_w,
975 .dst_h = dsc->dest_h,
976 .dst_stride = dsc->dest_stride,
977 .src_buf = dsc->src_buf,
978 .src_stride = dsc->src_stride,
979 .mask_buf = dsc->mask_buf,
980 .mask_stride = dsc->mask_stride
981 };
982 if(dst_px_size == 3) {
983 _lv_argb8888_blend_normal_to_rgb888_with_mask_helium(&asm_dsc);
984 }
985 else {
986 _lv_argb8888_blend_normal_to_xrgb8888_with_mask_helium(&asm_dsc);
987 }
988 return LV_RESULT_OK;
989 }
990
991 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_rgb888_mix_mask_opa_helium(asm_dsc_t * dsc);
992 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_xrgb8888_mix_mask_opa_helium(asm_dsc_t * dsc);
993 static inline lv_result_t lv_argb8888_blend_normal_to_rgb888_mix_mask_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc,
994 uint32_t dst_px_size)
995 {
996 asm_dsc_t asm_dsc = {
997 .opa = dsc->opa,
998 .dst_buf = dsc->dest_buf,
999 .dst_w = dsc->dest_w,
1000 .dst_h = dsc->dest_h,
1001 .dst_stride = dsc->dest_stride,
1002 .src_buf = dsc->src_buf,
1003 .src_stride = dsc->src_stride,
1004 .mask_buf = dsc->mask_buf,
1005 .mask_stride = dsc->mask_stride
1006 };
1007 if(dst_px_size == 3) {
1008 _lv_argb8888_blend_normal_to_rgb888_mix_mask_opa_helium(&asm_dsc);
1009 }
1010 else {
1011 _lv_argb8888_blend_normal_to_xrgb8888_mix_mask_opa_helium(&asm_dsc);
1012 }
1013 return LV_RESULT_OK;
1014 }
1015
1016 extern LVGL_HIDDEN void _lv_color_blend_to_argb8888_helium(asm_dsc_t * dsc);
1017 static inline lv_result_t lv_color_blend_to_argb8888_helium(lv_draw_sw_blend_fill_dsc_t * dsc)
1018 {
1019 asm_dsc_t asm_dsc = {
1020 .dst_buf = dsc->dest_buf,
1021 .dst_w = dsc->dest_w,
1022 .dst_h = dsc->dest_h,
1023 .dst_stride = dsc->dest_stride,
1024 .src_buf = &dsc->color
1025 };
1026
1027 _lv_color_blend_to_argb8888_helium(&asm_dsc);
1028 return LV_RESULT_OK;
1029 }
1030
1031 extern LVGL_HIDDEN void _lv_color_blend_to_argb8888_with_opa_helium(asm_dsc_t * dsc);
1032 static inline lv_result_t lv_color_blend_to_argb8888_with_opa_helium(lv_draw_sw_blend_fill_dsc_t * dsc)
1033 {
1034 asm_dsc_t asm_dsc = {
1035 .opa = dsc->opa,
1036 .dst_buf = dsc->dest_buf,
1037 .dst_w = dsc->dest_w,
1038 .dst_h = dsc->dest_h,
1039 .dst_stride = dsc->dest_stride,
1040 .src_buf = &dsc->color
1041 };
1042 _lv_color_blend_to_argb8888_with_opa_helium(&asm_dsc);
1043 return LV_RESULT_OK;
1044 }
1045
1046 extern LVGL_HIDDEN void _lv_color_blend_to_argb8888_with_mask_helium(asm_dsc_t * dsc);
1047 static inline lv_result_t lv_color_blend_to_argb8888_with_mask_helium(lv_draw_sw_blend_fill_dsc_t * dsc)
1048 {
1049 asm_dsc_t asm_dsc = {
1050 .dst_buf = dsc->dest_buf,
1051 .dst_w = dsc->dest_w,
1052 .dst_h = dsc->dest_h,
1053 .dst_stride = dsc->dest_stride,
1054 .src_buf = &dsc->color,
1055 .mask_buf = dsc->mask_buf,
1056 .mask_stride = dsc->mask_stride
1057 };
1058 _lv_color_blend_to_argb8888_with_mask_helium(&asm_dsc);
1059 return LV_RESULT_OK;
1060 }
1061
1062 extern LVGL_HIDDEN void _lv_color_blend_to_argb8888_mix_mask_opa_helium(asm_dsc_t * dsc);
1063 static inline lv_result_t lv_color_blend_to_argb8888_mix_mask_opa_helium(lv_draw_sw_blend_fill_dsc_t * dsc)
1064 {
1065 asm_dsc_t asm_dsc = {
1066 .opa = dsc->opa,
1067 .dst_buf = dsc->dest_buf,
1068 .dst_w = dsc->dest_w,
1069 .dst_h = dsc->dest_h,
1070 .dst_stride = dsc->dest_stride,
1071 .src_buf = &dsc->color,
1072 .mask_buf = dsc->mask_buf,
1073 .mask_stride = dsc->mask_stride
1074 };
1075 _lv_color_blend_to_argb8888_mix_mask_opa_helium(&asm_dsc);
1076 return LV_RESULT_OK;
1077 }
1078
1079 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_argb8888_helium(asm_dsc_t * dsc);
1080 static inline lv_result_t lv_rgb565_blend_normal_to_argb8888_helium(lv_draw_sw_blend_image_dsc_t * dsc)
1081 {
1082 asm_dsc_t asm_dsc = {
1083 .dst_buf = dsc->dest_buf,
1084 .dst_w = dsc->dest_w,
1085 .dst_h = dsc->dest_h,
1086 .dst_stride = dsc->dest_stride,
1087 .src_buf = dsc->src_buf,
1088 .src_stride = dsc->src_stride
1089 };
1090 _lv_rgb565_blend_normal_to_argb8888_helium(&asm_dsc);
1091 return LV_RESULT_OK;
1092 }
1093
1094 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_argb8888_with_opa_helium(asm_dsc_t * dsc);
1095 static inline lv_result_t lv_rgb565_blend_normal_to_argb8888_with_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc)
1096 {
1097 asm_dsc_t asm_dsc = {
1098 .opa = dsc->opa,
1099 .dst_buf = dsc->dest_buf,
1100 .dst_w = dsc->dest_w,
1101 .dst_h = dsc->dest_h,
1102 .dst_stride = dsc->dest_stride,
1103 .src_buf = dsc->src_buf,
1104 .src_stride = dsc->src_stride
1105 };
1106 _lv_rgb565_blend_normal_to_argb8888_with_opa_helium(&asm_dsc);
1107 return LV_RESULT_OK;
1108 }
1109
1110 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_argb8888_with_mask_helium(asm_dsc_t * dsc);
1111 static inline lv_result_t lv_rgb565_blend_normal_to_argb8888_with_mask_helium(lv_draw_sw_blend_image_dsc_t * dsc)
1112 {
1113 asm_dsc_t asm_dsc = {
1114 .dst_buf = dsc->dest_buf,
1115 .dst_w = dsc->dest_w,
1116 .dst_h = dsc->dest_h,
1117 .dst_stride = dsc->dest_stride,
1118 .src_buf = dsc->src_buf,
1119 .src_stride = dsc->src_stride,
1120 .mask_buf = dsc->mask_buf,
1121 .mask_stride = dsc->mask_stride
1122 };
1123 _lv_rgb565_blend_normal_to_argb8888_with_mask_helium(&asm_dsc);
1124 return LV_RESULT_OK;
1125 }
1126
1127 extern LVGL_HIDDEN void _lv_rgb565_blend_normal_to_argb8888_mix_mask_opa_helium(asm_dsc_t * dsc);
1128 static inline lv_result_t lv_rgb565_blend_normal_to_argb8888_mix_mask_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc)
1129 {
1130 asm_dsc_t asm_dsc = {
1131 .opa = dsc->opa,
1132 .dst_buf = dsc->dest_buf,
1133 .dst_w = dsc->dest_w,
1134 .dst_h = dsc->dest_h,
1135 .dst_stride = dsc->dest_stride,
1136 .src_buf = dsc->src_buf,
1137 .src_stride = dsc->src_stride,
1138 .mask_buf = dsc->mask_buf,
1139 .mask_stride = dsc->mask_stride
1140 };
1141 _lv_rgb565_blend_normal_to_argb8888_mix_mask_opa_helium(&asm_dsc);
1142 return LV_RESULT_OK;
1143 }
1144
1145 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_argb8888_helium(asm_dsc_t * dsc);
1146 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_argb8888_helium(asm_dsc_t * dsc);
1147 static inline lv_result_t lv_rgb888_blend_normal_to_argb8888_helium(lv_draw_sw_blend_image_dsc_t * dsc,
1148 uint32_t src_px_size)
1149 {
1150 asm_dsc_t asm_dsc = {
1151 .dst_buf = dsc->dest_buf,
1152 .dst_w = dsc->dest_w,
1153 .dst_h = dsc->dest_h,
1154 .dst_stride = dsc->dest_stride,
1155 .src_buf = dsc->src_buf,
1156 .src_stride = dsc->src_stride
1157 };
1158 if(src_px_size == 3) {
1159 _lv_rgb888_blend_normal_to_argb8888_helium(&asm_dsc);
1160 }
1161 else {
1162 _lv_xrgb8888_blend_normal_to_argb8888_helium(&asm_dsc);
1163 }
1164 return LV_RESULT_OK;
1165 }
1166
1167 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_argb8888_with_opa_helium(asm_dsc_t * dsc);
1168 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_argb8888_with_opa_helium(asm_dsc_t * dsc);
1169 static inline lv_result_t lv_rgb888_blend_normal_to_argb8888_with_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc,
1170 uint32_t src_px_size)
1171 {
1172 asm_dsc_t asm_dsc = {
1173 .opa = dsc->opa,
1174 .dst_buf = dsc->dest_buf,
1175 .dst_w = dsc->dest_w,
1176 .dst_h = dsc->dest_h,
1177 .dst_stride = dsc->dest_stride,
1178 .src_buf = dsc->src_buf,
1179 .src_stride = dsc->src_stride
1180 };
1181 if(src_px_size == 3) {
1182 _lv_rgb888_blend_normal_to_argb8888_with_opa_helium(&asm_dsc);
1183 }
1184 else {
1185 _lv_xrgb8888_blend_normal_to_argb8888_with_opa_helium(&asm_dsc);
1186 }
1187 return LV_RESULT_OK;
1188 }
1189
1190 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_argb8888_with_mask_helium(asm_dsc_t * dsc);
1191 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_argb8888_with_mask_helium(asm_dsc_t * dsc);
1192 static inline lv_result_t lv_rgb888_blend_normal_to_argb8888_with_mask_helium(lv_draw_sw_blend_image_dsc_t * dsc,
1193 uint32_t src_px_size)
1194 {
1195 asm_dsc_t asm_dsc = {
1196 .dst_buf = dsc->dest_buf,
1197 .dst_w = dsc->dest_w,
1198 .dst_h = dsc->dest_h,
1199 .dst_stride = dsc->dest_stride,
1200 .src_buf = dsc->src_buf,
1201 .src_stride = dsc->src_stride,
1202 .mask_buf = dsc->mask_buf,
1203 .mask_stride = dsc->mask_stride
1204 };
1205 if(src_px_size == 3) {
1206 _lv_rgb888_blend_normal_to_argb8888_with_mask_helium(&asm_dsc);
1207 }
1208 else {
1209 _lv_xrgb8888_blend_normal_to_argb8888_with_mask_helium(&asm_dsc);
1210 }
1211 return LV_RESULT_OK;
1212 }
1213
1214 extern LVGL_HIDDEN void _lv_rgb888_blend_normal_to_argb8888_mix_mask_opa_helium(asm_dsc_t * dsc);
1215 extern LVGL_HIDDEN void _lv_xrgb8888_blend_normal_to_argb8888_mix_mask_opa_helium(asm_dsc_t * dsc);
1216 static inline lv_result_t lv_rgb888_blend_normal_to_argb8888_mix_mask_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc,
1217 uint32_t src_px_size)
1218 {
1219 asm_dsc_t asm_dsc = {
1220 .opa = dsc->opa,
1221 .dst_buf = dsc->dest_buf,
1222 .dst_w = dsc->dest_w,
1223 .dst_h = dsc->dest_h,
1224 .dst_stride = dsc->dest_stride,
1225 .src_buf = dsc->src_buf,
1226 .src_stride = dsc->src_stride,
1227 .mask_buf = dsc->mask_buf,
1228 .mask_stride = dsc->mask_stride
1229 };
1230 if(src_px_size == 3) {
1231 _lv_rgb888_blend_normal_to_argb8888_mix_mask_opa_helium(&asm_dsc);
1232 }
1233 else {
1234 _lv_xrgb8888_blend_normal_to_argb8888_mix_mask_opa_helium(&asm_dsc);
1235 }
1236 return LV_RESULT_OK;
1237 }
1238
1239 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_argb8888_helium(asm_dsc_t * dsc);
1240 static inline lv_result_t lv_argb8888_blend_normal_to_argb8888_helium(lv_draw_sw_blend_image_dsc_t * dsc)
1241 {
1242 asm_dsc_t asm_dsc = {
1243 .dst_buf = dsc->dest_buf,
1244 .dst_w = dsc->dest_w,
1245 .dst_h = dsc->dest_h,
1246 .dst_stride = dsc->dest_stride,
1247 .src_buf = dsc->src_buf,
1248 .src_stride = dsc->src_stride
1249 };
1250 _lv_argb8888_blend_normal_to_argb8888_helium(&asm_dsc);
1251 return LV_RESULT_OK;
1252 }
1253
1254 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_argb8888_with_opa_helium(asm_dsc_t * dsc);
1255 static inline lv_result_t lv_argb8888_blend_normal_to_argb8888_with_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc)
1256 {
1257 asm_dsc_t asm_dsc = {
1258 .opa = dsc->opa,
1259 .dst_buf = dsc->dest_buf,
1260 .dst_w = dsc->dest_w,
1261 .dst_h = dsc->dest_h,
1262 .dst_stride = dsc->dest_stride,
1263 .src_buf = dsc->src_buf,
1264 .src_stride = dsc->src_stride
1265 };
1266 _lv_argb8888_blend_normal_to_argb8888_with_opa_helium(&asm_dsc);
1267 return LV_RESULT_OK;
1268 }
1269
1270 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_argb8888_with_mask_helium(asm_dsc_t * dsc);
1271 static inline lv_result_t lv_argb8888_blend_normal_to_argb8888_with_mask_helium(lv_draw_sw_blend_image_dsc_t * dsc)
1272 {
1273 asm_dsc_t asm_dsc = {
1274 .dst_buf = dsc->dest_buf,
1275 .dst_w = dsc->dest_w,
1276 .dst_h = dsc->dest_h,
1277 .dst_stride = dsc->dest_stride,
1278 .src_buf = dsc->src_buf,
1279 .src_stride = dsc->src_stride,
1280 .mask_buf = dsc->mask_buf,
1281 .mask_stride = dsc->mask_stride
1282 };
1283 _lv_argb8888_blend_normal_to_argb8888_with_mask_helium(&asm_dsc);
1284 return LV_RESULT_OK;
1285 }
1286
1287 extern LVGL_HIDDEN void _lv_argb8888_blend_normal_to_argb8888_mix_mask_opa_helium(asm_dsc_t * dsc);
1288 static inline lv_result_t lv_argb8888_blend_normal_to_argb8888_mix_mask_opa_helium(lv_draw_sw_blend_image_dsc_t * dsc)
1289 {
1290 asm_dsc_t asm_dsc = {
1291 .opa = dsc->opa,
1292 .dst_buf = dsc->dest_buf,
1293 .dst_w = dsc->dest_w,
1294 .dst_h = dsc->dest_h,
1295 .dst_stride = dsc->dest_stride,
1296 .src_buf = dsc->src_buf,
1297 .src_stride = dsc->src_stride,
1298 .mask_buf = dsc->mask_buf,
1299 .mask_stride = dsc->mask_stride
1300 };
1301 _lv_argb8888_blend_normal_to_argb8888_mix_mask_opa_helium(&asm_dsc);
1302 return LV_RESULT_OK;
1303 }
1304
1305 #endif /* LV_USE_NATIVE_HELIUM_ASM */
1306
1307 #endif /* !defined(__ASSEMBLY__) */
1308
1309 #endif /* defined(__ARM_FEATURE_MVE) && __ARM_FEATURE_MVE */
1310
1311 /**********************
1312 * MACROS
1313 **********************/
1314
1315 #ifdef __cplusplus
1316 } /*extern "C"*/
1317 #endif
1318
1319 #endif /*LV_BLEND_HELIUM_H*/