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

Unified Diff: third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTestHelpers.h

Issue 2812963003: Add DrawingBuffer multisample resolve unit test. (Closed)
Patch Set: Use enum. Created 3 years, 8 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 | « third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTest.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTestHelpers.h
diff --git a/third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTestHelpers.h b/third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTestHelpers.h
index fa44cfccaca1811d20865b92626bef5b463fc119..7cc062f1d390edbafa043843c2237d991cf4b5d1 100644
--- a/third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTestHelpers.h
+++ b/third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTestHelpers.h
@@ -18,21 +18,27 @@ enum {
kAlternateHeight = 50,
};
+enum UseMultisampling {
+ kDisableMultisampling,
+ kEnableMultisampling,
+};
+
class DrawingBufferForTests : public DrawingBuffer {
public:
static PassRefPtr<DrawingBufferForTests> Create(
std::unique_ptr<WebGraphicsContext3DProvider> context_provider,
DrawingBuffer::Client* client,
const IntSize& size,
- PreserveDrawingBuffer preserve) {
+ PreserveDrawingBuffer preserve,
+ UseMultisampling use_multisampling) {
std::unique_ptr<Extensions3DUtil> extensions_util =
Extensions3DUtil::Create(context_provider->ContextGL());
RefPtr<DrawingBufferForTests> drawing_buffer =
AdoptRef(new DrawingBufferForTests(std::move(context_provider),
std::move(extensions_util), client,
preserve));
- bool multisample_extension_supported = false;
- if (!drawing_buffer->Initialize(size, multisample_extension_supported)) {
+ if (!drawing_buffer->Initialize(
+ size, use_multisampling != kDisableMultisampling)) {
drawing_buffer->BeginDestruction();
return nullptr;
}
« no previous file with comments | « third_party/WebKit/Source/platform/graphics/gpu/DrawingBufferTest.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698