• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //
2 // Copyright 2018 The ANGLE Project Authors. All rights reserved.
3 // Use of this source code is governed by a BSD-style license that can be
4 // found in the LICENSE file.
5 //
6 
7 // RendererWGL.h: Renderer class for GL on Windows.  Owns a WGL context object.
8 
9 #ifndef LIBANGLE_RENDERER_GL_WGL_RENDERERWGL_H_
10 #define LIBANGLE_RENDERER_GL_WGL_RENDERERWGL_H_
11 
12 #include "libANGLE/renderer/gl/RendererGL.h"
13 #include "libANGLE/renderer/gl/wgl/FunctionsWGL.h"
14 
15 namespace rx
16 {
17 class DisplayWGL;
18 
19 class RendererWGL : public RendererGL
20 {
21   public:
22     RendererWGL(std::unique_ptr<FunctionsGL> functionsGL,
23                 const egl::AttributeMap &attribMap,
24                 DisplayWGL *display,
25                 HGLRC context,
26                 HGLRC sharedContext,
27                 const std::vector<int> workerContextAttribs);
28     ~RendererWGL() override;
29 
30     HGLRC getContext() const;
31 
32   private:
33     WorkerContext *createWorkerContext(std::string *infoLog) override;
34     DisplayWGL *mDisplay;
35     HGLRC mContext;
36     HGLRC mSharedContext;
37     const std::vector<int> mWorkerContextAttribs;
38 };
39 }  // namespace rx
40 
41 #endif  // LIBANGLE_RENDERER_GL_WGL_RENDERERWGL_H_
42