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

Side by Side Diff: gpu/command_buffer/service/framebuffer_manager_unittest.cc

Issue 2444813002: Remove unsafe mode to enable es3 api by default for WebGL2 and ES3 context (Closed)
Patch Set: remove runtime flag unsafeES3APIs from blink webgl module Created 4 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 <stddef.h> 5 #include <stddef.h>
6 #include <stdint.h> 6 #include <stdint.h>
7 7
8 #include "gpu/command_buffer/service/error_state_mock.h" 8 #include "gpu/command_buffer/service/error_state_mock.h"
9 #include "gpu/command_buffer/service/feature_info.h" 9 #include "gpu/command_buffer/service/feature_info.h"
10 #include "gpu/command_buffer/service/framebuffer_manager.h" 10 #include "gpu/command_buffer/service/framebuffer_manager.h"
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 public: 111 public:
112 static const GLuint kClient1Id = 1; 112 static const GLuint kClient1Id = 1;
113 static const GLuint kService1Id = 11; 113 static const GLuint kService1Id = 11;
114 114
115 explicit FramebufferInfoTestBase(ContextType context_type) 115 explicit FramebufferInfoTestBase(ContextType context_type)
116 : context_type_(context_type), 116 : context_type_(context_type),
117 manager_(kMaxDrawBuffers, 117 manager_(kMaxDrawBuffers,
118 kMaxColorAttachments, 118 kMaxColorAttachments,
119 new FramebufferCompletenessCache), 119 new FramebufferCompletenessCache),
120 feature_info_(new FeatureInfo()) { 120 feature_info_(new FeatureInfo()) {
121 feature_info_->SetES3APIsSwitch(false);
121 texture_manager_.reset(new TextureManager( 122 texture_manager_.reset(new TextureManager(
122 nullptr, feature_info_.get(), kMaxTextureSize, kMaxCubemapSize, 123 nullptr, feature_info_.get(), kMaxTextureSize, kMaxCubemapSize,
123 kMaxRectangleTextureSize, kMax3DTextureSize, kMaxArrayTextureLayers, 124 kMaxRectangleTextureSize, kMax3DTextureSize, kMaxArrayTextureLayers,
124 kUseDefaultTextures, nullptr)); 125 kUseDefaultTextures, nullptr));
125 renderbuffer_manager_.reset(new RenderbufferManager(nullptr, 126 renderbuffer_manager_.reset(new RenderbufferManager(nullptr,
126 kMaxRenderbufferSize, 127 kMaxRenderbufferSize,
127 kMaxSamples, 128 kMaxSamples,
128 feature_info_.get())); 129 feature_info_.get()));
129 } 130 }
130 ~FramebufferInfoTestBase() override { 131 ~FramebufferInfoTestBase() override {
(...skipping 1521 matching lines...) Expand 10 before | Expand all | Expand 10 after
1652 renderbuffer_manager_->GetRenderbuffer(kRenderbufferClientId); 1653 renderbuffer_manager_->GetRenderbuffer(kRenderbufferClientId);
1653 ASSERT_TRUE(renderbuffer != nullptr); 1654 ASSERT_TRUE(renderbuffer != nullptr);
1654 framebuffer_->AttachRenderbuffer(GL_COLOR_ATTACHMENT1, renderbuffer); 1655 framebuffer_->AttachRenderbuffer(GL_COLOR_ATTACHMENT1, renderbuffer);
1655 EXPECT_TRUE(framebuffer_->GetReadBufferAttachment()); 1656 EXPECT_TRUE(framebuffer_->GetReadBufferAttachment());
1656 } 1657 }
1657 1658
1658 } // namespace gles2 1659 } // namespace gles2
1659 } // namespace gpu 1660 } // namespace gpu
1660 1661
1661 1662
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698