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

Side by Side Diff: gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.h

Issue 1309743005: command_buffer: Implement EXT_blend_func_extended (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@new-05-path-fragment-input-gen
Patch Set: Created 5 years, 3 months 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 #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 538 matching lines...) Expand 10 before | Expand all | Expand 10 after
549 static const GLint kUniform2DesiredLocation = -1; 549 static const GLint kUniform2DesiredLocation = -1;
550 static const GLint kUniform3DesiredLocation = -1; 550 static const GLint kUniform3DesiredLocation = -1;
551 static const GLenum kUniform1Type = GL_SAMPLER_2D; 551 static const GLenum kUniform1Type = GL_SAMPLER_2D;
552 static const GLenum kUniform2Type = GL_INT_VEC2; 552 static const GLenum kUniform2Type = GL_INT_VEC2;
553 static const GLenum kUniform3Type = GL_FLOAT_VEC3; 553 static const GLenum kUniform3Type = GL_FLOAT_VEC3;
554 static const GLenum kUniformSamplerExternalType = GL_SAMPLER_EXTERNAL_OES; 554 static const GLenum kUniformSamplerExternalType = GL_SAMPLER_EXTERNAL_OES;
555 static const GLenum kUniformCubemapType = GL_SAMPLER_CUBE; 555 static const GLenum kUniformCubemapType = GL_SAMPLER_CUBE;
556 static const GLint kInvalidUniformLocation = 30; 556 static const GLint kInvalidUniformLocation = 30;
557 static const GLint kBadUniformIndex = 1000; 557 static const GLint kBadUniformIndex = 1000;
558 558
559 static const char* kOutputVariable1Name;
560 static const char* kOutputVariable1NameESSL3;
561
559 // Use StrictMock to make 100% sure we know how GL will be called. 562 // Use StrictMock to make 100% sure we know how GL will be called.
560 scoped_ptr< ::testing::StrictMock< ::gfx::MockGLInterface> > gl_; 563 scoped_ptr< ::testing::StrictMock< ::gfx::MockGLInterface> > gl_;
561 scoped_refptr<gfx::GLSurfaceStub> surface_; 564 scoped_refptr<gfx::GLSurfaceStub> surface_;
562 scoped_refptr<GLContextMock> context_; 565 scoped_refptr<GLContextMock> context_;
563 scoped_ptr<MockGLES2Decoder> mock_decoder_; 566 scoped_ptr<MockGLES2Decoder> mock_decoder_;
564 scoped_ptr<GLES2Decoder> decoder_; 567 scoped_ptr<GLES2Decoder> decoder_;
565 MemoryTracker* memory_tracker_; 568 MemoryTracker* memory_tracker_;
566 569
567 GLuint client_buffer_id_; 570 GLuint client_buffer_id_;
568 GLuint client_framebuffer_id_; 571 GLuint client_framebuffer_id_;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
607 bool cached_dither; 610 bool cached_dither;
608 bool cached_polygon_offset_fill; 611 bool cached_polygon_offset_fill;
609 bool cached_sample_alpha_to_coverage; 612 bool cached_sample_alpha_to_coverage;
610 bool cached_sample_coverage; 613 bool cached_sample_coverage;
611 bool cached_scissor_test; 614 bool cached_scissor_test;
612 bool cached_stencil_test; 615 bool cached_stencil_test;
613 }; 616 };
614 617
615 EnableFlags enable_flags_; 618 EnableFlags enable_flags_;
616 619
620 int shader_language_version_;
621
617 private: 622 private:
618 class MockCommandBufferEngine : public CommandBufferEngine { 623 class MockCommandBufferEngine : public CommandBufferEngine {
619 public: 624 public:
620 MockCommandBufferEngine(); 625 MockCommandBufferEngine();
621 626
622 ~MockCommandBufferEngine() override; 627 ~MockCommandBufferEngine() override;
623 628
624 scoped_refptr<gpu::Buffer> GetSharedMemoryBuffer(int32 shm_id) override; 629 scoped_refptr<gpu::Buffer> GetSharedMemoryBuffer(int32 shm_id) override;
625 630
626 void ClearSharedMemory() { 631 void ClearSharedMemory() {
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
697 }; 702 };
698 703
699 // SpecializedSetup specializations that are needed in multiple unittest files. 704 // SpecializedSetup specializations that are needed in multiple unittest files.
700 template <> 705 template <>
701 void GLES2DecoderTestBase::SpecializedSetup<cmds::LinkProgram, 0>(bool valid); 706 void GLES2DecoderTestBase::SpecializedSetup<cmds::LinkProgram, 0>(bool valid);
702 707
703 } // namespace gles2 708 } // namespace gles2
704 } // namespace gpu 709 } // namespace gpu
705 710
706 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_UNITTEST_BASE_H_ 711 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_UNITTEST_BASE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698