| 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 <stddef.h> | 7 #include <stddef.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| (...skipping 1279 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1290 void GLES2DecoderTestBase::DoFramebufferRenderbuffer( | 1290 void GLES2DecoderTestBase::DoFramebufferRenderbuffer( |
| 1291 GLenum target, | 1291 GLenum target, |
| 1292 GLenum attachment, | 1292 GLenum attachment, |
| 1293 GLenum renderbuffer_target, | 1293 GLenum renderbuffer_target, |
| 1294 GLuint renderbuffer_client_id, | 1294 GLuint renderbuffer_client_id, |
| 1295 GLuint renderbuffer_service_id, | 1295 GLuint renderbuffer_service_id, |
| 1296 GLenum error) { | 1296 GLenum error) { |
| 1297 EXPECT_CALL(*gl_, GetError()) | 1297 EXPECT_CALL(*gl_, GetError()) |
| 1298 .WillOnce(Return(GL_NO_ERROR)) | 1298 .WillOnce(Return(GL_NO_ERROR)) |
| 1299 .RetiresOnSaturation(); | 1299 .RetiresOnSaturation(); |
| 1300 EXPECT_CALL(*gl_, FramebufferRenderbufferEXT( | 1300 if (attachment == GL_DEPTH_STENCIL_ATTACHMENT) { |
| 1301 target, attachment, renderbuffer_target, renderbuffer_service_id)) | 1301 EXPECT_CALL(*gl_, FramebufferRenderbufferEXT( |
| 1302 .Times(1) | 1302 target, GL_DEPTH_ATTACHMENT, renderbuffer_target, |
| 1303 .RetiresOnSaturation(); | 1303 renderbuffer_service_id)) |
| 1304 .Times(1) |
| 1305 .RetiresOnSaturation(); |
| 1306 EXPECT_CALL(*gl_, FramebufferRenderbufferEXT( |
| 1307 target, GL_STENCIL_ATTACHMENT, renderbuffer_target, |
| 1308 renderbuffer_service_id)) |
| 1309 .Times(1) |
| 1310 .RetiresOnSaturation(); |
| 1311 } else { |
| 1312 EXPECT_CALL(*gl_, FramebufferRenderbufferEXT( |
| 1313 target, attachment, renderbuffer_target, renderbuffer_service_id)) |
| 1314 .Times(1) |
| 1315 .RetiresOnSaturation(); |
| 1316 } |
| 1304 EXPECT_CALL(*gl_, GetError()) | 1317 EXPECT_CALL(*gl_, GetError()) |
| 1305 .WillOnce(Return(error)) | 1318 .WillOnce(Return(error)) |
| 1306 .RetiresOnSaturation(); | 1319 .RetiresOnSaturation(); |
| 1307 cmds::FramebufferRenderbuffer cmd; | 1320 cmds::FramebufferRenderbuffer cmd; |
| 1308 cmd.Init(target, attachment, renderbuffer_target, renderbuffer_client_id); | 1321 cmd.Init(target, attachment, renderbuffer_target, renderbuffer_client_id); |
| 1309 EXPECT_EQ(error::kNoError, ExecuteCmd(cmd)); | 1322 EXPECT_EQ(error::kNoError, ExecuteCmd(cmd)); |
| 1310 } | 1323 } |
| 1311 | 1324 |
| 1312 void GLES2DecoderTestBase::DoVertexAttribPointer( | 1325 void GLES2DecoderTestBase::DoVertexAttribPointer( |
| 1313 GLuint index, GLint size, GLenum type, GLsizei stride, GLuint offset) { | 1326 GLuint index, GLint size, GLenum type, GLsizei stride, GLuint offset) { |
| (...skipping 685 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1999 SetupDefaultProgram(); | 2012 SetupDefaultProgram(); |
| 2000 } | 2013 } |
| 2001 | 2014 |
| 2002 // Include the auto-generated part of this file. We split this because it means | 2015 // Include the auto-generated part of this file. We split this because it means |
| 2003 // we can easily edit the non-auto generated parts right here in this file | 2016 // we can easily edit the non-auto generated parts right here in this file |
| 2004 // instead of having to edit some template or the code generator. | 2017 // instead of having to edit some template or the code generator. |
| 2005 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_0_autogen.h" | 2018 #include "gpu/command_buffer/service/gles2_cmd_decoder_unittest_0_autogen.h" |
| 2006 | 2019 |
| 2007 } // namespace gles2 | 2020 } // namespace gles2 |
| 2008 } // namespace gpu | 2021 } // namespace gpu |
| OLD | NEW |