How to using littlevgl as a frame of video

Part of my project is to display a video,with buttons like “play” “pause” …
When I get the video data, how to display it? Does the video frame rate affect littlevgl operation?

The most simple way would be:

  1. create an lv_img_dsc_t, initialize width, height, color format, etc. (You can see an example in any converted image)
  2. Create an lv_img object which uses that image_dsc. E.g. lv_img_set_src(img_obj, &img_dsc)
  3. Change data in the image_dsc to the frame.
  4. Call lv_obj_invalidate(img_obj)