# lv_draw_opengles.h (/api/draw/opengles/lv_draw_opengles_h)



<ApiSummary functions="3" />

Functions [#functions]

<ApiMember kind="function" name="lv_draw_opengles_init" file="draw/opengles/lv_draw_opengles.h" line="35" url="https://github.com/lvgl/lvgl/tree/a7b95c5b0839ce901c09c205610bc2c77cc3345d/src/draw/opengles/lv_draw_opengles.h#L35">
  lv_draw_opengles_init [#lv_draw_opengles_init]

  ```c title=" " lineNumbers=1
  void lv_draw_opengles_init(void)
  ```
</ApiMember>

<ApiMember kind="function" name="lv_draw_opengles_deinit" file="draw/opengles/lv_draw_opengles.h" line="36" url="https://github.com/lvgl/lvgl/tree/a7b95c5b0839ce901c09c205610bc2c77cc3345d/src/draw/opengles/lv_draw_opengles.h#L36">
  lv_draw_opengles_deinit [#lv_draw_opengles_deinit]

  ```c title=" " lineNumbers=1
  void lv_draw_opengles_deinit(void)
  ```
</ApiMember>

<ApiMember kind="function" name="lv_draw_opengles_clear_layer_area" file="draw/opengles/lv_draw_opengles.h" line="48" url="https://github.com/lvgl/lvgl/tree/a7b95c5b0839ce901c09c205610bc2c77cc3345d/src/draw/opengles/lv_draw_opengles.h#L48">
  lv_draw_opengles_clear_layer_area [#lv_draw_opengles_clear_layer_area]

  Clear a region of the GPU texture that backs the given layer. Needed because `lv_draw_buf_clear` operates on the CPU draw buffer, which is only a dummy placeholder when the layer is rendered to a GL texture. Without this, a transparent screen background leaves stale pixels on the texture between frames.

  ```c title=" " lineNumbers=1
  void lv_draw_opengles_clear_layer_area(lv_layer_t *layer, const lv_area_t *area)
  ```

  <span className="sr-only">
    Parameters
  </span>

  | Name    | Type                                                     | Description                                 |
  | ------- | -------------------------------------------------------- | ------------------------------------------- |
  | `layer` | <ApiLink name="lv_layer_t" display="lv_layer_t *" />     | layer whose backing texture must be cleared |
  | `area`  | <ApiLink name="lv_area_t" display="const lv_area_t *" /> | area (in layer/screen coordinates) to clear |
</ApiMember>

Dependencies [#dependencies]

<FileIncludes includes="[&#x22;lv_conf_internal.h&#x22;, &#x22;lv_draw.h&#x22;, &#x22;lv_area.h&#x22;]" transitiveIncludes="[&#x22;lv_anim.h&#x22;, &#x22;lv_array.h&#x22;, &#x22;lv_assert.h&#x22;, &#x22;lv_bidi.h&#x22;, &#x22;lv_color.h&#x22;, &#x22;lv_color_op.h&#x22;, &#x22;lv_conf_kconfig.h&#x22;, &#x22;lv_draw_buf.h&#x22;, &#x22;lv_event.h&#x22;, &#x22;lv_ext_data.h&#x22;, &#x22;lv_flex.h&#x22;, &#x22;lv_font.h&#x22;, &#x22;lv_fs.h&#x22;, &#x22;lv_grad.h&#x22;, &#x22;lv_grid.h&#x22;, &#x22;lv_image_decoder.h&#x22;, &#x22;lv_image_dsc.h&#x22;, &#x22;lv_layout.h&#x22;, &#x22;lv_ll.h&#x22;, &#x22;lv_log.h&#x22;, &#x22;lv_math.h&#x22;, &#x22;lv_matrix.h&#x22;, &#x22;lv_mem.h&#x22;, &#x22;lv_palette.h&#x22;, &#x22;lv_profiler.h&#x22;, &#x22;lv_profiler_builtin.h&#x22;, &#x22;lv_sprintf.h&#x22;, &#x22;lv_string.h&#x22;, &#x22;lv_style.h&#x22;, &#x22;lv_style_gen.h&#x22;, &#x22;lv_symbol_def.h&#x22;, &#x22;lv_text.h&#x22;, &#x22;lv_tick.h&#x22;, &#x22;lv_timer.h&#x22;, &#x22;lv_types.h&#x22;]" />
