X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=include%2Ftdm_helper.h;h=62f3cb32a20f8bb688a0668de7caf3babe6c5a87;hb=f8a9700f675cfd49481d52ae31b57fd74303ba21;hp=1459e7215c8c12f8f1f6b7a881983fc52ffb331f;hpb=224add70bc00208471268a44ff1a49a0ad9daaec;p=platform%2Fcore%2Fuifw%2Flibtdm.git diff --git a/include/tdm_helper.h b/include/tdm_helper.h index 1459e72..62f3cb3 100644 --- a/include/tdm_helper.h +++ b/include/tdm_helper.h @@ -9,7 +9,7 @@ * Taeheon Kim , * YoungJun Cho , * SooChan Lim , - * Boram Park + * Boram Park * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the @@ -36,9 +36,10 @@ #ifndef _TDM_HELPER_H_ #define _TDM_HELPER_H_ -#include "tdm_types.h" #include +#include "tdm_types.h" + #ifdef __cplusplus extern "C" { #endif @@ -65,8 +66,6 @@ tdm_helper_get_time(void); * - TBM_FORMAT_YUV420 * - TBM_FORMAT_NV12 * - TBM_FORMAT_NV21 - * - TBM_FORMAT_YUYV - * - TBM_FORMAT_UYVY * The filename extension should be "png" for TBM_FORMAT_ARGB8888 and TBM_FORMAT_XRGB8888 * or "yuv" for YUV formats. * @param[in] buffer A TDM buffer @@ -76,6 +75,16 @@ void tdm_helper_dump_buffer(tbm_surface_h buffer, const char *file); /** + * @brief Dump a buffer. + * @details + * The filename will includes the buffer information. (width, height, format) + * @param[in] buffer A TDM buffer + * @param[in] file The path of file. + */ +void +tdm_helper_dump_buffer_str(tbm_surface_h buffer, char *dir, char *str); + +/** * @brief fill a buffer with 0 for given pos. * @details * This function supports only if a buffer has below formats. @@ -107,8 +116,6 @@ tdm_helper_clear_buffer_color(tbm_surface_h buffer, tdm_pos *pos, unsigned int c * - TBM_FORMAT_YUV420 * - TBM_FORMAT_NV12 * - TBM_FORMAT_NV21 - * - TBM_FORMAT_YUYV - * - TBM_FORMAT_UYVY * @param[in] buffer A TDM buffer */ void @@ -144,10 +151,6 @@ tdm_helper_convert_buffer(tbm_surface_h srcbuf, tbm_surface_h dstbuf, * @details * This function will dup the fd of the given enviroment variable. The Caller * @b SHOULD close the fd. - * \n - * In DRM system, a drm-master-fd @b SHOULD be shared between TDM backend and - * TBM backend in display server side by using "TDM_DRM_MASTER_FD" - * and "TBM_DRM_MASTER_FD". * @param[in] env The given enviroment variable * @return fd if success. Otherwise, -1. * @see #tdm_helper_set_fd() @@ -156,10 +159,6 @@ int tdm_helper_get_fd(const char *env); /** * @brief Set the given fd to the give enviroment variable. - * @details - * In DRM system, a drm-master-fd @b SHOULD be shared between TDM backend and - * TBM backend in display server side by using "TDM_DRM_MASTER_FD" - * and "TBM_DRM_MASTER_FD". * @param[in] env The given enviroment variable * @param[in] fd The given fd * @see #tdm_helper_get_fd() @@ -226,12 +225,20 @@ void tdm_helper_get_display_information(tdm_display *dpy, char *reply, int *len); /** - * @brief Get whether the commit-per-vblank functionality is enabled or not. - * @param[in] dpy A display object - * @return 1 if enabled. Otherwise, 0. + * @brief Get whether the commit-per-vblank functionality is enabled or not for the output. + * @param[in] output An output the functionality has to be checked for + * @return -1 if error occurred, 1 if enabled, 0 if disabled. */ int -tdm_helper_commit_per_vblank_enabled(tdm_display *dpy); +tdm_helper_output_commit_per_vblank_enabled(tdm_output *output); + +/** + * @brief Get whether the vblank timer is expired or not for the output. + * @param[in] output An output the functionality has to be checked for + * @return -1 if error occurred, 1 if enabled, 0 if disabled. + */ +unsigned int +tdm_helper_output_vblank_timer_expired(tdm_output *output); #ifdef __cplusplus }