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: gpu/command_buffer/service/feature_info.cc

Issue 1419733005: gpu: Add YCbCr 420v extension. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase on master. Add gl/gfx namespace qualifiers. Created 5 years, 1 month 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "gpu/command_buffer/service/feature_info.h" 5 #include "gpu/command_buffer/service/feature_info.h"
6 6
7 #include <set> 7 #include <set>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
164 map_buffer_range(false), 164 map_buffer_range(false),
165 ext_discard_framebuffer(false), 165 ext_discard_framebuffer(false),
166 angle_depth_texture(false), 166 angle_depth_texture(false),
167 is_swiftshader(false), 167 is_swiftshader(false),
168 angle_texture_usage(false), 168 angle_texture_usage(false),
169 ext_texture_storage(false), 169 ext_texture_storage(false),
170 chromium_path_rendering(false), 170 chromium_path_rendering(false),
171 blend_equation_advanced(false), 171 blend_equation_advanced(false),
172 blend_equation_advanced_coherent(false), 172 blend_equation_advanced_coherent(false),
173 ext_texture_rg(false), 173 ext_texture_rg(false),
174 chromium_image_ycbcr_420v(false),
174 chromium_image_ycbcr_422(false), 175 chromium_image_ycbcr_422(false),
175 enable_subscribe_uniform(false), 176 enable_subscribe_uniform(false),
176 emulate_primitive_restart_fixed_index(false), 177 emulate_primitive_restart_fixed_index(false),
177 ext_render_buffer_format_bgra8888(false) {} 178 ext_render_buffer_format_bgra8888(false) {}
178 179
179 FeatureInfo::Workarounds::Workarounds() : 180 FeatureInfo::Workarounds::Workarounds() :
180 #define GPU_OP(type, name) name(false), 181 #define GPU_OP(type, name) name(false),
181 GPU_DRIVER_BUG_WORKAROUNDS(GPU_OP) 182 GPU_DRIVER_BUG_WORKAROUNDS(GPU_OP)
182 #undef GPU_OP 183 #undef GPU_OP
183 max_texture_size(0), 184 max_texture_size(0),
(...skipping 652 matching lines...) Expand 10 before | Expand all | Expand 10 after
836 // textures via glFramebufferTexture2D, and copy destinations via 837 // textures via glFramebufferTexture2D, and copy destinations via
837 // glCopyPixels. 838 // glCopyPixels.
838 validators_.texture_bind_target.AddValue(GL_TEXTURE_RECTANGLE_ARB); 839 validators_.texture_bind_target.AddValue(GL_TEXTURE_RECTANGLE_ARB);
839 validators_.texture_target.AddValue(GL_TEXTURE_RECTANGLE_ARB); 840 validators_.texture_target.AddValue(GL_TEXTURE_RECTANGLE_ARB);
840 validators_.get_tex_param_target.AddValue(GL_TEXTURE_RECTANGLE_ARB); 841 validators_.get_tex_param_target.AddValue(GL_TEXTURE_RECTANGLE_ARB);
841 validators_.g_l_state.AddValue(GL_TEXTURE_BINDING_RECTANGLE_ARB); 842 validators_.g_l_state.AddValue(GL_TEXTURE_BINDING_RECTANGLE_ARB);
842 } 843 }
843 844
844 #if defined(OS_MACOSX) 845 #if defined(OS_MACOSX)
845 AddExtensionString("GL_CHROMIUM_iosurface"); 846 AddExtensionString("GL_CHROMIUM_iosurface");
847 AddExtensionString("GL_CHROMIUM_ycbcr_420v_image");
848 feature_flags_.chromium_image_ycbcr_420v = true;
846 #endif 849 #endif
847 850
848 if (extensions.Contains("GL_APPLE_ycbcr_422")) { 851 if (extensions.Contains("GL_APPLE_ycbcr_422")) {
849 AddExtensionString("GL_CHROMIUM_ycbcr_422_image"); 852 AddExtensionString("GL_CHROMIUM_ycbcr_422_image");
850 feature_flags_.chromium_image_ycbcr_422 = true; 853 feature_flags_.chromium_image_ycbcr_422 = true;
851 } 854 }
852 855
853 // TODO(gman): Add support for these extensions. 856 // TODO(gman): Add support for these extensions.
854 // GL_OES_depth32 857 // GL_OES_depth32
855 858
(...skipping 375 matching lines...) Expand 10 before | Expand all | Expand 10 after
1231 if (pos == std::string::npos) { 1234 if (pos == std::string::npos) {
1232 extensions_ += (extensions_.empty() ? "" : " ") + str; 1235 extensions_ += (extensions_.empty() ? "" : " ") + str;
1233 } 1236 }
1234 } 1237 }
1235 1238
1236 FeatureInfo::~FeatureInfo() { 1239 FeatureInfo::~FeatureInfo() {
1237 } 1240 }
1238 1241
1239 } // namespace gles2 1242 } // namespace gles2
1240 } // namespace gpu 1243 } // namespace gpu
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698