dump layer buffer when calling tdm_layer_set_buffer 73/159773/2
authorChangyeon Lee <cyeon.lee@samsung.com>
Mon, 13 Nov 2017 04:48:13 +0000 (13:48 +0900)
committerChangyeon Lee <cyeon.lee@samsung.com>
Mon, 13 Nov 2017 05:41:33 +0000 (14:41 +0900)
Change-Id: Id0fdf736a3590a2251d59f1fb32f3d7beb692e62

src/tdm_layer.c

index c1a5d6bc051fd362d72cd109ed22c74ee2cbf3e3..246567592be150b141a73ab78d42fa33ce258319 100644 (file)
@@ -410,6 +410,10 @@ tdm_layer_set_buffer(tdm_layer *layer, tbm_surface_h buffer)
 
        _pthread_mutex_lock(&private_display->lock);
 
+       /* dump buffer */
+       if (tdm_dump_enable && !(private_layer->caps.capabilities & TDM_LAYER_CAPABILITY_VIDEO))
+               _tdm_layer_dump_buffer(private_layer, buffer);
+
        if (tdm_debug_dump & TDM_DUMP_FLAG_LAYER &&
                !(private_layer->caps.capabilities & TDM_LAYER_CAPABILITY_VIDEO)) {
                char str[TDM_PATH_LEN];
@@ -780,10 +784,6 @@ tdm_layer_commit_pending_data(tdm_private_layer *private_layer)
                        TDM_INFO("layer(%p) pending_buffer(%p) committed",
                                         private_layer, private_layer->pending_buffer);
 
-               /* dump buffer */
-               if (tdm_dump_enable && !(private_layer->caps.capabilities & TDM_LAYER_CAPABILITY_VIDEO))
-                       _tdm_layer_dump_buffer(private_layer, private_layer->pending_buffer);
-
                if (ret == TDM_ERROR_NONE) {
                        if (private_layer->waiting_buffer)
                                _tdm_layer_free_buffer(private_layer, private_layer->waiting_buffer);