Mir
set_gbm_device.h
Go to the documentation of this file.
1/*
2 * Copyright © 2016 Canonical Ltd.
3 *
4 * This program is free software: you can redistribute it and/or modify it
5 * under the terms of the GNU Lesser General Public License version 2 or 3,
6 * as published by the Free Software Foundation.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU Lesser General Public License for more details.
12 *
13 * You should have received a copy of the GNU Lesser General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 *
16 * Authored by: Kevin DuBois <kevin.dubois@canonical.com>
17 */
18
19#ifndef MIR_CLIENT_EXTENSIONS_SET_GBM_DEVICE_H_
20#define MIR_CLIENT_EXTENSIONS_SET_GBM_DEVICE_H_
21
23
24#ifdef __cplusplus
25extern "C" {
26#endif
27
28struct gbm_device;
29
30//Set the gbm device used by the client
31// \param [in] device The gbm_device.
32// \param [in] context The context to set the gbm device.
33typedef void (*MirSetGbmDevice)(struct gbm_device*, void* const context);
35{
37 void* const context;
39
40//legacy compatibility
42
43static inline MirExtensionSetGbmDeviceV1 const* mir_extension_set_gbm_device_v1(
44 MirConnection* connection)
45{
47 connection, "mir_extension_set_gbm_device", 1);
48}
49
50#ifdef __cplusplus
51}
52#endif
53#endif /* MIR_CLIENT_EXTENSIONS_SET_GBM_DEVICE_H_ */
struct MirConnection MirConnection
Definition: client_types.h:41
void const * mir_connection_request_extension(MirConnection *connection, char const *interface, int version)
Request a Mir extension.
struct MirExtensionSetGbmDeviceV1 MirExtensionSetGbmDeviceV1
void(* MirSetGbmDevice)(struct gbm_device *, void *const context)
Definition: set_gbm_device.h:33
MirExtensionSetGbmDeviceV1 MirExtensionSetGbmDevice
Definition: set_gbm_device.h:41
Definition: set_gbm_device.h:35
void *const context
Definition: set_gbm_device.h:37
MirSetGbmDevice set_gbm_device
Definition: set_gbm_device.h:36

Copyright © 2012-2022 Canonical Ltd.
Generated on Wed Dec 28 21:01:08 UTC 2022
This documentation is licensed under the GPL version 2 or 3.