hwc_window: add the buffer dump
[platform/core/uifw/libtdm.git] / src / tdm_private.h
index 59cb1ad..4b23a4a 100644 (file)
@@ -53,6 +53,7 @@
 #include <sys/syscall.h>
 #include <sys/types.h>
 #include <math.h>
+#include <grp.h>
 
 #include <wayland-server-protocol.h>
 #include <tbm_bufmgr.h>
@@ -109,6 +110,7 @@ enum {
        TDM_DUMP_FLAG_LAYER   = (1 << 0),
        TDM_DUMP_FLAG_PP      = (1 << 1),
        TDM_DUMP_FLAG_CAPTURE = (1 << 2),
+       TDM_DUMP_FLAG_WINDOW = (1 << 3),
 };
 
 #define TDM_DUMP_DIR    "/tmp"
@@ -122,6 +124,7 @@ typedef enum {
 typedef struct _tdm_private_display tdm_private_display;
 typedef struct _tdm_private_output tdm_private_output;
 typedef struct _tdm_private_layer tdm_private_layer;
+typedef struct _tdm_private_hwc_window tdm_private_hwc_window;
 typedef struct _tdm_private_pp tdm_private_pp;
 typedef struct _tdm_private_capture tdm_private_capture;
 typedef struct _tdm_private_loop tdm_private_loop;
@@ -151,6 +154,7 @@ struct _tdm_private_display {
        tdm_func_display func_display;
        tdm_func_output func_output;
        tdm_func_layer func_layer;
+       tdm_func_hwc_window func_hwc_window;
        tdm_func_pp func_pp;
        tdm_func_capture func_capture;
 
@@ -176,6 +180,8 @@ struct _tdm_private_display {
        int commit_per_vblank;
        tdm_commit_type commit_type;
 
+       int hwc_enable;
+
        int print_fps;
 };
 
@@ -200,6 +206,7 @@ struct _tdm_private_output {
        int regist_dpms_cb;
 
        struct list_head layer_list;
+       struct list_head hwc_window_list;
        struct list_head capture_list;
        struct list_head vblank_handler_list;
        struct list_head output_commit_handler_list;
@@ -249,6 +256,19 @@ struct _tdm_private_layer {
        unsigned int fps_count;
 };
 
+struct _tdm_private_hwc_window {
+       struct list_head link;
+
+       int index;
+       uint32_t zpos;
+
+       tdm_private_display *private_display;
+       tdm_private_output *private_output;
+
+       tdm_hwc_window *hwc_window_backend;
+};
+
+
 struct _tdm_private_pp {
        struct list_head link;
 
@@ -466,6 +486,11 @@ tdm_pp_create_internal(tdm_private_display *private_display, tdm_error *error);
 void
 tdm_pp_destroy_internal(tdm_private_pp *private_pp);
 
+tdm_hwc_window *
+tdm_hwc_window_create_internal(tdm_private_output *private_output, tdm_error *error);
+tdm_error
+tdm_hwc_window_destroy_internal(tdm_private_hwc_window * private_hwc_window);
+
 tdm_private_capture *
 tdm_capture_create_output_internal(tdm_private_output *private_output,
                                                                   tdm_error *error);