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

Side by Side Diff: content/common/gpu/gpu_command_buffer_stub.cc

Issue 7765013: Revert 98504 - Manually merging trunk revs 95836 and 96904 to 835 branch (second attempt) (Closed) Base URL: svn://svn.chromium.org/chrome/branches/835/src/
Patch Set: Created 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | content/renderer/gpu/renderer_gl_context.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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #if defined(ENABLE_GPU) 5 #if defined(ENABLE_GPU)
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/debug/trace_event.h" 9 #include "base/debug/trace_event.h"
10 #include "base/process_util.h" 10 #include "base/process_util.h"
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 requested_attribs_(attribs), 49 requested_attribs_(attribs),
50 route_id_(route_id), 50 route_id_(route_id),
51 software_(software), 51 software_(software),
52 last_flush_count_(0), 52 last_flush_count_(0),
53 renderer_id_(renderer_id), 53 renderer_id_(renderer_id),
54 render_view_id_(render_view_id), 54 render_view_id_(render_view_id),
55 parent_stub_for_initialization_(), 55 parent_stub_for_initialization_(),
56 parent_texture_for_initialization_(0), 56 parent_texture_for_initialization_(0),
57 watchdog_(watchdog), 57 watchdog_(watchdog),
58 task_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) { 58 task_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) {
59 if (share_group) { 59 if (share_group)
60 context_group_ = share_group->context_group_; 60 context_group_ = share_group->context_group_;
61 } else { 61 else
62 // TODO(gman): this needs to be false for everything but Pepper. 62 context_group_ = new gpu::gles2::ContextGroup;
63 bool bind_generates_resource = true;
64 context_group_ = new gpu::gles2::ContextGroup(bind_generates_resource);
65 }
66 } 63 }
67 64
68 GpuCommandBufferStub::~GpuCommandBufferStub() { 65 GpuCommandBufferStub::~GpuCommandBufferStub() {
69 if (scheduler_.get()) { 66 if (scheduler_.get()) {
70 scheduler_->Destroy(); 67 scheduler_->Destroy();
71 } 68 }
72 69
73 GpuChannelManager* gpu_channel_manager = channel_->gpu_channel_manager(); 70 GpuChannelManager* gpu_channel_manager = channel_->gpu_channel_manager();
74 gpu_channel_manager->Send(new GpuHostMsg_DestroyCommandBuffer( 71 gpu_channel_manager->Send(new GpuHostMsg_DestroyCommandBuffer(
75 handle_, renderer_id_, render_view_id_)); 72 handle_, renderer_id_, render_view_id_));
(...skipping 497 matching lines...) Expand 10 before | Expand all | Expand 10 after
573 new GpuVideoDecodeAccelerator(this, route_id_, this)); 570 new GpuVideoDecodeAccelerator(this, route_id_, this));
574 video_decoder_->Initialize(configs); 571 video_decoder_->Initialize(configs);
575 } 572 }
576 573
577 void GpuCommandBufferStub::OnDestroyVideoDecoder() { 574 void GpuCommandBufferStub::OnDestroyVideoDecoder() {
578 LOG(ERROR) << "GpuCommandBufferStub::OnDestroyVideoDecoder"; 575 LOG(ERROR) << "GpuCommandBufferStub::OnDestroyVideoDecoder";
579 video_decoder_.reset(); 576 video_decoder_.reset();
580 } 577 }
581 578
582 #endif // defined(ENABLE_GPU) 579 #endif // defined(ENABLE_GPU)
OLDNEW
« no previous file with comments | « no previous file | content/renderer/gpu/renderer_gl_context.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698