| 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 #ifndef GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_UNITTEST_BASE_H_ | 5 #ifndef GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_UNITTEST_BASE_H_ |
| 6 #define GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_UNITTEST_BASE_H_ | 6 #define GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_UNITTEST_BASE_H_ |
| 7 | 7 |
| 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/buffer_manager.h" | 10 #include "gpu/command_buffer/service/buffer_manager.h" |
| (...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 319 | 319 |
| 320 void DoEnableDisable(GLenum cap, bool enable); | 320 void DoEnableDisable(GLenum cap, bool enable); |
| 321 | 321 |
| 322 void DoEnableVertexAttribArray(GLint index); | 322 void DoEnableVertexAttribArray(GLint index); |
| 323 | 323 |
| 324 void DoBufferData(GLenum target, GLsizei size); | 324 void DoBufferData(GLenum target, GLsizei size); |
| 325 | 325 |
| 326 void DoBufferSubData( | 326 void DoBufferSubData( |
| 327 GLenum target, GLint offset, GLsizei size, const void* data); | 327 GLenum target, GLint offset, GLsizei size, const void* data); |
| 328 | 328 |
| 329 void DoScissor(GLint x, GLint y, GLsizei width, GLsizei height); |
| 330 |
| 329 void SetupVertexBuffer(); | 331 void SetupVertexBuffer(); |
| 330 void SetupAllNeededVertexBuffers(); | 332 void SetupAllNeededVertexBuffers(); |
| 331 | 333 |
| 332 void SetupIndexBuffer(); | 334 void SetupIndexBuffer(); |
| 333 | 335 |
| 334 void DeleteVertexBuffer(); | 336 void DeleteVertexBuffer(); |
| 335 | 337 |
| 336 void DeleteIndexBuffer(); | 338 void DeleteIndexBuffer(); |
| 337 | 339 |
| 338 void SetupClearTextureExpectations(GLuint service_id, | 340 void SetupClearTextureExpectations(GLuint service_id, |
| 339 GLuint old_service_id, | 341 GLuint old_service_id, |
| 340 GLenum bind_target, | 342 GLenum bind_target, |
| 341 GLenum target, | 343 GLenum target, |
| 342 GLint level, | 344 GLint level, |
| 343 GLenum internal_format, | 345 GLenum internal_format, |
| 344 GLenum format, | 346 GLenum format, |
| 345 GLenum type, | 347 GLenum type, |
| 346 GLint xoffset, | 348 GLint xoffset, |
| 347 GLint yoffset, | 349 GLint yoffset, |
| 348 GLsizei width, | 350 GLsizei width, |
| 349 GLsizei height); | 351 GLsizei height); |
| 350 | 352 |
| 351 void SetupExpectationsForRestoreClearState( | 353 void SetupExpectationsForRestoreClearState(GLclampf restore_red, |
| 352 GLclampf restore_red, | 354 GLclampf restore_green, |
| 353 GLclampf restore_green, | 355 GLclampf restore_blue, |
| 354 GLclampf restore_blue, | 356 GLclampf restore_alpha, |
| 355 GLclampf restore_alpha, | 357 GLuint restore_stencil, |
| 356 GLuint restore_stencil, | 358 GLclampf restore_depth, |
| 357 GLclampf restore_depth, | 359 bool restore_scissor_test, |
| 358 bool restore_scissor_test); | 360 GLint restore_scissor_x, |
| 361 GLint restore_scissor_y, |
| 362 GLsizei restore_scissor_width, |
| 363 GLsizei restore_scissor_height); |
| 359 | 364 |
| 360 void SetupExpectationsForFramebufferClearing( | 365 void SetupExpectationsForFramebufferClearing(GLenum target, |
| 361 GLenum target, | 366 GLuint clear_bits, |
| 362 GLuint clear_bits, | 367 GLclampf restore_red, |
| 363 GLclampf restore_red, | 368 GLclampf restore_green, |
| 364 GLclampf restore_green, | 369 GLclampf restore_blue, |
| 365 GLclampf restore_blue, | 370 GLclampf restore_alpha, |
| 366 GLclampf restore_alpha, | 371 GLuint restore_stencil, |
| 367 GLuint restore_stencil, | 372 GLclampf restore_depth, |
| 368 GLclampf restore_depth, | 373 bool restore_scissor_test, |
| 369 bool restore_scissor_test); | 374 GLint restore_scissor_x, |
| 375 GLint restore_scissor_y, |
| 376 GLsizei restore_scissor_width, |
| 377 GLsizei restore_scissor_height); |
| 370 | 378 |
| 371 void SetupExpectationsForFramebufferClearingMulti( | 379 void SetupExpectationsForFramebufferClearingMulti( |
| 372 GLuint read_framebuffer_service_id, | 380 GLuint read_framebuffer_service_id, |
| 373 GLuint draw_framebuffer_service_id, | 381 GLuint draw_framebuffer_service_id, |
| 374 GLenum target, | 382 GLenum target, |
| 375 GLuint clear_bits, | 383 GLuint clear_bits, |
| 376 GLclampf restore_red, | 384 GLclampf restore_red, |
| 377 GLclampf restore_green, | 385 GLclampf restore_green, |
| 378 GLclampf restore_blue, | 386 GLclampf restore_blue, |
| 379 GLclampf restore_alpha, | 387 GLclampf restore_alpha, |
| 380 GLuint restore_stencil, | 388 GLuint restore_stencil, |
| 381 GLclampf restore_depth, | 389 GLclampf restore_depth, |
| 382 bool restore_scissor_test); | 390 bool restore_scissor_test, |
| 391 GLint restore_scissor_x, |
| 392 GLint restore_scissor_y, |
| 393 GLsizei restore_scissor_width, |
| 394 GLsizei restore_scissor_height); |
| 383 | 395 |
| 384 void SetupExpectationsForDepthMask(bool mask); | 396 void SetupExpectationsForDepthMask(bool mask); |
| 385 void SetupExpectationsForEnableDisable(GLenum cap, bool enable); | 397 void SetupExpectationsForEnableDisable(GLenum cap, bool enable); |
| 386 void SetupExpectationsForColorMask(bool red, | 398 void SetupExpectationsForColorMask(bool red, |
| 387 bool green, | 399 bool green, |
| 388 bool blue, | 400 bool blue, |
| 389 bool alpha); | 401 bool alpha); |
| 390 void SetupExpectationsForStencilMask(GLuint front_mask, GLuint back_mask); | 402 void SetupExpectationsForStencilMask(GLuint front_mask, GLuint back_mask); |
| 391 | 403 |
| 392 void SetupExpectationsForApplyingDirtyState( | 404 void SetupExpectationsForApplyingDirtyState( |
| (...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 683 }; | 695 }; |
| 684 | 696 |
| 685 // SpecializedSetup specializations that are needed in multiple unittest files. | 697 // SpecializedSetup specializations that are needed in multiple unittest files. |
| 686 template <> | 698 template <> |
| 687 void GLES2DecoderTestBase::SpecializedSetup<cmds::LinkProgram, 0>(bool valid); | 699 void GLES2DecoderTestBase::SpecializedSetup<cmds::LinkProgram, 0>(bool valid); |
| 688 | 700 |
| 689 } // namespace gles2 | 701 } // namespace gles2 |
| 690 } // namespace gpu | 702 } // namespace gpu |
| 691 | 703 |
| 692 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_UNITTEST_BASE_H_ | 704 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_UNITTEST_BASE_H_ |
| OLD | NEW |