OLD | NEW |
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 <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <set> | 9 #include <set> |
10 #include <vector> | 10 #include <vector> |
(...skipping 907 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
918 feature_flags_.chromium_image_ycbcr_422 = true; | 918 feature_flags_.chromium_image_ycbcr_422 = true; |
919 } | 919 } |
920 | 920 |
921 // TODO(gman): Add support for these extensions. | 921 // TODO(gman): Add support for these extensions. |
922 // GL_OES_depth32 | 922 // GL_OES_depth32 |
923 | 923 |
924 feature_flags_.enable_texture_float_linear |= enable_texture_float_linear; | 924 feature_flags_.enable_texture_float_linear |= enable_texture_float_linear; |
925 feature_flags_.enable_texture_half_float_linear |= | 925 feature_flags_.enable_texture_half_float_linear |= |
926 enable_texture_half_float_linear; | 926 enable_texture_half_float_linear; |
927 | 927 |
928 if (extensions.Contains("GL_ANGLE_pack_reverse_row_order")) { | |
929 AddExtensionString("GL_ANGLE_pack_reverse_row_order"); | |
930 feature_flags_.angle_pack_reverse_row_order = true; | |
931 validators_.pixel_store.AddValue(GL_PACK_REVERSE_ROW_ORDER_ANGLE); | |
932 validators_.g_l_state.AddValue(GL_PACK_REVERSE_ROW_ORDER_ANGLE); | |
933 } | |
934 | |
935 if (extensions.Contains("GL_ANGLE_texture_usage")) { | 928 if (extensions.Contains("GL_ANGLE_texture_usage")) { |
936 feature_flags_.angle_texture_usage = true; | 929 feature_flags_.angle_texture_usage = true; |
937 AddExtensionString("GL_ANGLE_texture_usage"); | 930 AddExtensionString("GL_ANGLE_texture_usage"); |
938 validators_.texture_parameter.AddValue(GL_TEXTURE_USAGE_ANGLE); | 931 validators_.texture_parameter.AddValue(GL_TEXTURE_USAGE_ANGLE); |
939 } | 932 } |
940 | 933 |
941 // Note: Only APPLE_texture_format_BGRA8888 extension allows BGRA8_EXT in | 934 // Note: Only APPLE_texture_format_BGRA8888 extension allows BGRA8_EXT in |
942 // ES3's glTexStorage2D. We prefer support BGRA to texture storage. | 935 // ES3's glTexStorage2D. We prefer support BGRA to texture storage. |
943 // So we don't expose GL_EXT_texture_storage when ES3 + | 936 // So we don't expose GL_EXT_texture_storage when ES3 + |
944 // GL_EXT_texture_format_BGRA8888 because we fail the GL_BGRA8 requirement. | 937 // GL_EXT_texture_format_BGRA8888 because we fail the GL_BGRA8 requirement. |
(...skipping 398 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1343 if (pos == std::string::npos) { | 1336 if (pos == std::string::npos) { |
1344 extensions_ += (extensions_.empty() ? "" : " ") + str; | 1337 extensions_ += (extensions_.empty() ? "" : " ") + str; |
1345 } | 1338 } |
1346 } | 1339 } |
1347 | 1340 |
1348 FeatureInfo::~FeatureInfo() { | 1341 FeatureInfo::~FeatureInfo() { |
1349 } | 1342 } |
1350 | 1343 |
1351 } // namespace gles2 | 1344 } // namespace gles2 |
1352 } // namespace gpu | 1345 } // namespace gpu |
OLD | NEW |