| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/gl/gl_image_native_pixmap.h" | 5 #include "ui/gl/gl_image_native_pixmap.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "ui/gfx/buffer_format_util.h" | 9 #include "ui/gfx/buffer_format_util.h" |
| 10 #include "ui/gl/gl_surface_egl.h" | 10 #include "ui/gl/gl_surface_egl.h" |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 60 case gfx::BufferFormat::BGRX_8888: | 60 case gfx::BufferFormat::BGRX_8888: |
| 61 case gfx::BufferFormat::YVU_420: | 61 case gfx::BufferFormat::YVU_420: |
| 62 case gfx::BufferFormat::YUV_420_BIPLANAR: | 62 case gfx::BufferFormat::YUV_420_BIPLANAR: |
| 63 return true; | 63 return true; |
| 64 case gfx::BufferFormat::ATC: | 64 case gfx::BufferFormat::ATC: |
| 65 case gfx::BufferFormat::ATCIA: | 65 case gfx::BufferFormat::ATCIA: |
| 66 case gfx::BufferFormat::DXT1: | 66 case gfx::BufferFormat::DXT1: |
| 67 case gfx::BufferFormat::DXT5: | 67 case gfx::BufferFormat::DXT5: |
| 68 case gfx::BufferFormat::ETC1: | 68 case gfx::BufferFormat::ETC1: |
| 69 case gfx::BufferFormat::RGBA_4444: | 69 case gfx::BufferFormat::RGBA_4444: |
| 70 case gfx::BufferFormat::RGBA_F16: |
| 70 case gfx::BufferFormat::UYVY_422: | 71 case gfx::BufferFormat::UYVY_422: |
| 71 return false; | 72 return false; |
| 72 } | 73 } |
| 73 | 74 |
| 74 NOTREACHED(); | 75 NOTREACHED(); |
| 75 return false; | 76 return false; |
| 76 } | 77 } |
| 77 | 78 |
| 78 EGLint FourCC(gfx::BufferFormat format) { | 79 EGLint FourCC(gfx::BufferFormat format) { |
| 79 switch (format) { | 80 switch (format) { |
| (...skipping 14 matching lines...) Expand all Loading... |
| 94 case gfx::BufferFormat::YVU_420: | 95 case gfx::BufferFormat::YVU_420: |
| 95 return DRM_FORMAT_YVU420; | 96 return DRM_FORMAT_YVU420; |
| 96 case gfx::BufferFormat::YUV_420_BIPLANAR: | 97 case gfx::BufferFormat::YUV_420_BIPLANAR: |
| 97 return DRM_FORMAT_NV12; | 98 return DRM_FORMAT_NV12; |
| 98 case gfx::BufferFormat::ATC: | 99 case gfx::BufferFormat::ATC: |
| 99 case gfx::BufferFormat::ATCIA: | 100 case gfx::BufferFormat::ATCIA: |
| 100 case gfx::BufferFormat::DXT1: | 101 case gfx::BufferFormat::DXT1: |
| 101 case gfx::BufferFormat::DXT5: | 102 case gfx::BufferFormat::DXT5: |
| 102 case gfx::BufferFormat::ETC1: | 103 case gfx::BufferFormat::ETC1: |
| 103 case gfx::BufferFormat::RGBA_4444: | 104 case gfx::BufferFormat::RGBA_4444: |
| 105 case gfx::BufferFormat::RGBA_F16: |
| 104 case gfx::BufferFormat::UYVY_422: | 106 case gfx::BufferFormat::UYVY_422: |
| 105 NOTREACHED(); | 107 NOTREACHED(); |
| 106 return 0; | 108 return 0; |
| 107 } | 109 } |
| 108 | 110 |
| 109 NOTREACHED(); | 111 NOTREACHED(); |
| 110 return 0; | 112 return 0; |
| 111 } | 113 } |
| 112 | 114 |
| 113 } // namespace | 115 } // namespace |
| (...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 261 case gfx::BufferFormat::YVU_420: | 263 case gfx::BufferFormat::YVU_420: |
| 262 return GL_RGB_YCRCB_420_CHROMIUM; | 264 return GL_RGB_YCRCB_420_CHROMIUM; |
| 263 case gfx::BufferFormat::YUV_420_BIPLANAR: | 265 case gfx::BufferFormat::YUV_420_BIPLANAR: |
| 264 return GL_RGB_YCBCR_420V_CHROMIUM; | 266 return GL_RGB_YCBCR_420V_CHROMIUM; |
| 265 case gfx::BufferFormat::ATC: | 267 case gfx::BufferFormat::ATC: |
| 266 case gfx::BufferFormat::ATCIA: | 268 case gfx::BufferFormat::ATCIA: |
| 267 case gfx::BufferFormat::DXT1: | 269 case gfx::BufferFormat::DXT1: |
| 268 case gfx::BufferFormat::DXT5: | 270 case gfx::BufferFormat::DXT5: |
| 269 case gfx::BufferFormat::ETC1: | 271 case gfx::BufferFormat::ETC1: |
| 270 case gfx::BufferFormat::RGBA_4444: | 272 case gfx::BufferFormat::RGBA_4444: |
| 273 case gfx::BufferFormat::RGBA_F16: |
| 271 case gfx::BufferFormat::UYVY_422: | 274 case gfx::BufferFormat::UYVY_422: |
| 272 NOTREACHED(); | 275 NOTREACHED(); |
| 273 return GL_NONE; | 276 return GL_NONE; |
| 274 } | 277 } |
| 275 | 278 |
| 276 NOTREACHED(); | 279 NOTREACHED(); |
| 277 return GL_NONE; | 280 return GL_NONE; |
| 278 } | 281 } |
| 279 | 282 |
| 280 } // namespace gl | 283 } // namespace gl |
| OLD | NEW |