1 /*
2  * Copyright 2016, Björn Ståhl
3  * License: 3-Clause BSD, see COPYING file in arcan source repository.
4  * Reference: http://arcan-fe.com
5  * Description: Private structures shared between normal shmif- implementation
6  * and accelerated extension functions.
7  */
8 
9 enum state_fl {
10 	STATE_INDIRECT = 0,
11 	STATE_DIRECT = 1,
12 	STATE_NOACCEL = 2
13 };
14 
15 struct shmif_ext_int;
16 
17 struct shmif_ext_hidden {
18 /* optional hook for freeing */
19 	void (*cleanup)(struct arcan_shmif_cont*);
20 
21 /* currently opened render-node or similar source */
22 	int active_fd;
23 
24 /* intermediate store for specifying an explicit switch */
25 	int pending_fd;
26 
27 /* tracking information for active use */
28 	int state_fl;
29 
30 /* metadata for allocation help */
31 	size_t n_modifiers;
32 	uint64_t modifiers[64];
33 
34 /* platform- specific */
35 	struct shmif_ext_hidden_int* internal;
36 };
37