Tizen Native API
_Evas_Native_Surface Struct Reference

Public Attributes

int version
Evas_Native_Surface_Type type
union {
   struct {
      void *   visual
      unsigned long   pixmap
   }   x11
   struct {
      unsigned int   texture_id
      unsigned int   framebuffer_id
      unsigned int   internal_format
      unsigned int   format
      unsigned int   h
   }   opengl
   struct {
      void *   buffer
      int   rot
      float   ratio
      int   flip
   }   tizen
   struct {
      void *   surface
   }   evasgl
data

Detailed Description

A generic datatype for engine specific native surface information.

Please fill up Evas_Native_Surface fields that regarded with current surface type. If you want to set the native surface type to EVAS_NATIVE_SURFACE_X11, you need to set union data with x11.visual or x11.pixmap. If you need to set the native surface as EVAS_NATIVE_SURFACE_OPENGL, on the other hand, you need to set union data with opengl.texture_id or opengl.framebuffer_id and so on. The version field should be set with EVAS_NATIVE_SURFACE_VERSION in order to check abi break in your application on the different efl library versions.

Warning:
Native surface types totally depend on the system. Please be aware that the types are supported on your system before using them.
See also:
evas_object_image_native_surface_set()

Member Data Documentation

tbm surface

Choose one union data according to your surface.

Set this struct fields if surface data is Evas GL based.

flip (0:none, 1:horizontal, 2:vertical, 3:both)

Same as 'format' for glTexImage2D()

0 if this is not an FBO, otherwise FBO ID from glGenFramebuffers()

Region inside the texture to use (Image size is assumed as texture size, with 0, 0 being the top-left and co-ordinates working down to the right and bottom being positive)

Same as 'internalFormat' for glTexImage2D()

Set this struct fields if your surface data is OpenGL based.

Pixmap ID to use (Pixmap)

width/height ratio of the source image

rotation (0, 90, 180, 270)

evas gl surface to use

opengl texture ID to use from glGenTextures()

Set this struct fields if your surface data is Tizen based.

Current Native Surface Version. Use EVAS_NATIVE_SURFACE_VERSION

Visual of the pixmap to use (Visual)

struct { ... } _Evas_Native_Surface::x11

Set this struct fields if your surface data is X11 based.