/lvgl-latest/src/misc/ |
D | lv_color.h | 65 #define LV_COLOR_FORMAT_GET_BPP(cf) ( \ argument 66 (cf) == LV_COLOR_FORMAT_I1 ? 1 : \ 67 (cf) == LV_COLOR_FORMAT_A1 ? 1 : \ 68 (cf) == LV_COLOR_FORMAT_I2 ? 2 : \ 69 (cf) == LV_COLOR_FORMAT_A2 ? 2 : \ 70 (cf) == LV_COLOR_FORMAT_I4 ? 4 : \ 71 (cf) == LV_COLOR_FORMAT_A4 ? 4 : \ 72 (cf) == LV_COLOR_FORMAT_L8 ? 8 : \ 73 (cf) == LV_COLOR_FORMAT_A8 ? 8 : \ 74 (cf) == LV_COLOR_FORMAT_I8 ? 8 : \ [all …]
|
/lvgl-latest/scripts/ |
D | LVGLImage.py | 212 def unpack_colors(data: bytes, cf: ColorFormat, w) -> List: 218 bpp = cf.bpp 222 if cf == ColorFormat.A4: 234 if cf == ColorFormat.A2: 244 if cf == ColorFormat.A1: 263 if cf == ColorFormat.RGB888: 269 elif cf == ColorFormat.RGB565A8: 281 elif cf == ColorFormat.ARGB8565: 309 cf: ColorFormat, 379 ncolors = cf.ncolors [all …]
|
/lvgl-latest/src/draw/ |
D | lv_draw_buf.c | 37 static uint32_t _calculate_draw_buf_size(uint32_t w, uint32_t h, lv_color_format_t cf, uint32_t str… 202 uint8_t bpp = lv_color_format_get_bpp(header->cf); in lv_draw_buf_clear() 222 LV_ASSERT_FORMAT_MSG(dest->header.cf == src->header.cf, "Color format mismatch: %d != %d", in lv_draw_buf_copy() 223 dest->header.cf, src->header.cf); in lv_draw_buf_copy() 230 if(LV_COLOR_FORMAT_IS_INDEXED(dest->header.cf)) { in lv_draw_buf_copy() 231 …lv_memcpy(dest->data, src->data, LV_COLOR_INDEXED_PALETTE_SIZE(dest->header.cf) * sizeof(lv_color3… in lv_draw_buf_copy() 261 uint32_t line_bytes = (line_width * lv_color_format_get_bpp(dest->header.cf) + 7) >> 3; in lv_draw_buf_copy() 271 lv_result_t lv_draw_buf_init(lv_draw_buf_t * draw_buf, uint32_t w, uint32_t h, lv_color_format_t cf… in lv_draw_buf_init() argument 278 if(stride == 0) stride = lv_draw_buf_width_to_stride(w, cf); in lv_draw_buf_init() 288 header->cf = cf; in lv_draw_buf_init() [all …]
|
D | lv_draw_buf.h | 36 #define LV_DRAW_BUF_STRIDE(w, cf) \ argument 37 LV_ROUND_UP(((w) * LV_COLOR_FORMAT_GET_BPP(cf) + 7) / 8, LV_DRAW_BUF_STRIDE_ALIGN) 40 #define LV_DRAW_BUF_SIZE(w, h, cf) \ argument 41 (LV_DRAW_BUF_STRIDE(w, cf) * (h) + LV_DRAW_BUF_ALIGN + \ 42 LV_COLOR_INDEXED_PALETTE_SIZE(cf) * sizeof(lv_color32_t)) 55 .cf = (_cf), \ 70 …lv_draw_buf_init(&name, header->w, header->h, (lv_color_format_t)header->cf, header->stride, buf_#… 220 lv_draw_buf_t * lv_draw_buf_create(uint32_t w, uint32_t h, lv_color_format_t cf, uint32_t stride); 237 lv_color_format_t cf, uint32_t stride); 265 lv_result_t lv_draw_buf_init(lv_draw_buf_t * draw_buf, uint32_t w, uint32_t h, lv_color_format_t cf… [all …]
|
/lvgl-latest/src/widgets/canvas/ |
D | lv_canvas.c | 71 void lv_canvas_set_buffer(lv_obj_t * obj, void * buf, int32_t w, int32_t h, lv_color_format_t cf) in lv_canvas_set_buffer() argument 77 uint32_t stride = lv_draw_buf_width_to_stride(w, cf); in lv_canvas_set_buffer() 78 lv_draw_buf_init(&canvas->static_buf, w, h, cf, stride, buf, stride * h); in lv_canvas_set_buffer() 114 lv_color_format_t cf = draw_buf->header.cf; in lv_canvas_set_px() local 117 if(LV_COLOR_FORMAT_IS_INDEXED(cf)) { in lv_canvas_set_px() 120 switch(cf) { in lv_canvas_set_px() 138 uint8_t bpp = lv_color_format_get_bpp(cf); in lv_canvas_set_px() 143 else if(cf == LV_COLOR_FORMAT_L8) { in lv_canvas_set_px() 146 else if(cf == LV_COLOR_FORMAT_A8) { in lv_canvas_set_px() 149 else if(cf == LV_COLOR_FORMAT_RGB565) { in lv_canvas_set_px() [all …]
|
/lvgl-latest/src/libs/bin_decoder/ |
D | lv_bin_decoder.c | 145 header->cf = header->magic; in lv_bin_decoder_info() 159 header->cf = LV_COLOR_FORMAT_A8; in lv_bin_decoder_info() 216 lv_color_format_t cf = dsc->header.cf; in lv_bin_decoder_open() local 221 else if(LV_COLOR_FORMAT_IS_INDEXED(cf)) { in lv_bin_decoder_open() 230 else if(LV_COLOR_FORMAT_IS_ALPHA_ONLY(cf)) { in lv_bin_decoder_open() 234 else if(cf == LV_COLOR_FORMAT_ARGB8888 \ in lv_bin_decoder_open() 235 || cf == LV_COLOR_FORMAT_XRGB8888 \ in lv_bin_decoder_open() 236 || cf == LV_COLOR_FORMAT_RGB888 \ in lv_bin_decoder_open() 237 || cf == LV_COLOR_FORMAT_RGB565 \ in lv_bin_decoder_open() 238 || cf == LV_COLOR_FORMAT_RGB565A8 \ in lv_bin_decoder_open() [all …]
|
/lvgl-latest/src/draw/nxp/pxp/ |
D | lv_pxp_utils.c | 41 pxp_output_pixel_format_t pxp_get_out_px_format(lv_color_format_t cf) in pxp_get_out_px_format() argument 45 switch(cf) { in pxp_get_out_px_format() 67 pxp_as_pixel_format_t pxp_get_as_px_format(lv_color_format_t cf) in pxp_get_as_px_format() argument 71 switch(cf) { in pxp_get_as_px_format() 94 pxp_ps_pixel_format_t pxp_get_ps_px_format(lv_color_format_t cf) in pxp_get_ps_px_format() argument 98 switch(cf) { in pxp_get_ps_px_format()
|
D | lv_pxp_utils.h | 59 pxp_output_pixel_format_t pxp_get_out_px_format(lv_color_format_t cf); 61 pxp_as_pixel_format_t pxp_get_as_px_format(lv_color_format_t cf); 64 pxp_ps_pixel_format_t pxp_get_ps_px_format(lv_color_format_t cf);
|
D | lv_draw_pxp.c | 110 lv_color_format_t cf) in lv_draw_pxp_rotate() argument 140 .pixelFormat = pxp_get_as_px_format(cf), in lv_draw_pxp_rotate() 150 .pixelFormat = pxp_get_out_px_format(cf), in lv_draw_pxp_rotate() 167 static inline bool _pxp_src_cf_supported(lv_color_format_t cf) in _pxp_src_cf_supported() argument 171 switch(cf) { in _pxp_src_cf_supported() 184 static inline bool _pxp_dest_cf_supported(lv_color_format_t cf) in _pxp_dest_cf_supported() argument 188 switch(cf) { in _pxp_dest_cf_supported() 215 bool src_has_alpha = (img_dsc->header.cf == LV_COLOR_FORMAT_ARGB8888); in _pxp_draw_img_supported() 291 if(img_dsc->header.cf >= LV_COLOR_FORMAT_PROPRIETARY_START) in _pxp_evaluate() 297 if((!_pxp_src_cf_supported(img_dsc->header.cf)) || in _pxp_evaluate()
|
/lvgl-latest/src/others/snapshot/ |
D | lv_snapshot.c | 47 lv_draw_buf_t * lv_snapshot_create_draw_buf(lv_obj_t * obj, lv_color_format_t cf) in lv_snapshot_create_draw_buf() argument 57 return lv_draw_buf_create(w, h, cf, LV_STRIDE_AUTO); in lv_snapshot_create_draw_buf() 74 lv_result_t lv_snapshot_take_to_draw_buf(lv_obj_t * obj, lv_color_format_t cf, lv_draw_buf_t * draw… in lv_snapshot_take_to_draw_buf() argument 80 switch(cf) { in lv_snapshot_take_to_draw_buf() 119 layer.color_format = cf; in lv_snapshot_take_to_draw_buf() 142 lv_draw_buf_t * lv_snapshot_take(lv_obj_t * obj, lv_color_format_t cf) in lv_snapshot_take() argument 145 lv_draw_buf_t * draw_buf = lv_snapshot_create_draw_buf(obj, cf); in lv_snapshot_take() 148 if(lv_snapshot_take_to_draw_buf(obj, cf, draw_buf) != LV_RESULT_OK) { in lv_snapshot_take() 162 lv_result_t lv_snapshot_take_to_buf(lv_obj_t * obj, lv_color_format_t cf, lv_image_dsc_t * dsc, in lv_snapshot_take_to_buf() argument 168 lv_draw_buf_init(&draw_buf, 1, 1, cf, buf_size, buf, buf_size); in lv_snapshot_take_to_buf() [all …]
|
D | lv_snapshot.h | 41 lv_draw_buf_t * lv_snapshot_take(lv_obj_t * obj, lv_color_format_t cf); 49 lv_draw_buf_t * lv_snapshot_create_draw_buf(lv_obj_t * obj, lv_color_format_t cf); 68 lv_result_t lv_snapshot_take_to_draw_buf(lv_obj_t * obj, lv_color_format_t cf, lv_draw_buf_t * draw… 88 lv_result_t lv_snapshot_take_to_buf(lv_obj_t * obj, lv_color_format_t cf, lv_image_dsc_t * dsc,
|
/lvgl-latest/src/drivers/display/st_ltdc/ |
D | lv_st_ltdc.c | 48 static lv_color_format_t get_lv_cf_from_layer_cf(uint32_t cf); 53 static uint32_t get_dma2d_output_cf_from_layer_cf(uint32_t cf); 54 static uint32_t get_dma2d_input_cf_from_lv_cf(uint32_t cf); 110 lv_color_format_t cf = get_lv_cf_from_layer_cf(layer_cf); in create() local 113 lv_display_set_color_format(disp, cf); in create() 119 uint32_t cf_size = lv_color_format_get_size(cf); in create() 157 lv_color_format_t cf = lv_display_get_color_format(disp); in flush_cb() local 161 uint32_t px_size = lv_color_format_get_size(cf); in flush_cb() 173 uint32_t dma2d_input_cf = get_dma2d_input_cf_from_lv_cf(cf); in flush_cb() 200 …draw_sw_rotate(px_map, first_pixel, area_width, area_height, area_stride, fb_stride, rotation, cf); in flush_cb() [all …]
|
/lvgl-latest/src/draw/nxp/vglite/ |
D | lv_draw_buf_vglite.c | 38 static uint32_t _width_to_stride(uint32_t w, lv_color_format_t cf); 76 lv_color_format_t cf = header->cf; in _invalidate_cache() local 89 uint8_t bits_per_pixel = lv_color_format_get_bpp(cf); in _invalidate_cache() 121 static uint32_t _width_to_stride(uint32_t w, lv_color_format_t cf) in _width_to_stride() argument 123 uint8_t bits_per_pixel = lv_color_format_get_bpp(cf); in _width_to_stride() 126 uint8_t align_bytes = vglite_get_stride_alignment(cf); in _width_to_stride()
|
D | lv_vglite_buf.c | 73 lv_color_format_t cf) in vglite_set_dest_buf() argument 75 vglite_set_buf(&_dest_vgbuf, (void *)buf, width, height, stride, cf); in vglite_set_dest_buf() 79 lv_color_format_t cf) in vglite_set_src_buf() argument 81 vglite_set_buf(&_src_vgbuf, (void *)buf, width, height, stride, cf); in vglite_set_src_buf() 86 lv_color_format_t cf) in vglite_set_buf() argument 88 vg_lite_buffer_format_t vgformat = vglite_get_buf_format(cf); in vglite_set_buf()
|
D | lv_vglite_utils.c | 181 vg_lite_buffer_format_t vglite_get_buf_format(lv_color_format_t cf) in vglite_get_buf_format() argument 185 switch(cf) { in vglite_get_buf_format() 228 uint8_t vglite_get_stride_alignment(lv_color_format_t cf) in vglite_get_stride_alignment() argument 232 switch(cf) { in vglite_get_stride_alignment() 263 bool vglite_src_buf_aligned(const void * buf, uint32_t stride, lv_color_format_t cf) in vglite_src_buf_aligned() argument 272 if(stride == 0 || stride % vglite_get_stride_alignment(cf)) in vglite_src_buf_aligned()
|
D | lv_vglite_buf.h | 84 lv_color_format_t cf); 97 lv_color_format_t cf); 112 lv_color_format_t cf);
|
D | lv_vglite_utils.h | 136 vg_lite_buffer_format_t vglite_get_buf_format(lv_color_format_t cf); 146 uint8_t vglite_get_stride_alignment(lv_color_format_t cf); 158 bool vglite_src_buf_aligned(const void * buf, uint32_t stride, lv_color_format_t cf);
|
/lvgl-latest/src/draw/dma2d/ |
D | lv_draw_dma2d_fill.c | 40 lv_color_format_t cf = dsc->base.layer->color_format; in lv_draw_dma2d_opaque_fill() local 42 lv_draw_dma2d_output_cf_t output_cf = lv_draw_dma2d_cf_to_dma2d_output_cf(cf); in lv_draw_dma2d_opaque_fill() 43 uint32_t cf_size = LV_COLOR_FORMAT_GET_SIZE(cf); in lv_draw_dma2d_opaque_fill() 74 lv_color_format_t cf = dsc->base.layer->color_format; in lv_draw_dma2d_fill() local 77 lv_draw_dma2d_output_cf_t output_cf = lv_draw_dma2d_cf_to_dma2d_output_cf(cf); in lv_draw_dma2d_fill() 78 uint32_t cf_size = LV_COLOR_FORMAT_GET_SIZE(cf); in lv_draw_dma2d_fill() 113 if(cf == LV_COLOR_FORMAT_XRGB8888) { in lv_draw_dma2d_fill()
|
D | lv_draw_dma2d.c | 125 lv_draw_dma2d_output_cf_t lv_draw_dma2d_cf_to_dma2d_output_cf(lv_color_format_t cf) in lv_draw_dma2d_cf_to_dma2d_output_cf() argument 127 switch(cf) { in lv_draw_dma2d_cf_to_dma2d_output_cf() 143 uint32_t lv_draw_dma2d_color_to_dma2d_color(lv_draw_dma2d_output_cf_t cf, lv_color_t color) in lv_draw_dma2d_color_to_dma2d_color() argument 145 switch(cf) { in lv_draw_dma2d_color_to_dma2d_color() 300 if(!(dsc->header.cf < LV_COLOR_FORMAT_PROPRIETARY_START in evaluate_cb() 313 && (dsc->header.cf == LV_COLOR_FORMAT_ARGB8888 in evaluate_cb() 314 || dsc->header.cf == LV_COLOR_FORMAT_XRGB8888 in evaluate_cb() 315 || dsc->header.cf == LV_COLOR_FORMAT_RGB888 in evaluate_cb() 316 || dsc->header.cf == LV_COLOR_FORMAT_RGB565 in evaluate_cb() 317 || dsc->header.cf == LV_COLOR_FORMAT_ARGB1555) in evaluate_cb()
|
/lvgl-latest/src/draw/sw/ |
D | lv_draw_sw_img.c | 77 lv_color_format_t cf, const lv_draw_image_dsc_t * draw_dsc); 219 lv_color_format_t cf = decoded->header.cf; in img_draw_core() local 227 if(!transformed && !radius && cf == LV_COLOR_FORMAT_A8) { in img_draw_core() 241 …else if(!transformed && !radius && cf == LV_COLOR_FORMAT_RGB565A8 && draw_dsc->recolor_opa <= LV_O… in img_draw_core() 260 else if(!transformed && !radius && (cf == LV_COLOR_FORMAT_L8 || cf == LV_COLOR_FORMAT_AL88)) { in img_draw_core() 264 blend_dsc.src_color_format = cf; in img_draw_core() 272 blend_dsc.src_color_format = cf; in img_draw_core() 284 cf, /* image format */ in img_draw_core() 303 lv_color_format_t cf = decoded->header.cf; in radius_only() local 304 lv_color_format_t cf_ori = cf; in radius_only() [all …]
|
/lvgl-latest/src/draw/vg_lite/ |
D | lv_vg_lite_decoder.c | 32 #define IS_CONV_INDEX_FORMAT(cf) (cf == LV_COLOR_FORMAT_I1 || cf == LV_COLOR_FORMAT_I2 || cf == LV_… argument 106 uint32_t ori_stride = header->w * lv_color_format_get_bpp(header->cf); in image_stride() 160 if(!IS_CONV_INDEX_FORMAT(header->cf)) { in decoder_info() 165 LV_LOG_WARN("NOT Supported compressed index format: %d", header->cf); in decoder_info() 169 header->cf = DEST_IMG_FORMAT; in decoder_info() 183 lv_color_format_t src_cf = src_img_buf.header.cf; in decoder_open_variable() 278 uint32_t palette_size = LV_COLOR_INDEXED_PALETTE_SIZE(src_header.cf); in decoder_open_file() 320 image_decode_to_index8_line(dest, src_temp, width, src_header.cf); in decoder_open_file()
|
/lvgl-latest/demos/benchmark/assets/ |
D | img_benchmark_lvgl_logo_rgb.c | 335 .header.cf = LV_COLOR_FORMAT_RGB565, 337 .header.cf = LV_COLOR_FORMAT_RGB888, 339 .header.cf = LV_COLOR_FORMAT_XRGB8888,
|
/lvgl-latest/src/drivers/sdl/ |
D | lv_sdl_window.c | 213 lv_color_format_t cf = lv_display_get_color_format(disp); in flush_cb() local 219 if(cf == LV_COLOR_FORMAT_I1) { in flush_cb() 221 cf = LV_COLOR_FORMAT_ARGB8888; in flush_cb() 242 uint32_t px_map_stride = lv_draw_buf_width_to_stride(lv_area_get_width(area), cf); in flush_cb() 243 uint32_t px_size = lv_color_format_get_size(cf); in flush_cb() 245 int32_t fb_stride = lv_draw_buf_width_to_stride(disp->hor_res, cf); in flush_cb() 261 … lv_draw_sw_rotate(px_map, fb_start, px_map_w, px_map_h, px_map_stride, fb_stride, rotation, cf); in flush_cb() 378 lv_color_format_t cf = lv_display_get_color_format(disp); in window_update() local 379 if(cf == LV_COLOR_FORMAT_I1) { in window_update() 380 cf = LV_COLOR_FORMAT_ARGB8888; in window_update() [all …]
|
/lvgl-latest/src/draw/nema_gfx/ |
D | lv_draw_nema_gfx_utils.c | 43 uint32_t lv_nemagfx_cf_to_nema(lv_color_format_t cf) in lv_nemagfx_cf_to_nema() argument 45 switch(cf) { in lv_nemagfx_cf_to_nema() 130 bool lv_nemagfx_is_cf_supported(lv_color_format_t cf) in lv_nemagfx_is_cf_supported() argument 133 switch(cf) { in lv_nemagfx_is_cf_supported()
|
D | lv_draw_nema_gfx_img.c | 48 static uint32_t lv_nemagfx_mask_cf_to_nema(lv_color_format_t cf); 132 lv_color_format_t dst_cf = layer->draw_buf->header.cf; in _draw_nema_gfx_img() 139 lv_color_format_t src_cf = img_dsc->header.cf; in _draw_nema_gfx_img() 176 …if(dsc->bitmap_mask_src->header.cf == LV_COLOR_FORMAT_A8 || dsc->bitmap_mask_src->header.cf == LV_… in _draw_nema_gfx_img() 192 lv_nemagfx_mask_cf_to_nema(mask->header.cf), in _draw_nema_gfx_img() 242 static uint32_t lv_nemagfx_mask_cf_to_nema(lv_color_format_t cf) in lv_nemagfx_mask_cf_to_nema() argument 244 switch(cf) { in lv_nemagfx_mask_cf_to_nema()
|