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

Side by Side Diff: gpu/command_buffer/service/gles2_cmd_decoder_unittest_textures.cc

Issue 1140683002: glBindTexImage2DCHROMIUM should retain pixel format. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add GetInternalFormat override to MockGLImage. Created 5 years, 7 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 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 "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "gpu/command_buffer/common/gles2_cmd_format.h" 9 #include "gpu/command_buffer/common/gles2_cmd_format.h"
10 #include "gpu/command_buffer/common/gles2_cmd_utils.h" 10 #include "gpu/command_buffer/common/gles2_cmd_utils.h"
(...skipping 2724 matching lines...) Expand 10 before | Expand all | Expand 10 after
2735 // Image should no longer be set. 2735 // Image should no longer be set.
2736 EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == NULL); 2736 EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == NULL);
2737 } 2737 }
2738 2738
2739 class MockGLImage : public gfx::GLImage { 2739 class MockGLImage : public gfx::GLImage {
2740 public: 2740 public:
2741 MockGLImage() {} 2741 MockGLImage() {}
2742 2742
2743 // Overridden from gfx::GLImage: 2743 // Overridden from gfx::GLImage:
2744 MOCK_METHOD0(GetSize, gfx::Size()); 2744 MOCK_METHOD0(GetSize, gfx::Size());
2745 MOCK_METHOD0(GetInternalFormat, unsigned());
2745 MOCK_METHOD1(Destroy, void(bool)); 2746 MOCK_METHOD1(Destroy, void(bool));
2746 MOCK_METHOD1(BindTexImage, bool(unsigned)); 2747 MOCK_METHOD1(BindTexImage, bool(unsigned));
2747 MOCK_METHOD1(ReleaseTexImage, void(unsigned)); 2748 MOCK_METHOD1(ReleaseTexImage, void(unsigned));
2748 MOCK_METHOD1(CopyTexImage, bool(unsigned)); 2749 MOCK_METHOD1(CopyTexImage, bool(unsigned));
2749 MOCK_METHOD0(WillUseTexImage, void()); 2750 MOCK_METHOD0(WillUseTexImage, void());
2750 MOCK_METHOD0(DidUseTexImage, void()); 2751 MOCK_METHOD0(DidUseTexImage, void());
2751 MOCK_METHOD0(WillModifyTexImage, void()); 2752 MOCK_METHOD0(WillModifyTexImage, void());
2752 MOCK_METHOD0(DidModifyTexImage, void()); 2753 MOCK_METHOD0(DidModifyTexImage, void());
2753 MOCK_METHOD5(ScheduleOverlayPlane, bool(gfx::AcceleratedWidget, 2754 MOCK_METHOD5(ScheduleOverlayPlane, bool(gfx::AcceleratedWidget,
2754 int, 2755 int,
(...skipping 535 matching lines...) Expand 10 before | Expand all | Expand 10 after
3290 // TODO(gman): CompressedTexSubImage2DImmediate 3291 // TODO(gman): CompressedTexSubImage2DImmediate
3291 3292
3292 // TODO(gman): TexImage2D 3293 // TODO(gman): TexImage2D
3293 3294
3294 // TODO(gman): TexImage2DImmediate 3295 // TODO(gman): TexImage2DImmediate
3295 3296
3296 // TODO(gman): TexSubImage2DImmediate 3297 // TODO(gman): TexSubImage2DImmediate
3297 3298
3298 } // namespace gles2 3299 } // namespace gles2
3299 } // namespace gpu 3300 } // namespace gpu
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698