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

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

Issue 465040: Added CommandBufferClient, CommandBufferStub and some IPC messages.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years 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
« no previous file with comments | « gpu/command_buffer/service/cmd_parser.h ('k') | gpu/command_buffer/service/cmd_parser_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2009, Google Inc. 2 * Copyright 2009, Google Inc.
3 * All rights reserved. 3 * All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 17 matching lines...) Expand all
28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 */ 30 */
31 31
32 32
33 // This file contains the implementation of the command parser. 33 // This file contains the implementation of the command parser.
34 34
35 #include "gpu/command_buffer/service/precompile.h" 35 #include "gpu/command_buffer/service/precompile.h"
36 #include "gpu/command_buffer/service/cmd_parser.h" 36 #include "gpu/command_buffer/service/cmd_parser.h"
37 37
38 namespace command_buffer { 38 namespace gpu {
39 39
40 CommandParser::CommandParser(void *shm_address, 40 CommandParser::CommandParser(void *shm_address,
41 size_t shm_size, 41 size_t shm_size,
42 ptrdiff_t offset, 42 ptrdiff_t offset,
43 size_t size, 43 size_t size,
44 CommandBufferOffset start_get, 44 CommandBufferOffset start_get,
45 AsyncAPIInterface *handler) 45 AsyncAPIInterface *handler)
46 : get_(start_get), 46 : get_(start_get),
47 put_(start_get), 47 put_(start_get),
48 handler_(handler) { 48 handler_(handler) {
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 // Processes all the commands, while the buffer is not empty. Stop if an error 100 // Processes all the commands, while the buffer is not empty. Stop if an error
101 // is encountered. 101 // is encountered.
102 parse_error::ParseError CommandParser::ProcessAllCommands() { 102 parse_error::ParseError CommandParser::ProcessAllCommands() {
103 while (!IsEmpty()) { 103 while (!IsEmpty()) {
104 parse_error::ParseError error = ProcessCommand(); 104 parse_error::ParseError error = ProcessCommand();
105 if (error) return error; 105 if (error) return error;
106 } 106 }
107 return parse_error::kParseNoError; 107 return parse_error::kParseNoError;
108 } 108 }
109 109
110 } // namespace command_buffer 110 } // namespace gpu
OLDNEW
« no previous file with comments | « gpu/command_buffer/service/cmd_parser.h ('k') | gpu/command_buffer/service/cmd_parser_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698