1
0
mirror of https://github.com/lvgl/lvgl.git synced 2025-01-28 07:03:00 +08:00
lvgl/examples/libs/ffmpeg/lv_example_ffmpeg_1.py

22 lines
419 B
Python
Raw Normal View History

#!/opt/bin/lv_micropython-ffmpeg -i
import sys
import lvgl as lv
import display_driver
try:
#
# Open an image from a file
#
image = lv.image(lv.screen_active())
image.set_src("ffmpeg.png")
image.center()
except Exception as e:
print(e)
# TODO
# fallback for online examples
label = lv.label(lv.screen_active())
label.set_text("FFmpeg is not installed")
label.center()