| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "ui/ozone/platform/drm/common/drm_util.h" | 5 #include "ui/ozone/platform/drm/common/drm_util.h" |
| 6 | 6 |
| 7 #include <drm_fourcc.h> | 7 #include <drm_fourcc.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 #include <stdlib.h> | 9 #include <stdlib.h> |
| 10 #include <sys/mman.h> | 10 #include <sys/mman.h> |
| (...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 320 case gfx::BufferFormat::RGBX_8888: | 320 case gfx::BufferFormat::RGBX_8888: |
| 321 return DRM_FORMAT_XBGR8888; | 321 return DRM_FORMAT_XBGR8888; |
| 322 case gfx::BufferFormat::BGRA_8888: | 322 case gfx::BufferFormat::BGRA_8888: |
| 323 return DRM_FORMAT_ARGB8888; | 323 return DRM_FORMAT_ARGB8888; |
| 324 case gfx::BufferFormat::BGRX_8888: | 324 case gfx::BufferFormat::BGRX_8888: |
| 325 return DRM_FORMAT_XRGB8888; | 325 return DRM_FORMAT_XRGB8888; |
| 326 case gfx::BufferFormat::BGR_565: | 326 case gfx::BufferFormat::BGR_565: |
| 327 return DRM_FORMAT_RGB565; | 327 return DRM_FORMAT_RGB565; |
| 328 case gfx::BufferFormat::UYVY_422: | 328 case gfx::BufferFormat::UYVY_422: |
| 329 return DRM_FORMAT_UYVY; | 329 return DRM_FORMAT_UYVY; |
| 330 case gfx::BufferFormat::YUYV_422: |
| 331 return DRM_FORMAT_YUYV; |
| 330 case gfx::BufferFormat::YVU_420: | 332 case gfx::BufferFormat::YVU_420: |
| 331 return DRM_FORMAT_YV12; | 333 return DRM_FORMAT_YV12; |
| 332 case gfx::BufferFormat::YUV_420_BIPLANAR: | 334 case gfx::BufferFormat::YUV_420_BIPLANAR: |
| 333 return DRM_FORMAT_NV12; | 335 return DRM_FORMAT_NV12; |
| 334 default: | 336 default: |
| 335 NOTREACHED(); | 337 NOTREACHED(); |
| 336 return 0; | 338 return 0; |
| 337 } | 339 } |
| 338 } | 340 } |
| 339 | 341 |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 371 case gfx::BufferFormat::RGBA_8888: | 373 case gfx::BufferFormat::RGBA_8888: |
| 372 case gfx::BufferFormat::RGBX_8888: | 374 case gfx::BufferFormat::RGBX_8888: |
| 373 return DRM_FORMAT_XBGR8888; | 375 return DRM_FORMAT_XBGR8888; |
| 374 case gfx::BufferFormat::BGRA_8888: | 376 case gfx::BufferFormat::BGRA_8888: |
| 375 case gfx::BufferFormat::BGRX_8888: | 377 case gfx::BufferFormat::BGRX_8888: |
| 376 return DRM_FORMAT_XRGB8888; | 378 return DRM_FORMAT_XRGB8888; |
| 377 case gfx::BufferFormat::BGR_565: | 379 case gfx::BufferFormat::BGR_565: |
| 378 return DRM_FORMAT_RGB565; | 380 return DRM_FORMAT_RGB565; |
| 379 case gfx::BufferFormat::UYVY_422: | 381 case gfx::BufferFormat::UYVY_422: |
| 380 return DRM_FORMAT_UYVY; | 382 return DRM_FORMAT_UYVY; |
| 383 case gfx::BufferFormat::YUYV_422: |
| 384 return DRM_FORMAT_YUYV; |
| 381 default: | 385 default: |
| 382 NOTREACHED(); | 386 NOTREACHED(); |
| 383 return 0; | 387 return 0; |
| 384 } | 388 } |
| 385 } | 389 } |
| 386 } // namespace ui | 390 } // namespace ui |
| OLD | NEW |