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

Side by Side Diff: services/ui/public/cpp/gles2_context.h

Issue 2586323002: mus: Use ui::ContextProviderCommandBuffer. (Closed)
Patch Set: . Created 4 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
« no previous file with comments | « services/ui/public/cpp/context_provider.cc ('k') | services/ui/public/cpp/gles2_context.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2014 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 SERVICES_UI_PUBLIC_CPP_GLES2_CONTEXT_H_
6 #define SERVICES_UI_PUBLIC_CPP_GLES2_CONTEXT_H_
7
8 #include <stdint.h>
9
10 #include <memory>
11 #include <vector>
12
13 #include "base/macros.h"
14 #include "base/single_thread_task_runner.h"
15 #include "gpu/command_buffer/client/gles2_implementation.h"
16
17 namespace gpu {
18
19 class CommandBufferProxyImpl;
20 class GpuChannelHost;
21 class TransferBuffer;
22
23 namespace gles2 {
24 class GLES2CmdHelper;
25 }
26
27 } // namespace gpu
28
29 namespace ui {
30
31 class GLES2Context {
32 public:
33 ~GLES2Context();
34 gpu::gles2::GLES2Interface* interface() const {
35 return implementation_.get();
36 }
37 gpu::ContextSupport* context_support() const { return implementation_.get(); }
38
39 static std::unique_ptr<GLES2Context> CreateOffscreenContext(
40 scoped_refptr<gpu::GpuChannelHost> gpu_channel_host,
41 scoped_refptr<base::SingleThreadTaskRunner> task_runner);
42
43 private:
44 GLES2Context();
45 bool Initialize(scoped_refptr<gpu::GpuChannelHost> gpu_channel_host,
46 scoped_refptr<base::SingleThreadTaskRunner> task_runner);
47
48 std::unique_ptr<gpu::CommandBufferProxyImpl> command_buffer_proxy_impl_;
49 std::unique_ptr<gpu::gles2::GLES2CmdHelper> gles2_helper_;
50 std::unique_ptr<gpu::TransferBuffer> transfer_buffer_;
51 std::unique_ptr<gpu::gles2::GLES2Implementation> implementation_;
52
53 DISALLOW_COPY_AND_ASSIGN(GLES2Context);
54 };
55
56 } // namespace ui
57
58 #endif // SERVICES_UI_PUBLIC_CPP_GLES2_CONTEXT_H_
OLDNEW
« no previous file with comments | « services/ui/public/cpp/context_provider.cc ('k') | services/ui/public/cpp/gles2_context.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698