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

Side by Side Diff: webkit/gpu/test_context_provider_factory.h

Issue 12217099: Implement the Platform::sharedOffscreenGraphicsContext3D method. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: no factory member vars Created 7 years, 9 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef WEBKIT_GPU_TEST_CONTEXT_PROVIDER_FACTORY_H_
6 #define WEBKIT_GPU_TEST_CONTEXT_PROVIDER_FACTORY_H_
7
8 #include "base/memory/ref_counted.h"
9 #include "webkit/gpu/webkit_gpu_export.h"
10 #include "webkit/support/webkit_support.h"
11
12 namespace cc {
13 class ContextProvider;
14 }
15
16 namespace webkit {
17 namespace gpu {
18 class ContextProviderInProcess;
19
20 class WEBKIT_GPU_EXPORT TestContextProviderFactory {
21 public:
22 static void SetUpFactoryForTesting(
23 webkit_support::GraphicsContext3DImplementation implementation);
24
25 // SetUpFactoryForTesting() must be called before GetInstance can be called.
26 // The returned pointer is static and should not be deleted by the caller.
27 static TestContextProviderFactory* GetInstance();
28
29 scoped_refptr<cc::ContextProvider> OffscreenContextProviderForMainThread();
30 scoped_refptr<cc::ContextProvider>
31 OffscreenContextProviderForCompositorThread();
32
33 private:
34 TestContextProviderFactory();
35 ~TestContextProviderFactory();
36
37 scoped_refptr<webkit::gpu::ContextProviderInProcess> main_thread_;
38 scoped_refptr<webkit::gpu::ContextProviderInProcess> compositor_thread_;
39
40 DISALLOW_COPY_AND_ASSIGN(TestContextProviderFactory);
41 };
42
43 } // namespace gpu
44 } // namespace webkit
45
46 #endif // WEBKIT_GPU_TEST_WEBKIT_CONTEXT_PROVIDER_FACTORY_H_
OLDNEW
« no previous file with comments | « webkit/gpu/grcontext_for_webgraphicscontext3d.h ('k') | webkit/gpu/test_context_provider_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698