From: Changyeon Lee Date: Fri, 10 Aug 2018 04:57:37 +0000 (+0900) Subject: hwc_window: rename get_buffer_queue to acquire_buffer_queue X-Git-Tag: accepted/tizen/unified/20180813.061409~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F27%2F186527%2F1;p=platform%2Fcore%2Fuifw%2Flibtdm.git hwc_window: rename get_buffer_queue to acquire_buffer_queue Change-Id: Ie5e45480833bee69978192bdd2a98b875456a404 --- diff --git a/haltests/src/tc_tdm_hwc_window.cpp b/haltests/src/tc_tdm_hwc_window.cpp index b330e85..1e704a7 100644 --- a/haltests/src/tc_tdm_hwc_window.cpp +++ b/haltests/src/tc_tdm_hwc_window.cpp @@ -81,7 +81,7 @@ TEST_P(TDMHwcWindow, DestroyWindowSuccessful) } } -/* tbm_surface_queue_h tdm_hwc_window_get_buffer_queue() */ +/* tbm_surface_queue_h tdm_hwc_window_acquire_buffer_queue() */ TEST_P(TDMHwcWindow, GetBufferQueueFailNull) { TDM_UT_SKIP_FLAG(has_outputs); @@ -89,11 +89,11 @@ TEST_P(TDMHwcWindow, GetBufferQueueFailNull) tdm_error error = TDM_ERROR_NONE; tbm_surface_queue_h queue = NULL; - queue = tdm_hwc_window_get_buffer_queue(NULL, &error); + queue = tdm_hwc_window_acquire_buffer_queue(NULL, &error); ASSERT_NE(TDM_ERROR_NONE, error); ASSERT_EQ(NULL, queue); - queue = tdm_hwc_window_get_buffer_queue(NULL, NULL); + queue = tdm_hwc_window_acquire_buffer_queue(NULL, NULL); ASSERT_EQ(NULL, queue); } @@ -126,13 +126,13 @@ TEST_P(TDMHwcWindow, GetBufferQueueSuccessful) error = tdm_hwc_window_set_info(hwc_wins[w], &info); ASSERT_EQ(TDM_ERROR_NONE, error); - queue = tdm_hwc_window_get_buffer_queue(hwc_wins[w], &error); - tbm_surface_queue_destroy(queue); + queue = tdm_hwc_window_acquire_buffer_queue(hwc_wins[w], &error); + tdm_hwc_window_release_buffer_queue(hwc_wins[w], queue); ASSERT_EQ(TDM_ERROR_NONE, error); ASSERT_NE(NULL, queue); - queue = tdm_hwc_window_get_buffer_queue(hwc_wins[w], NULL); - tbm_surface_queue_destroy(queue); + queue = tdm_hwc_window_acquire_buffer_queue(hwc_wins[w], NULL); + tdm_hwc_window_release_buffer_queue(hwc_wins[w], queue); ASSERT_NE(NULL, queue); } diff --git a/include/tdm.h b/include/tdm.h index 7a5893d..0b40cd5 100644 --- a/include/tdm.h +++ b/include/tdm.h @@ -992,7 +992,7 @@ void tdm_hwc_window_destroy(tdm_hwc_window *hwc_window); /** - * @brief Get a buffer queue for the window object + * @brief Acquire a buffer queue for the window object * @details These buffers are used to composite by hardware a client content in * the nocomp mode. * @param[in] hwc_window A window object @@ -1001,7 +1001,7 @@ tdm_hwc_window_destroy(tdm_hwc_window *hwc_window); * @since 2.0.0 */ tbm_surface_queue_h -tdm_hwc_window_get_buffer_queue(tdm_hwc_window *hwc_window, tdm_error *error); +tdm_hwc_window_acquire_buffer_queue(tdm_hwc_window *hwc_window, tdm_error *error); /** * @brief Release a buffer queue for the window object diff --git a/include/tdm_backend.h b/include/tdm_backend.h index 12b088c..f695562 100644 --- a/include/tdm_backend.h +++ b/include/tdm_backend.h @@ -868,8 +868,8 @@ typedef struct _tdm_func_hwc_window { * @param[out] error #TDM_ERROR_NONE if success. Otherwise, error value. * @return A buffer queue */ - tbm_surface_queue_h (*hwc_window_get_buffer_queue)(tdm_hwc_window *hwc_window, - tdm_error *error); + tbm_surface_queue_h (*hwc_window_acquire_buffer_queue)(tdm_hwc_window *hwc_window, + tdm_error *error); /** * @brief Release a buffer queue for the window object diff --git a/include/tdm_types.h b/include/tdm_types.h index c596ac6..225325f 100644 --- a/include/tdm_types.h +++ b/include/tdm_types.h @@ -210,7 +210,7 @@ typedef enum { /** If the client needs to render to a specific buffer for compositing * with TDM_COMPOSITION_DEVICE, Set TDM_PREPARATION_BUFFER_QUEUE type to hwc_window. * The client will render next frame on buffers of queue which got by - * tdm_hwc_window_get_buffer_queue. + * tdm_hwc_window_acquire_buffer_queue. */ TDM_PREPARATION_BUFFER_QUEUE = (1 << 0), } tdm_hwc_window_preparation; diff --git a/src/tdm_hwc_window.c b/src/tdm_hwc_window.c index 72b80af..0066ef3 100644 --- a/src/tdm_hwc_window.c +++ b/src/tdm_hwc_window.c @@ -185,7 +185,7 @@ tdm_hwc_window_destroy(tdm_hwc_window *hwc_window) } EXTERN tbm_surface_queue_h -tdm_hwc_window_get_buffer_queue(tdm_hwc_window *hwc_window, tdm_error *error) +tdm_hwc_window_acquire_buffer_queue(tdm_hwc_window *hwc_window, tdm_error *error) { tdm_private_module *private_module; tdm_func_hwc_window *func_hwc_window = NULL; @@ -198,7 +198,7 @@ tdm_hwc_window_get_buffer_queue(tdm_hwc_window *hwc_window, tdm_error *error) private_module = private_output->private_module; func_hwc_window = &private_module->func_hwc_window; - if (!func_hwc_window->hwc_window_get_buffer_queue) { + if (!func_hwc_window->hwc_window_acquire_buffer_queue) { /* LCOV_EXCL_START */ _pthread_mutex_unlock(&private_display->lock); TDM_WRN("not implemented!!"); @@ -207,7 +207,7 @@ tdm_hwc_window_get_buffer_queue(tdm_hwc_window *hwc_window, tdm_error *error) return NULL; } - queue = func_hwc_window->hwc_window_get_buffer_queue(private_hwc_window->hwc_window_backend, error); + queue = func_hwc_window->hwc_window_acquire_buffer_queue(private_hwc_window->hwc_window_backend, error); _pthread_mutex_unlock(&private_display->lock);