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

Side by Side Diff: gpu/command_buffer/common/cmd_buffer_common.cc

Issue 558035: [GPU] Get GPU process running on the mac... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 10 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 // This file contains the binary format definition of the command buffer and 5 // This file contains the binary format definition of the command buffer and
6 // command buffer commands. 6 // command buffer commands.
7 7
8 #include "gpu/command_buffer/common/cmd_buffer_common.h" 8 #include "gpu/command_buffer/common/cmd_buffer_common.h"
9 9
10 namespace gpu { 10 namespace gpu {
11 const int32 CommandHeader::kMaxSize = (1 << 21) - 1; 11 #if !defined(OS_WIN)
12 12 // gcc needs this to link, but MSVC requires it not be present
13 const int32 CommandHeader::kMaxSize;
14 #endif
13 namespace cmd { 15 namespace cmd {
14 16
15 const char* GetCommandName(CommandId command_id) { 17 const char* GetCommandName(CommandId command_id) {
16 static const char* const names[] = { 18 static const char* const names[] = {
17 #define COMMON_COMMAND_BUFFER_CMD_OP(name) # name, 19 #define COMMON_COMMAND_BUFFER_CMD_OP(name) # name,
18 20
19 COMMON_COMMAND_BUFFER_CMDS(COMMON_COMMAND_BUFFER_CMD_OP) 21 COMMON_COMMAND_BUFFER_CMDS(COMMON_COMMAND_BUFFER_CMD_OP)
20 22
21 #undef COMMON_COMMAND_BUFFER_CMD_OP 23 #undef COMMON_COMMAND_BUFFER_CMD_OP
22 }; 24 };
23 25
24 int id = static_cast<int>(command_id); 26 int id = static_cast<int>(command_id);
25 return (id >= 0 && id < kNumCommands) ? names[id] : "*unknown-command*"; 27 return (id >= 0 && id < kNumCommands) ? names[id] : "*unknown-command*";
26 } 28 }
27 29
28 } // namespace cmd 30 } // namespace cmd
29 } // namespace gpu 31 } // namespace gpu
30 32
31 33
OLDNEW
« no previous file with comments | « gpu/command_buffer/common/cmd_buffer_common.h ('k') | gpu/command_buffer/service/gles2_cmd_decoder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698