OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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.h" | 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "gpu/command_buffer/common/gles2_cmd_format.h" | 8 #include "gpu/command_buffer/common/gles2_cmd_format.h" |
9 #include "gpu/command_buffer/common/gles2_cmd_utils.h" | 9 #include "gpu/command_buffer/common/gles2_cmd_utils.h" |
10 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest.h" | 10 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest.h" |
(...skipping 502 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
513 init.request_depth = true; | 513 init.request_depth = true; |
514 init.bind_generates_resource = true; | 514 init.bind_generates_resource = true; |
515 init.extensions = "GL_EXT_multisample_compatibility "; | 515 init.extensions = "GL_EXT_multisample_compatibility "; |
516 InitDecoder(init); | 516 InitDecoder(init); |
517 } | 517 } |
518 }; | 518 }; |
519 INSTANTIATE_TEST_CASE_P(Service, | 519 INSTANTIATE_TEST_CASE_P(Service, |
520 GLES2DecoderTestWithEXTMultisampleCompatibility, | 520 GLES2DecoderTestWithEXTMultisampleCompatibility, |
521 ::testing::Bool()); | 521 ::testing::Bool()); |
522 | 522 |
| 523 class GLES2DecoderTestWithBlendFuncExtended : public GLES2DecoderTest { |
| 524 public: |
| 525 GLES2DecoderTestWithBlendFuncExtended() {} |
| 526 void SetUp() override { |
| 527 InitState init; |
| 528 init.gl_version = "opengl es 3.0"; |
| 529 init.has_alpha = true; |
| 530 init.has_depth = true; |
| 531 init.request_alpha = true; |
| 532 init.request_depth = true; |
| 533 init.bind_generates_resource = true; |
| 534 init.extensions = "GL_EXT_blend_func_extended"; |
| 535 InitDecoder(init); |
| 536 } |
| 537 }; |
| 538 INSTANTIATE_TEST_CASE_P(Service, |
| 539 GLES2DecoderTestWithBlendFuncExtended, |
| 540 ::testing::Bool()); |
| 541 |
| 542 |
523 TEST_P(GLES2DecoderTestWithCHROMIUMPathRendering, GenDeletePaths) { | 543 TEST_P(GLES2DecoderTestWithCHROMIUMPathRendering, GenDeletePaths) { |
524 static GLuint kFirstClientID = client_path_id_ + 88; | 544 static GLuint kFirstClientID = client_path_id_ + 88; |
525 static GLsizei kPathCount = 58; | 545 static GLsizei kPathCount = 58; |
526 static GLuint kFirstCreatedServiceID = 8000; | 546 static GLuint kFirstCreatedServiceID = 8000; |
527 | 547 |
528 // GenPaths range 0 causes no calls. | 548 // GenPaths range 0 causes no calls. |
529 cmds::GenPathsCHROMIUM gen_cmd; | 549 cmds::GenPathsCHROMIUM gen_cmd; |
530 gen_cmd.Init(kFirstClientID, 0); | 550 gen_cmd.Init(kFirstClientID, 0); |
531 EXPECT_EQ(error::kNoError, ExecuteCmd(gen_cmd)); | 551 EXPECT_EQ(error::kNoError, ExecuteCmd(gen_cmd)); |
532 EXPECT_EQ(GL_NO_ERROR, GetGLError()); | 552 EXPECT_EQ(GL_NO_ERROR, GetGLError()); |
(...skipping 1146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1679 SetBucketAsCString(kBucketId, kBadName1); | 1699 SetBucketAsCString(kBucketId, kBadName1); |
1680 cmd.Init(client_program_id_, kLocation, kBucketId); | 1700 cmd.Init(client_program_id_, kLocation, kBucketId); |
1681 EXPECT_EQ(error::kNoError, ExecuteCmd(cmd)); | 1701 EXPECT_EQ(error::kNoError, ExecuteCmd(cmd)); |
1682 EXPECT_EQ(GL_INVALID_OPERATION, GetGLError()); | 1702 EXPECT_EQ(GL_INVALID_OPERATION, GetGLError()); |
1683 } | 1703 } |
1684 | 1704 |
1685 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_extensions_autog
en.h" | 1705 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_extensions_autog
en.h" |
1686 | 1706 |
1687 } // namespace gles2 | 1707 } // namespace gles2 |
1688 } // namespace gpu | 1708 } // namespace gpu |
OLD | NEW |