OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #ifndef UI_GL_GL_IMAGE_IO_SURFACE_H_ | 5 #ifndef UI_GL_GL_IMAGE_IO_SURFACE_H_ |
6 #define UI_GL_GL_IMAGE_IO_SURFACE_H_ | 6 #define UI_GL_GL_IMAGE_IO_SURFACE_H_ |
7 | 7 |
8 #include <IOSurface/IOSurface.h> | 8 #include <IOSurface/IOSurface.h> |
9 | 9 |
10 #include "base/mac/scoped_cftyperef.h" | 10 #include "base/mac/scoped_cftyperef.h" |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 ~GLImageIOSurface() override; | 57 ~GLImageIOSurface() override; |
58 | 58 |
59 private: | 59 private: |
60 const gfx::Size size_; | 60 const gfx::Size size_; |
61 const unsigned internalformat_; | 61 const unsigned internalformat_; |
62 gfx::BufferFormat format_; | 62 gfx::BufferFormat format_; |
63 base::ScopedCFTypeRef<IOSurfaceRef> io_surface_; | 63 base::ScopedCFTypeRef<IOSurfaceRef> io_surface_; |
64 gfx::GenericSharedMemoryId io_surface_id_; | 64 gfx::GenericSharedMemoryId io_surface_id_; |
65 base::ThreadChecker thread_checker_; | 65 base::ThreadChecker thread_checker_; |
66 | 66 |
| 67 // GL state to support 420v IOSurface conversion to RGB. |
| 68 unsigned framebuffer_ = 0; |
| 69 unsigned vertex_shader_ = 0; |
| 70 unsigned fragment_shader_ = 0; |
| 71 unsigned program_ = 0; |
| 72 int size_location_ = -1; |
| 73 unsigned vertex_buffer_ = 0; |
| 74 |
67 DISALLOW_COPY_AND_ASSIGN(GLImageIOSurface); | 75 DISALLOW_COPY_AND_ASSIGN(GLImageIOSurface); |
68 }; | 76 }; |
69 | 77 |
70 } // namespace gl | 78 } // namespace gl |
71 | 79 |
72 #endif // UI_GL_GL_IMAGE_IO_SURFACE_H_ | 80 #endif // UI_GL_GL_IMAGE_IO_SURFACE_H_ |
OLD | NEW |