Mir
gbm_buffer.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
5  * it under the terms of the GNU Lesser General Public License version 3 as
6  * 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_GBM_BUFFER_H_
20 #define MIR_CLIENT_EXTENSIONS_GBM_BUFFER_H_
21 
24 #include "mir_toolkit/mir_buffer.h"
25 
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
29 
50  MirConnection* connection,
51  int width, int height,
52  unsigned int gbm_pixel_format,
53  unsigned int gbm_bo_flags,
54  MirBufferCallback available_callback, void* available_context);
55 
57 {
60 
61 static inline MirExtensionGbmBufferV1 const* mir_extension_gbm_buffer_v1(
62  MirConnection* connection)
63 {
65  connection, "mir_extension_gbm_buffer", 1);
66 }
67 
68 #ifdef __cplusplus
69 }
70 #endif
71 #endif /* MIR_CLIENT_EXTENSIONS_GBM_BUFFER_H_ */
Definition: gbm_buffer.h:56
void(* mir_connection_allocate_buffer_gbm)(MirConnection *connection, int width, int height, unsigned int gbm_pixel_format, unsigned int gbm_bo_flags, MirBufferCallback available_callback, void *available_context)
Allocate a MirBuffer via gbm.
Definition: gbm_buffer.h:49
unsigned int height
Definition: mir_image.h:27
unsigned int width
Definition: mir_image.h:26
struct MirConnection MirConnection
Definition: client_types.h:40
void(* MirBufferCallback)(MirBuffer *, void *context)
Definition: client_types.h:475
void const * mir_connection_request_extension(MirConnection *connection, char const *interface, int version)
Request a Mir extension.
mir_connection_allocate_buffer_gbm allocate_buffer_gbm
Definition: gbm_buffer.h:58
struct MirExtensionGbmBufferV1 MirExtensionGbmBufferV1

Copyright © 2012-2016 Canonical Ltd.
Generated on Thu Feb 9 21:49:33 UTC 2017