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

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

Issue 1199313008: Allowed GLES query target migration between binary occlusion types (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 6 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
« no previous file with comments | « gpu/command_buffer/client/query_tracker.cc ('k') | gpu/command_buffer/service/query_manager.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #include "gpu/command_buffer/service/gles2_cmd_decoder.h" 5 #include "gpu/command_buffer/service/gles2_cmd_decoder.h"
6 6
7 #include <stdio.h> 7 #include <stdio.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <cmath> 10 #include <cmath>
(...skipping 11614 matching lines...) Expand 10 before | Expand all | Expand 10 after
11625 if (!query_manager_->IsValidQuery(client_id)) { 11625 if (!query_manager_->IsValidQuery(client_id)) {
11626 LOCAL_SET_GL_ERROR(GL_INVALID_OPERATION, 11626 LOCAL_SET_GL_ERROR(GL_INVALID_OPERATION,
11627 "glBeginQueryEXT", 11627 "glBeginQueryEXT",
11628 "id not made by glGenQueriesEXT"); 11628 "id not made by glGenQueriesEXT");
11629 return error::kNoError; 11629 return error::kNoError;
11630 } 11630 }
11631 query = query_manager_->CreateQuery( 11631 query = query_manager_->CreateQuery(
11632 target, client_id, sync_shm_id, sync_shm_offset); 11632 target, client_id, sync_shm_id, sync_shm_offset);
11633 } 11633 }
11634 11634
11635 if (query->target() != target) { 11635 if (!query->UpdateTarget(target)) {
11636 LOCAL_SET_GL_ERROR( 11636 LOCAL_SET_GL_ERROR(
11637 GL_INVALID_OPERATION, "glBeginQueryEXT", "target does not match"); 11637 GL_INVALID_OPERATION, "glBeginQueryEXT", "target does not match");
11638 return error::kNoError; 11638 return error::kNoError;
11639 } else if (query->shm_id() != sync_shm_id || 11639 } else if (query->shm_id() != sync_shm_id ||
11640 query->shm_offset() != sync_shm_offset) { 11640 query->shm_offset() != sync_shm_offset) {
11641 DLOG(ERROR) << "Shared memory used by query not the same as before"; 11641 DLOG(ERROR) << "Shared memory used by query not the same as before";
11642 return error::kInvalidArguments; 11642 return error::kInvalidArguments;
11643 } 11643 }
11644 11644
11645 if (!query_manager_->BeginQuery(query)) { 11645 if (!query_manager_->BeginQuery(query)) {
(...skipping 2081 matching lines...) Expand 10 before | Expand all | Expand 10 after
13727 } 13727 }
13728 } 13728 }
13729 13729
13730 // Include the auto-generated part of this file. We split this because it means 13730 // Include the auto-generated part of this file. We split this because it means
13731 // we can easily edit the non-auto generated parts right here in this file 13731 // we can easily edit the non-auto generated parts right here in this file
13732 // instead of having to edit some template or the code generator. 13732 // instead of having to edit some template or the code generator.
13733 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h" 13733 #include "gpu/command_buffer/service/gles2_cmd_decoder_autogen.h"
13734 13734
13735 } // namespace gles2 13735 } // namespace gles2
13736 } // namespace gpu 13736 } // namespace gpu
OLDNEW
« no previous file with comments | « gpu/command_buffer/client/query_tracker.cc ('k') | gpu/command_buffer/service/query_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698