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

Side by Side Diff: content/browser/aura/no_transport_image_transport_factory.cc

Issue 111063003: Aura: Don't create GL context for CreateSharedSurfaceHandle() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "content/browser/aura/no_transport_image_transport_factory.h" 5 #include "content/browser/aura/no_transport_image_transport_factory.h"
6 6
7 #include "cc/output/context_provider.h" 7 #include "cc/output/context_provider.h"
8 #include "content/common/gpu/client/gl_helper.h" 8 #include "content/common/gpu/client/gl_helper.h"
9 #include "third_party/WebKit/public/platform/WebGraphicsContext3D.h" 9 #include "third_party/WebKit/public/platform/WebGraphicsContext3D.h"
10 #include "ui/compositor/compositor.h" 10 #include "ui/compositor/compositor.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 scoped_ptr<ui::ContextFactory> context_factory) 47 scoped_ptr<ui::ContextFactory> context_factory)
48 : context_factory_(context_factory.Pass()) {} 48 : context_factory_(context_factory.Pass()) {}
49 49
50 NoTransportImageTransportFactory::~NoTransportImageTransportFactory() {} 50 NoTransportImageTransportFactory::~NoTransportImageTransportFactory() {}
51 51
52 ui::ContextFactory* NoTransportImageTransportFactory::AsContextFactory() { 52 ui::ContextFactory* NoTransportImageTransportFactory::AsContextFactory() {
53 return context_factory_.get(); 53 return context_factory_.get();
54 } 54 }
55 55
56 gfx::GLSurfaceHandle 56 gfx::GLSurfaceHandle
57 NoTransportImageTransportFactory::CreateSharedSurfaceHandle() { 57 NoTransportImageTransportFactory::GetSharedSurfaceHandle() {
58 return gfx::GLSurfaceHandle(); 58 return gfx::GLSurfaceHandle();
59 } 59 }
60 60
61 void NoTransportImageTransportFactory::DestroySharedSurfaceHandle(
62 gfx::GLSurfaceHandle surface) {}
63
64 scoped_refptr<ui::Texture> 61 scoped_refptr<ui::Texture>
65 NoTransportImageTransportFactory::CreateTransportClient( 62 NoTransportImageTransportFactory::CreateTransportClient(
66 float device_scale_factor) { 63 float device_scale_factor) {
67 return new FakeTexture(context_factory_->SharedMainThreadContextProvider(), 64 return new FakeTexture(context_factory_->SharedMainThreadContextProvider(),
68 device_scale_factor); 65 device_scale_factor);
69 } 66 }
70 67
71 scoped_refptr<ui::Texture> NoTransportImageTransportFactory::CreateOwnedTexture( 68 scoped_refptr<ui::Texture> NoTransportImageTransportFactory::CreateOwnedTexture(
72 const gfx::Size& size, 69 const gfx::Size& size,
73 float device_scale_factor, 70 float device_scale_factor,
(...skipping 16 matching lines...) Expand all
90 87
91 // We don't generate lost context events, so we don't need to keep track of 88 // We don't generate lost context events, so we don't need to keep track of
92 // observers 89 // observers
93 void NoTransportImageTransportFactory::AddObserver( 90 void NoTransportImageTransportFactory::AddObserver(
94 ImageTransportFactoryObserver* observer) {} 91 ImageTransportFactoryObserver* observer) {}
95 92
96 void NoTransportImageTransportFactory::RemoveObserver( 93 void NoTransportImageTransportFactory::RemoveObserver(
97 ImageTransportFactoryObserver* observer) {} 94 ImageTransportFactoryObserver* observer) {}
98 95
99 } // namespace content 96 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698