| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "components/exo/wayland/server.h" | 5 #include "components/exo/wayland/server.h" |
| 6 | 6 |
| 7 #include <grp.h> | 7 #include <grp.h> |
| 8 #include <linux/input.h> | 8 #include <linux/input.h> |
| 9 #include <stddef.h> | 9 #include <stddef.h> |
| 10 #include <stdint.h> | 10 #include <stdint.h> |
| (...skipping 455 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 466 | 466 |
| 467 const struct drm_supported_format { | 467 const struct drm_supported_format { |
| 468 uint32_t drm_format; | 468 uint32_t drm_format; |
| 469 gfx::BufferFormat buffer_format; | 469 gfx::BufferFormat buffer_format; |
| 470 } drm_supported_formats[] = { | 470 } drm_supported_formats[] = { |
| 471 {WL_DRM_FORMAT_RGB565, gfx::BufferFormat::BGR_565}, | 471 {WL_DRM_FORMAT_RGB565, gfx::BufferFormat::BGR_565}, |
| 472 {WL_DRM_FORMAT_XBGR8888, gfx::BufferFormat::RGBX_8888}, | 472 {WL_DRM_FORMAT_XBGR8888, gfx::BufferFormat::RGBX_8888}, |
| 473 {WL_DRM_FORMAT_ABGR8888, gfx::BufferFormat::RGBA_8888}, | 473 {WL_DRM_FORMAT_ABGR8888, gfx::BufferFormat::RGBA_8888}, |
| 474 {WL_DRM_FORMAT_XRGB8888, gfx::BufferFormat::BGRX_8888}, | 474 {WL_DRM_FORMAT_XRGB8888, gfx::BufferFormat::BGRX_8888}, |
| 475 {WL_DRM_FORMAT_ARGB8888, gfx::BufferFormat::BGRA_8888}, | 475 {WL_DRM_FORMAT_ARGB8888, gfx::BufferFormat::BGRA_8888}, |
| 476 {WL_DRM_FORMAT_NV12, gfx::BufferFormat::YUV_420_BIPLANAR}, |
| 476 {WL_DRM_FORMAT_YVU420, gfx::BufferFormat::YVU_420}}; | 477 {WL_DRM_FORMAT_YVU420, gfx::BufferFormat::YVU_420}}; |
| 477 | 478 |
| 478 void drm_authenticate(wl_client* client, wl_resource* resource, uint32_t id) { | 479 void drm_authenticate(wl_client* client, wl_resource* resource, uint32_t id) { |
| 479 wl_drm_send_authenticated(resource); | 480 wl_drm_send_authenticated(resource); |
| 480 } | 481 } |
| 481 | 482 |
| 482 void drm_create_buffer(wl_client* client, | 483 void drm_create_buffer(wl_client* client, |
| 483 wl_resource* resource, | 484 wl_resource* resource, |
| 484 uint32_t id, | 485 uint32_t id, |
| 485 uint32_t name, | 486 uint32_t name, |
| (...skipping 2642 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3128 DCHECK(event_loop); | 3129 DCHECK(event_loop); |
| 3129 wl_event_loop_dispatch(event_loop, timeout.InMilliseconds()); | 3130 wl_event_loop_dispatch(event_loop, timeout.InMilliseconds()); |
| 3130 } | 3131 } |
| 3131 | 3132 |
| 3132 void Server::Flush() { | 3133 void Server::Flush() { |
| 3133 wl_display_flush_clients(wl_display_.get()); | 3134 wl_display_flush_clients(wl_display_.get()); |
| 3134 } | 3135 } |
| 3135 | 3136 |
| 3136 } // namespace wayland | 3137 } // namespace wayland |
| 3137 } // namespace exo | 3138 } // namespace exo |
| OLD | NEW |