Skip to content

Commit

Permalink
Merge branch 'master' into custom_calendar_year
Browse files Browse the repository at this point in the history
  • Loading branch information
C47D authored Jan 8, 2024
2 parents 0376527 + a9960c6 commit 2e10819
Show file tree
Hide file tree
Showing 155 changed files with 3,001 additions and 1,853 deletions.
2 changes: 0 additions & 2 deletions .devcontainer/__lv_conf.h__
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
#ifndef LV_CONF_H
#define LV_CONF_H

#include <stdint.h>

#define LV_USE_DEV_VERSION 1

/*====================
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ccpp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ jobs:
install: |
apt-get update -y
apt-get install build-essential ccache python3 libpng-dev ruby-full gcovr cmake libjpeg62-turbo-dev -q -y
apt-get install build-essential ccache libgcc-10-dev python3 libpng-dev ruby-full gcovr cmake libjpeg62-turbo-dev libfreetype6-dev libasan6 -q -y
/usr/sbin/update-ccache-symlinks
echo 'export PATH="/usr/lib/ccache:$PATH"' | tee -a ~/.bashrc
Expand Down
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,5 @@ tests/build_*/
tests/report/
.DS_Store
.vscode
.idea
*.bak


14 changes: 2 additions & 12 deletions Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -1150,24 +1150,14 @@ menu "LVGL configuration"
config LV_FREETYPE_USE_LVGL_PORT
bool "Let FreeType to use LVGL memory and file porting"
default n
choice
prompt "Freetype cache type"
default LV_FREETYPE_CACHE_TYPE_IMAGE

config LV_FREETYPE_CACHE_TYPE_IMAGE
bool "IMAGE"
config LV_FREETYPE_CACHE_TYPE_OUTLINE
bool "OUTLINE"
endchoice
config LV_FREETYPE_CACHE_FT_FACES
int "The maximum number of FT_Face"
default 8
config LV_FREETYPE_CACHE_FT_SIZES
int "The maximum number of FT_Size"
default 8
config LV_FREETYPE_CACHE_FT_OUTLINES
int "The maximum number of Outline"
depends on LV_FREETYPE_CACHE_TYPE_OUTLINE
config LV_FREETYPE_CACHE_FT_GLYPH_CNT
int "The maximum number of Glyph in count"
default 256
endmenu

