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

Unified Diff: ui/gl/yuv_to_rgb_converter.h

Issue 2005463002: Attach YUV420 to RGB converter to GLContext (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2704
Patch Set: Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/gl/gl_image_io_surface.mm ('k') | ui/gl/yuv_to_rgb_converter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gl/yuv_to_rgb_converter.h
diff --git a/ui/gl/yuv_to_rgb_converter.h b/ui/gl/yuv_to_rgb_converter.h
new file mode 100644
index 0000000000000000000000000000000000000000..794b61511a61b8001428780c22a765e26bbacd51
--- /dev/null
+++ b/ui/gl/yuv_to_rgb_converter.h
@@ -0,0 +1,33 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef UI_GL_YUV420_RGB_CONVERTER_H_
+#define UI_GL_YUV420_RGB_CONVERTER_H_
+
+#include "ui/gfx/geometry/size.h"
+
+namespace gl {
+
+class YUVToRGBConverter {
+ public:
+ YUVToRGBConverter();
+ ~YUVToRGBConverter();
+ void CopyYUV420ToRGB(unsigned target,
+ unsigned y_texture,
+ unsigned uv_texture,
+ const gfx::Size& size,
+ unsigned rgb_texture);
+
+ private:
+ unsigned framebuffer_ = 0;
+ unsigned vertex_shader_ = 0;
+ unsigned fragment_shader_ = 0;
+ unsigned program_ = 0;
+ int size_location_ = -1;
+ unsigned vertex_buffer_ = 0;
+};
+
+} // namespace gl
+
+#endif // UI_GL_YUV420_RGB_CONVERTER_H_
« no previous file with comments | « ui/gl/gl_image_io_surface.mm ('k') | ui/gl/yuv_to_rgb_converter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698