tinyds-tdm: Fix build break 82/278182/1
authorSeunghun Lee <shiin.lee@samsung.com>
Tue, 26 Apr 2022 00:22:06 +0000 (09:22 +0900)
committerSooChan Lim <sc1.lim@samsung.com>
Mon, 18 Jul 2022 05:58:34 +0000 (14:58 +0900)
Change-Id: I75ab91d3d8195592b3aa661297cd8fa8f80d73f7

src/examples/tinyds-tdm.c

index c14cb9e..4bc08f1 100644 (file)
@@ -105,7 +105,8 @@ static void output_buffer_queue_init(struct tinyds_output *output);
 static void output_renderer_init(struct tinyds_output *output);
 static void output_draw_with_renderer(struct tinyds_output *output);
 #else
-static void output_swapchain_init(struct tinyds_output *output);
+static void output_swapchain_init(struct tinyds_output *output,
+        int width, int height, uint32_t format);
 static void output_draw_with_swapchain(struct tinyds_output *output);
 static void draw_view(struct tinyds_view *view, pixman_image_t *dst_image);
 #endif
@@ -273,7 +274,8 @@ backend_handle_new_output(struct wl_listener *listener, void *data)
     output_buffer_queue_init(output);
     output_renderer_init(output);
 #else
-    output_swapchain_init(output);
+    output_swapchain_init(output, mode->width, mode->height,
+            DRM_FORMAT_XRGB8888);
 #endif
 
     output->output_destroy.notify = output_handle_destroy;
@@ -456,13 +458,15 @@ output_draw_with_renderer(struct tinyds_output *output)
 }
 #else
 static void
-output_swapchain_init(struct tinyds_output *output)
+output_swapchain_init(struct tinyds_output *output,
+        int width, int height, uint32_t format);
+
 {
     output->allocator = ds_tbm_allocator_create();
     assert(output->allocator);
 
     output->swapchain = ds_swapchain_create(output->allocator,
-            mode->width, mode->height, DRM_FORMAT_XRGB8888);
+            width, height, format);
     assert(output->swapchain);
 }