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

Side by Side Diff: gpu/ipc/service/gpu_command_buffer_stub.cc

Issue 2814583002: Service/ClientDiscardableManager (Closed)
Patch Set: Feedback Created 3 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 (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/ipc/service/gpu_command_buffer_stub.h" 5 #include "gpu/ipc/service/gpu_command_buffer_stub.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 569 matching lines...) Expand 10 before | Expand all | Expand 10 after
580 context_group_ = new gles2::ContextGroup( 580 context_group_ = new gles2::ContextGroup(
581 manager->gpu_preferences(), channel_->mailbox_manager(), 581 manager->gpu_preferences(), channel_->mailbox_manager(),
582 new GpuCommandBufferMemoryTracker( 582 new GpuCommandBufferMemoryTracker(
583 channel_, command_buffer_id_.GetUnsafeValue(), 583 channel_, command_buffer_id_.GetUnsafeValue(),
584 init_params.attribs.context_type, channel_->task_runner()), 584 init_params.attribs.context_type, channel_->task_runner()),
585 manager->shader_translator_cache(), 585 manager->shader_translator_cache(),
586 manager->framebuffer_completeness_cache(), feature_info, 586 manager->framebuffer_completeness_cache(), feature_info,
587 init_params.attribs.bind_generates_resource, 587 init_params.attribs.bind_generates_resource,
588 gmb_factory ? gmb_factory->AsImageFactory() : nullptr, 588 gmb_factory ? gmb_factory->AsImageFactory() : nullptr,
589 channel_->watchdog() /* progress_reporter */, 589 channel_->watchdog() /* progress_reporter */,
590 manager->gpu_feature_info()); 590 manager->gpu_feature_info(), channel_->discardable_manager());
591 } 591 }
592 592
593 #if defined(OS_MACOSX) 593 #if defined(OS_MACOSX)
594 // Virtualize PreferIntegratedGpu contexts by default on OS X to prevent 594 // Virtualize PreferIntegratedGpu contexts by default on OS X to prevent
595 // performance regressions when enabling FCM. 595 // performance regressions when enabling FCM.
596 // http://crbug.com/180463 596 // http://crbug.com/180463
597 if (init_params.attribs.gpu_preference == gl::PreferIntegratedGpu) 597 if (init_params.attribs.gpu_preference == gl::PreferIntegratedGpu)
598 use_virtualized_gl_context_ = true; 598 use_virtualized_gl_context_ = true;
599 #endif 599 #endif
600 600
(...skipping 652 matching lines...) Expand 10 before | Expand all | Expand 10 after
1253 command_buffer_->GetLastState().error == error::kLostContext) 1253 command_buffer_->GetLastState().error == error::kLostContext)
1254 return; 1254 return;
1255 1255
1256 command_buffer_->SetContextLostReason(error::kUnknown); 1256 command_buffer_->SetContextLostReason(error::kUnknown);
1257 if (decoder_) 1257 if (decoder_)
1258 decoder_->MarkContextLost(error::kUnknown); 1258 decoder_->MarkContextLost(error::kUnknown);
1259 command_buffer_->SetParseError(error::kLostContext); 1259 command_buffer_->SetParseError(error::kLostContext);
1260 } 1260 }
1261 1261
1262 } // namespace gpu 1262 } // namespace gpu
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698