lv_opengles_driver.h

Functions

void lv_opengles_init(void)

Initialize OpenGL

备注

it is not necessary to call this if you use lv_glfw_window_create

void lv_opengles_deinit(void)

Deinitialize OpenGL

备注

it is not necessary to call this if you use lv_glfw_window_create

void lv_opengles_render_texture(unsigned int texture, const lv_area_t *texture_area, lv_opa_t opa, int32_t disp_w, int32_t disp_h)

Render a texture

参数:
  • texture -- OpenGL texture ID

  • texture_area -- the area in the window to render the texture in

  • opa -- opacity to blend the texture with existing contents

  • disp_w -- width of the window being rendered to

  • disp_h -- height of the window being rendered to

void lv_opengles_render_clear(void)

Clear the window/display

void lv_opengles_viewport(int32_t x, int32_t y, int32_t w, int32_t h)

Set the OpenGL viewport

参数:
  • x -- x position of the viewport

  • y -- y position of the viewport

  • w -- width of the viewport

  • h -- height of the viewport