Monado OpenXR Runtime
comp_gl_win32_client.h
Go to the documentation of this file.
1// Copyright 2019-2022, Collabora, Ltd.
2// SPDX-License-Identifier: BSL-1.0
3/*!
4 * @file
5 * @brief OpenGL on Win32 client side glue to compositor header.
6 * @author Rylie Pavlik <rylie.pavlik@collabora.com>
7 * @author Jakob Bornecrantz <jakob@collabora.com>
8 * @ingroup comp_client
9 */
10
11#pragma once
12
13#include "xrt/xrt_gfx_win32.h"
15
16#ifdef __cplusplus
17extern "C" {
18#endif
19
21{
22 HDC hDC;
23 HGLRC hGLRC;
24};
25
26/*!
27 * @class client_gl_win32_compositor
28 * A client facing win32 OpenGL base compositor.
29 *
30 * @ingroup comp_client
31 * @extends client_gl_compositor
32 */
34{
35 //! OpenGL compositor wrapper base.
37
38 /*!
39 * Temporary storage for "current" OpenGL context while app_context is
40 * made current using context_begin/context_end. We only need one because
41 * app_context can only be made current in one thread at a time too.
42 */
44
45 //! GL context provided in graphics binding.
47
48 //! The OpenGL library
49 HMODULE opengl;
50};
51
52/*!
53 * Create a new client_gl_win32_compositor.
54 *
55 * @public @memberof client_gl_win32_compositor
56 * @see xrt_compositor_native
57 */
59client_gl_win32_compositor_create(struct xrt_compositor_native *xcn, void *hDC, void *hGLRC);
60
61
62#ifdef __cplusplus
63}
64#endif
OpenGL client side glue to compositor header.
Wraps the real compositor providing a OpenGL based interface.
Definition: comp_gl_client.h:142
Definition: comp_gl_win32_client.h:21
A client facing win32 OpenGL base compositor.
Definition: comp_gl_win32_client.h:34
struct client_gl_compositor base
OpenGL compositor wrapper base.
Definition: comp_gl_win32_client.h:36
struct client_gl_win32_compositor * client_gl_win32_compositor_create(struct xrt_compositor_native *xcn, void *hDC, void *hGLRC)
Create a new client_gl_win32_compositor.
Definition: comp_gl_win32_client.c:132
struct client_gl_context temp_context
Temporary storage for "current" OpenGL context while app_context is made current using context_begin/...
Definition: comp_gl_win32_client.h:43
HMODULE opengl
The OpenGL library.
Definition: comp_gl_win32_client.h:49
struct client_gl_context app_context
GL context provided in graphics binding.
Definition: comp_gl_win32_client.h:46
Main compositor server interface.
Definition: xrt_compositor.h:2224
Header defining an XRT graphics provider.