| 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 253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 | 264 |
| 265 return params; | 265 return params; |
| 266 } | 266 } |
| 267 | 267 |
| 268 int GetFourCCFormatFromBufferFormat(gfx::BufferFormat format) { | 268 int GetFourCCFormatFromBufferFormat(gfx::BufferFormat format) { |
| 269 switch (format) { | 269 switch (format) { |
| 270 case gfx::BufferFormat::BGRA_8888: | 270 case gfx::BufferFormat::BGRA_8888: |
| 271 return DRM_FORMAT_ARGB8888; | 271 return DRM_FORMAT_ARGB8888; |
| 272 case gfx::BufferFormat::BGRX_8888: | 272 case gfx::BufferFormat::BGRX_8888: |
| 273 return DRM_FORMAT_XRGB8888; | 273 return DRM_FORMAT_XRGB8888; |
| 274 case gfx::BufferFormat::UYVY_422: |
| 275 return DRM_FORMAT_UYVY; |
| 274 default: | 276 default: |
| 275 NOTREACHED(); | 277 NOTREACHED(); |
| 276 return 0; | 278 return 0; |
| 277 } | 279 } |
| 278 } | 280 } |
| 279 | 281 |
| 280 } // namespace ui | 282 } // namespace ui |
| OLD | NEW |