RetroArch
led_driver.h
Go to the documentation of this file.
1 /* RetroArch - A frontend for libretro.
2  *
3  * RetroArch is free software: you can redistribute it and/or modify it under the terms
4  * of the GNU General Public License as published by the Free Software Found-
5  * ation, either version 3 of the License, or (at your option) any later version.
6  *
7  * RetroArch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
8  * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
9  * PURPOSE. See the GNU General Public License for more details.
10  *
11  * You should have received a copy of the GNU General Public License along with RetroArch.
12  * If not, see <http://www.gnu.org/licenses/>.
13  */
14 
15 #ifndef __LED_DRIVER__H
16 #define __LED_DRIVER__H
17 
18 #include <stdint.h>
19 #include <stdlib.h>
20 #include <stddef.h>
21 #include <sys/types.h>
22 
23 #include <boolean.h>
24 #include <libretro.h>
25 #include <retro_common_api.h>
26 #include <retro_environment.h>
27 
29 
30 typedef struct led_driver
31 {
32  void (*init)(void);
33  void (*free)(void);
34  void (*set_led)(int led, int value);
35  const char *ident;
36 } led_driver_t;
37 
38 
39 bool led_driver_init(void);
40 
41 void led_driver_free(void);
42 
43 void led_driver_set_led(int led, int value);
44 
45 extern const led_driver_t null_led_driver;
46 extern const led_driver_t overlay_led_driver;
47 extern const led_driver_t rpi_led_driver;
48 
50 
51 #endif
bool led_driver_init(void)
Definition: led_driver.c:24
#define RETRO_BEGIN_DECLS
Definition: retro_common_api.h:41
Definition: led_driver.h:30
typedef void(__stdcall *PFN_DESTRUCTION_CALLBACK)(void *pData)
const led_driver_t null_led_driver
Definition: led_null.c:22
RETRO_BEGIN_DECLS struct led_driver led_driver_t
void led_driver_set_led(int led, int value)
Definition: led_driver.c:59
void(* free)(void)
Definition: led_driver.h:33
const led_driver_t overlay_led_driver
Definition: led_overlay.c:65
const char * ident
Definition: led_driver.h:35
void(* init)(void)
Definition: led_driver.h:32
#define RETRO_END_DECLS
Definition: retro_common_api.h:42
const led_driver_t rpi_led_driver
Definition: led_rpi.c:140
GLsizei const GLfloat * value
Definition: glext.h:6709
void(* set_led)(int led, int value)
Definition: led_driver.h:34
void led_driver_free(void)
Definition: led_driver.c:53