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/gles2_cmd_decoder_unittest_base.h" | 5 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/string_number_conversions.h" | 10 #include "base/string_number_conversions.h" |
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
334 int32 attributes[] = { | 334 int32 attributes[] = { |
335 EGL_ALPHA_SIZE, request_alpha ? 8 : 0, | 335 EGL_ALPHA_SIZE, request_alpha ? 8 : 0, |
336 EGL_DEPTH_SIZE, request_depth ? 24 : 0, | 336 EGL_DEPTH_SIZE, request_depth ? 24 : 0, |
337 EGL_STENCIL_SIZE, request_stencil ? 8 : 0, | 337 EGL_STENCIL_SIZE, request_stencil ? 8 : 0, |
338 }; | 338 }; |
339 std::vector<int32> attribs(attributes, attributes + arraysize(attributes)); | 339 std::vector<int32> attribs(attributes, attributes + arraysize(attributes)); |
340 | 340 |
341 decoder_.reset(GLES2Decoder::Create(group_.get())); | 341 decoder_.reset(GLES2Decoder::Create(group_.get())); |
342 decoder_->set_log_synthesized_gl_errors(false); | 342 decoder_->set_log_synthesized_gl_errors(false); |
343 decoder_->Initialize( | 343 decoder_->Initialize( |
344 surface_, context_, surface_->GetSize(), DisallowedFeatures(), | 344 surface_, context_, false, surface_->GetSize(), DisallowedFeatures(), |
345 NULL, attribs); | 345 NULL, attribs); |
346 decoder_->set_engine(engine_.get()); | 346 decoder_->set_engine(engine_.get()); |
347 | 347 |
348 EXPECT_CALL(*gl_, GenBuffersARB(_, _)) | 348 EXPECT_CALL(*gl_, GenBuffersARB(_, _)) |
349 .WillOnce(SetArgumentPointee<1>(kServiceBufferId)) | 349 .WillOnce(SetArgumentPointee<1>(kServiceBufferId)) |
350 .RetiresOnSaturation(); | 350 .RetiresOnSaturation(); |
351 GenHelper<GenBuffersImmediate>(client_buffer_id_); | 351 GenHelper<GenBuffersImmediate>(client_buffer_id_); |
352 EXPECT_CALL(*gl_, GenFramebuffersEXT(_, _)) | 352 EXPECT_CALL(*gl_, GenFramebuffersEXT(_, _)) |
353 .WillOnce(SetArgumentPointee<1>(kServiceFramebufferId)) | 353 .WillOnce(SetArgumentPointee<1>(kServiceFramebufferId)) |
354 .RetiresOnSaturation(); | 354 .RetiresOnSaturation(); |
(...skipping 1029 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1384 num_vertices, buffer_id, GL_NO_ERROR); | 1384 num_vertices, buffer_id, GL_NO_ERROR); |
1385 } | 1385 } |
1386 | 1386 |
1387 void GLES2DecoderWithShaderTestBase::SetUp() { | 1387 void GLES2DecoderWithShaderTestBase::SetUp() { |
1388 GLES2DecoderTestBase::SetUp(); | 1388 GLES2DecoderTestBase::SetUp(); |
1389 SetupDefaultProgram(); | 1389 SetupDefaultProgram(); |
1390 } | 1390 } |
1391 | 1391 |
1392 } // namespace gles2 | 1392 } // namespace gles2 |
1393 } // namespace gpu | 1393 } // namespace gpu |
OLD | NEW |