Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(578)

Side by Side Diff: ui/gfx/mac/io_surface.cc

Issue 2684993005: (NotForReview) Enable YUV video overlay on Skylake ChromeOS.
Patch Set: rebase to ToT (Mar/27) Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ui/gfx/linux/client_native_pixmap_factory_dmabuf.cc ('k') | ui/gfx/mojo/buffer_types.mojom » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "ui/gfx/mac/io_surface.h" 5 #include "ui/gfx/mac/io_surface.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 return 2; 47 return 2;
48 case gfx::BufferFormat::ATC: 48 case gfx::BufferFormat::ATC:
49 case gfx::BufferFormat::ATCIA: 49 case gfx::BufferFormat::ATCIA:
50 case gfx::BufferFormat::DXT1: 50 case gfx::BufferFormat::DXT1:
51 case gfx::BufferFormat::DXT5: 51 case gfx::BufferFormat::DXT5:
52 case gfx::BufferFormat::ETC1: 52 case gfx::BufferFormat::ETC1:
53 case gfx::BufferFormat::BGR_565: 53 case gfx::BufferFormat::BGR_565:
54 case gfx::BufferFormat::RGBA_4444: 54 case gfx::BufferFormat::RGBA_4444:
55 case gfx::BufferFormat::RGBX_8888: 55 case gfx::BufferFormat::RGBX_8888:
56 case gfx::BufferFormat::YVU_420: 56 case gfx::BufferFormat::YVU_420:
57 case gfx::BufferFormat::YUYV_422:
57 NOTREACHED(); 58 NOTREACHED();
58 return 0; 59 return 0;
59 } 60 }
60 61
61 NOTREACHED(); 62 NOTREACHED();
62 return 0; 63 return 0;
63 } 64 }
64 65
65 int32_t PixelFormat(gfx::BufferFormat format) { 66 int32_t PixelFormat(gfx::BufferFormat format) {
66 switch (format) { 67 switch (format) {
(...skipping 10 matching lines...) Expand all
77 case gfx::BufferFormat::RG_88: 78 case gfx::BufferFormat::RG_88:
78 case gfx::BufferFormat::ATC: 79 case gfx::BufferFormat::ATC:
79 case gfx::BufferFormat::ATCIA: 80 case gfx::BufferFormat::ATCIA:
80 case gfx::BufferFormat::DXT1: 81 case gfx::BufferFormat::DXT1:
81 case gfx::BufferFormat::DXT5: 82 case gfx::BufferFormat::DXT5:
82 case gfx::BufferFormat::ETC1: 83 case gfx::BufferFormat::ETC1:
83 case gfx::BufferFormat::BGR_565: 84 case gfx::BufferFormat::BGR_565:
84 case gfx::BufferFormat::RGBA_4444: 85 case gfx::BufferFormat::RGBA_4444:
85 case gfx::BufferFormat::RGBX_8888: 86 case gfx::BufferFormat::RGBX_8888:
86 case gfx::BufferFormat::YVU_420: 87 case gfx::BufferFormat::YVU_420:
88 case gfx::BufferFormat::YUYV_422:
87 NOTREACHED(); 89 NOTREACHED();
88 return 0; 90 return 0;
89 } 91 }
90 92
91 NOTREACHED(); 93 NOTREACHED();
92 return 0; 94 return 0;
93 } 95 }
94 96
95 } // namespace 97 } // namespace
96 98
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 // Note that nullptr is an acceptable input to IOSurfaceSetValue. 206 // Note that nullptr is an acceptable input to IOSurfaceSetValue.
205 IOSurfaceSetValue(surface, CFSTR("IOSurfaceColorSpace"), color_space_icc); 207 IOSurfaceSetValue(surface, CFSTR("IOSurfaceColorSpace"), color_space_icc);
206 } 208 }
207 209
208 UMA_HISTOGRAM_TIMES("GPU.IOSurface.CreateTime", 210 UMA_HISTOGRAM_TIMES("GPU.IOSurface.CreateTime",
209 base::TimeTicks::Now() - start_time); 211 base::TimeTicks::Now() - start_time);
210 return surface; 212 return surface;
211 } 213 }
212 214
213 } // namespace gfx 215 } // namespace gfx
OLDNEW
« no previous file with comments | « ui/gfx/linux/client_native_pixmap_factory_dmabuf.cc ('k') | ui/gfx/mojo/buffer_types.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698