Expand Down
34 changes: 22 additions & 12 deletions demos/benchmark/lv_demo_benchmark.c
Original file line number Diff line number Diff line change
Expand Up @@ -476,11 +476,19 @@ static void sysmon_perf_observer_cb(lv_observer_t * observer, lv_subject_t * sub
const lv_sysmon_perf_info_t * info = lv_subject_get_pointer(subject);
lv_obj_t * label = lv_observer_get_target(observer);

char scene_name[64];
if(scenes[scene_act].name[0] != '\0') {
lv_snprintf(scene_name, sizeof(scene_name), "%s: ", scenes[scene_act].name);
}
else {
scene_name[0] = '\0';
}

lv_label_set_text_fmt(label,
"%s: "
"%s"
"%" LV_PRIu32" FPS, %" LV_PRIu32 "%% CPU\n"
"refr. %" LV_PRIu32" ms = %" LV_PRIu32 "ms render + %" LV_PRIu32" ms flush",
scenes[scene_act].name,
scene_name,
info->calculated.fps, info->calculated.cpu,
info->calculated.render_avg_time + info->calculated.flush_avg_time,
info->calculated.render_avg_time, info->calculated.flush_avg_time);
Expand Down Expand Up @@ -544,17 +552,15 @@ static void summary_create(void)
lv_table_set_cell_value(table, 0, 0, "Name");
lv_table_set_cell_value(table, 0, 1, "Avg. CPU");
lv_table_set_cell_value(table, 0, 2, "Avg. FPS");
lv_table_set_cell_value(table, 0, 3, "Avg. render time");
lv_table_set_cell_value(table, 0, 4, "Avg. flush time");
lv_table_set_cell_value(table, 0, 3, "Avg. time (render + flush)");

lv_obj_update_layout(table);
int32_t col_w = lv_obj_get_content_width(table) / 5;
int32_t col_w = lv_obj_get_content_width(table) / 4;

lv_table_set_column_width(table, 0, col_w);
lv_table_set_column_width(table, 1, col_w);
lv_table_set_column_width(table, 2, col_w);
lv_table_set_column_width(table, 3, col_w);
lv_table_set_column_width(table, 4, col_w);

uint32_t i;
int32_t total_avg_fps = 0;
Expand All @@ -570,14 +576,16 @@ static void summary_create(void)
lv_table_set_cell_value(table, i + 2, 1, "N/A");
lv_table_set_cell_value(table, i + 2, 2, "N/A");
lv_table_set_cell_value(table, i + 2, 3, "N/A");
lv_table_set_cell_value(table, i + 2, 4, "N/A");
}
else {
int32_t cnt = scenes[i].measurement_cnt - 1;
lv_table_set_cell_value_fmt(table, i + 2, 1, "%"LV_PRIu32" %%", scenes[i].cpu_avg_usage / cnt);
lv_table_set_cell_value_fmt(table, i + 2, 2, "%"LV_PRIu32" FPS", scenes[i].fps_avg / cnt);
lv_table_set_cell_value_fmt(table, i + 2, 3, "%"LV_PRIu32" ms", scenes[i].render_avg_time / cnt);
lv_table_set_cell_value_fmt(table, i + 2, 4, "%"LV_PRIu32" ms", scenes[i].flush_avg_time / cnt);

uint32_t render_time = scenes[i].render_avg_time / cnt;
uint32_t flush_time = scenes[i].flush_avg_time / cnt;
lv_table_set_cell_value_fmt(table, i + 2, 3, "%"LV_PRIu32" ms (%"LV_PRIu32" + %"LV_PRIu32")",
render_time + flush_time, render_time, flush_time);

valid_scene_cnt++;
total_avg_cpu += scenes[i].cpu_avg_usage / cnt;
Expand All @@ -593,13 +601,15 @@ static void summary_create(void)
lv_table_set_cell_value(table, 1, 1, "N/A");
lv_table_set_cell_value(table, 1, 2, "N/A");
lv_table_set_cell_value(table, 1, 3, "N/A");
lv_table_set_cell_value(table, 1, 4, "N/A");
}
else {
lv_table_set_cell_value_fmt(table, 1, 1, "%"LV_PRIu32" %%", total_avg_cpu / valid_scene_cnt);
lv_table_set_cell_value_fmt(table, 1, 2, "%"LV_PRIu32" FPS", total_avg_fps / valid_scene_cnt);
lv_table_set_cell_value_fmt(table, 1, 3, "%"LV_PRIu32" ms", total_avg_render_time / valid_scene_cnt);
lv_table_set_cell_value_fmt(table, 1, 4, "%"LV_PRIu32" ms", total_avg_flush_time / valid_scene_cnt);

uint32_t render_time = total_avg_render_time / valid_scene_cnt;
uint32_t flush_time = total_avg_flush_time / valid_scene_cnt;
lv_table_set_cell_value_fmt(table, 1, 3, "%"LV_PRIu32" ms (%"LV_PRIu32" + %"LV_PRIu32")",
render_time + flush_time, render_time, flush_time);
}
}

Expand Down
6 changes: 3 additions & 3 deletions docs/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,12 @@ Main new features
- Run time display color format adjustment with RGB888 support
- Built-in support ``pthread``, ``FreeRTOS`` and other (RT)OSes which are used during rendering
- Built-in support LVGL's, C library, and other ``stdlib``s
- Better parallel rendering architecture. See the details `here </porting/draw>`__
- Better parallel rendering architecture. See the details :ref:`here <porting_draw>`
- Built in display and touch driver: SDL, Linux Frame buffer, NuttX LCD and touch drivers, ST7789 and ILI9341 driver are available and more will come soon
- `lv_observer </others/observer>`__ allows to bind data to UI elements and create a uniform and easy to maintain API
- :ref:`observer` allows to bind data to UI elements and create a uniform and easy to maintain API
- GitHub CodeSpace integration makes possible to run LVGL in an Online VSCode editor with 3 click. See more `here <https://blog.lvgl.io/2023-04-13/monthly-newsletter>`__
- Add vector graphics support via ThorVG. It can be used to draw vector graphics to a `Canvas <https://github.com/lvgl/lvgl/blob/master/examples/widgets/canvas/lv_example_canvas_8.c>`__
- `lv_image </widgets/image>`__ supports aligning, stretching or tiling the image source if the widget is larger or smaller.
- :ref:`lv_image` supports aligning, stretching or tiling the image source if the widget is larger or smaller.
General API changes
-------------------
Expand Down
Loading

0 comments on commit 2e10819

Please sign in to comment.