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

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

Issue 2275203002: Make command buffer commands and immediate data volatile (Closed)
Patch Set: std::copy->const_cast+memcpy Created 4 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_mock.h" 5 #include "gpu/command_buffer/service/gles2_cmd_decoder_mock.h"
6 6
7 #include "gpu/command_buffer/common/gles2_cmd_utils.h" 7 #include "gpu/command_buffer/common/gles2_cmd_utils.h"
8 8
9 namespace gpu { 9 namespace gpu {
10 namespace gles2 { 10 namespace gles2 {
11 11
12 MockGLES2Decoder::MockGLES2Decoder() 12 MockGLES2Decoder::MockGLES2Decoder()
13 : GLES2Decoder() { 13 : GLES2Decoder() {
14 ON_CALL(*this, GetCommandName(testing::_)) 14 ON_CALL(*this, GetCommandName(testing::_))
15 .WillByDefault(testing::Return("")); 15 .WillByDefault(testing::Return(""));
16 ON_CALL(*this, MakeCurrent()) 16 ON_CALL(*this, MakeCurrent())
17 .WillByDefault(testing::Return(true)); 17 .WillByDefault(testing::Return(true));
18 } 18 }
19 19
20 MockGLES2Decoder::~MockGLES2Decoder() {} 20 MockGLES2Decoder::~MockGLES2Decoder() {}
21 21
22 error::Error MockGLES2Decoder::FakeDoCommands(unsigned int num_commands, 22 error::Error MockGLES2Decoder::FakeDoCommands(unsigned int num_commands,
23 const void* buffer, 23 const volatile void* buffer,
24 int num_entries, 24 int num_entries,
25 int* entries_processed) { 25 int* entries_processed) {
26 return AsyncAPIInterface::DoCommands( 26 return AsyncAPIInterface::DoCommands(
27 num_commands, buffer, num_entries, entries_processed); 27 num_commands, buffer, num_entries, entries_processed);
28 } 28 }
29 29
30 } // namespace gles2 30 } // namespace gles2
31 } // namespace gpu 31 } // namespace gpu
OLDNEW
« no previous file with comments | « gpu/command_buffer/service/gles2_cmd_decoder_mock.h ('k') | gpu/command_buffer/service/gles2_cmd_decoder_passthrough.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698