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

Unified Diff: content/common/gpu/client/gl_helper_unittest.cc

Issue 149123008: Implement GLHelperReadbackSupport for GLHelper usage. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove unused gl_helper member. Created 6 years, 10 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 | « content/common/gpu/client/gl_helper_readback_support.cc ('k') | content/content_common.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/gpu/client/gl_helper_unittest.cc
diff --git a/content/common/gpu/client/gl_helper_unittest.cc b/content/common/gpu/client/gl_helper_unittest.cc
index aae1a02d14e7bf02ef2e6a434a81a74ef3823a89..028777bdca0c5e3d84dc72062feae4ad32aac18c 100644
--- a/content/common/gpu/client/gl_helper_unittest.cc
+++ b/content/common/gpu/client/gl_helper_unittest.cc
@@ -23,6 +23,7 @@
#include "base/synchronization/waitable_event.h"
#include "base/time/time.h"
#include "content/common/gpu/client/gl_helper.h"
+#include "content/common/gpu/client/gl_helper_readback_support.h"
#include "content/common/gpu/client/gl_helper_scaling.h"
#include "content/public/test/unittest_test_suite.h"
#include "content/test/content_test_suite.h"
@@ -1001,12 +1002,8 @@ class GLHelperTest : public testing::Test {
bool TestTextureFormatReadback(const gfx::Size& src_size,
SkBitmap::Config bitmap_config,
bool async) {
- DCHECK((bitmap_config == SkBitmap::kRGB_565_Config) ||
- (bitmap_config == SkBitmap::kARGB_8888_Config));
- bool rgb565_format = (bitmap_config == SkBitmap::kRGB_565_Config);
- if (rgb565_format && !helper_->CanUseRgb565Readback()) {
- LOG(INFO) << "RGB565 Format Not supported on this platform";
- LOG(INFO) << "Skipping RGB565ReadBackTest";
+ if (!helper_->IsReadbackConfigSupported(bitmap_config)) {
+ LOG(INFO) << "Skipping test format not supported" << bitmap_config;
return true;
}
WebGLId src_texture = context_->createTexture();
« no previous file with comments | « content/common/gpu/client/gl_helper_readback_support.cc ('k') | content/content_common.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698