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

Unified Diff: cc/output/gl_renderer.cc

Issue 609663003: cc: Remove use of PassAs() and constructor-casting with scoped_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: cc-passas: PassAs-presubmit-warning Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/output/delegating_renderer_unittest.cc ('k') | cc/output/gl_renderer_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/output/gl_renderer.cc
diff --git a/cc/output/gl_renderer.cc b/cc/output/gl_renderer.cc
index a6de8525dc21e6318666ea24c9d75ac8818ab21b..04ba194bce05c67e9561217436f63f9ca3ac81c3 100644
--- a/cc/output/gl_renderer.cc
+++ b/cc/output/gl_renderer.cc
@@ -145,7 +145,7 @@ class GLRenderer::ScopedUseGrContext {
static scoped_ptr<ScopedUseGrContext> Create(GLRenderer* renderer,
DrawingFrame* frame) {
if (!renderer->output_surface_->context_provider()->GrContext())
- return scoped_ptr<ScopedUseGrContext>();
+ return nullptr;
return make_scoped_ptr(new ScopedUseGrContext(renderer, frame));
}
@@ -968,7 +968,7 @@ scoped_ptr<ScopedResource> GLRenderer::GetBackgroundWithFilters(
UseRenderPass(frame, target_render_pass);
if (!using_background_texture)
- return scoped_ptr<ScopedResource>();
+ return nullptr;
return background_texture.Pass();
}
@@ -2167,7 +2167,7 @@ void GLRenderer::FinishDrawingFrame(DrawingFrame* frame) {
pending_sync_queries_.push_back(current_sync_query_.Pass());
}
- current_framebuffer_lock_.reset();
+ current_framebuffer_lock_ = nullptr;
swap_buffer_rect_.Union(gfx::ToEnclosingRect(frame->root_damage_rect));
GLC(gl_, gl_->Disable(GL_BLEND));
@@ -2645,7 +2645,7 @@ bool GLRenderer::UseScopedTexture(DrawingFrame* frame,
}
void GLRenderer::BindFramebufferToOutputSurface(DrawingFrame* frame) {
- current_framebuffer_lock_.reset();
+ current_framebuffer_lock_ = nullptr;
output_surface_->BindFramebuffer();
if (output_surface_->HasExternalStencilTest()) {
@@ -2661,7 +2661,7 @@ bool GLRenderer::BindFramebufferToTexture(DrawingFrame* frame,
const gfx::Rect& target_rect) {
DCHECK(texture->id());
- current_framebuffer_lock_.reset();
+ current_framebuffer_lock_ = nullptr;
SetStencilEnabled(false);
GLC(gl_, gl_->BindFramebuffer(GL_FRAMEBUFFER, offscreen_framebuffer_id_));
@@ -3082,7 +3082,7 @@ GLRenderer::GetVideoStreamTextureProgram(TexCoordPrecision precision) {
}
void GLRenderer::CleanupSharedObjects() {
- shared_geometry_.reset();
+ shared_geometry_ = nullptr;
for (int i = 0; i < NumTexCoordPrecisions; ++i) {
for (int j = 0; j < NumSamplerTypes; ++j) {
« no previous file with comments | « cc/output/delegating_renderer_unittest.cc ('k') | cc/output/gl_renderer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698