cec-config: fixed typo
[deb_libcec.git] / include / cecc.h
CommitLineData
abbca718
LOK
1#pragma once
2/*
3 * This file is part of the libCEC(R) library.
4 *
b492c10e 5 * libCEC(R) is Copyright (C) 2011-2012 Pulse-Eight Limited. All rights reserved.
abbca718
LOK
6 * libCEC(R) is an original work, containing original code.
7 *
8 * libCEC(R) is a trademark of Pulse-Eight Limited.
9 *
10 * This program is dual-licensed; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
19 *
20 * You should have received a copy of the GNU General Public License
21 * along with this program; if not, write to the Free Software
22 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
23 *
24 *
25 * Alternatively, you can license this library under a commercial license,
26 * please contact Pulse-Eight Licensing for more information.
27 *
28 * For more information contact:
29 * Pulse-Eight Licensing <license@pulse-eight.com>
30 * http://www.pulse-eight.com/
31 * http://www.pulse-eight.net/
32 */
33
34#ifndef CECEXPORTS_C_H_
35#define CECEXPORTS_C_H_
36
bafc6701 37#include "cectypes.h"
acec5f48 38
abbca718
LOK
39#ifdef __cplusplus
40extern "C" {
41#endif
42
f8513317
LOK
43#ifdef __cplusplus
44extern DECLSPEC int cec_init_typed(const char *strDeviceName, CEC::cec_device_type_list devicesTypes);
45#else
46extern DECLSPEC int cec_init_typed(const char *strDeviceName, cec_device_type_list devicesTypes);
47#endif
48
5f39c4d8
LOK
49extern DECLSPEC void cec_destroy(void);
50
02ee2c68 51extern DECLSPEC int cec_open(const char *strPort, uint32_t iTimeout);
abbca718 52
5f39c4d8 53extern DECLSPEC void cec_close(void);
f99bc831 54
fa4798bd 55#ifdef __cplusplus
547b390d 56extern DECLSPEC int cec_enable_callbacks(void *cbParam, CEC::ICECCallbacks *callbacks);
fa4798bd 57#else
547b390d 58extern DECLSPEC int cec_enable_callbacks(void *cbParam, ICECCallbacks *callbacks);
fa4798bd
LOK
59#endif
60
2abe74eb 61#ifdef __cplusplus
f958766e 62extern DECLSPEC int8_t cec_find_adapters(CEC::cec_adapter *deviceList, uint8_t iBufSize, const char *strDevicePath);
2abe74eb 63#else
f958766e 64extern DECLSPEC int8_t cec_find_adapters(cec_adapter *deviceList, uint8_t iBufSize, const char *strDevicePath);
2abe74eb
LOK
65#endif
66
02ee2c68 67extern DECLSPEC int cec_ping_adapters(void);
abbca718 68
02ee2c68 69extern DECLSPEC int cec_start_bootloader(void);
abbca718 70
d75be19b 71extern DECLSPEC int8_t cec_get_min_lib_version(void);
2abe74eb 72
d75be19b 73extern DECLSPEC int8_t cec_get_lib_version_major(void);
abbca718 74
eafd9bed
LOK
75extern DECLSPEC int8_t cec_get_lib_version_minor(void);
76
abbca718 77#ifdef __cplusplus
f958766e 78extern DECLSPEC int cec_power_on_devices(CEC::cec_logical_address address);
abbca718 79#else
f958766e 80extern DECLSPEC int cec_power_on_devices(cec_logical_address address);
abbca718
LOK
81#endif
82
abbca718 83#ifdef __cplusplus
f958766e 84extern DECLSPEC int cec_standby_devices(CEC::cec_logical_address address);
abbca718 85#else
f958766e 86extern DECLSPEC int cec_standby_devices(cec_logical_address address);
abbca718
LOK
87#endif
88
02ee2c68 89extern DECLSPEC int cec_set_active_view(void);
abbca718 90
18203d17 91#ifdef __cplusplus
f958766e 92extern DECLSPEC int cec_set_active_source(CEC::cec_device_type type);
18203d17 93#else
f958766e 94extern DECLSPEC int cec_set_active_source(cec_device_type type);
18203d17
LOK
95#endif
96
f2cdbc36
PG
97#ifdef __cplusplus
98extern DECLSPEC int cec_set_deck_control_mode(CEC::cec_deck_control_mode mode, int bSendUpdate);
99#else
100extern DECLSPEC int cec_set_deck_control_mode(cec_deck_control_mode mode, int bSendUpdate);
101#endif
102
103#ifdef __cplusplus
104extern DECLSPEC int cec_set_deck_info(CEC::cec_deck_info info, int bSendUpdate);
105#else
106extern DECLSPEC int cec_set_deck_info(cec_deck_info info, int bSendUpdate);
107#endif
108
02ee2c68 109extern DECLSPEC int cec_set_inactive_view(void);
abbca718 110
f2cdbc36
PG
111#ifdef __cplusplus
112extern DECLSPEC int cec_set_menu_state(CEC::cec_menu_state state, int bSendUpdate);
113#else
114extern DECLSPEC int cec_set_menu_state(cec_menu_state state, int bSendUpdate);
115#endif
116
abbca718 117#ifdef __cplusplus
02ee2c68 118extern DECLSPEC int cec_get_next_log_message(CEC::cec_log_message *message);
abbca718 119#else
02ee2c68 120extern DECLSPEC int cec_get_next_log_message(cec_log_message *message);
abbca718
LOK
121#endif
122
abbca718 123#ifdef __cplusplus
02ee2c68 124extern DECLSPEC int cec_get_next_keypress(CEC::cec_keypress *key);
abbca718 125#else
02ee2c68 126extern DECLSPEC int cec_get_next_keypress(cec_keypress *key);
abbca718
LOK
127#endif
128
825ddb96 129#ifdef __cplusplus
02ee2c68 130extern DECLSPEC int cec_get_next_command(CEC::cec_command *command);
825ddb96 131#else
02ee2c68 132extern DECLSPEC int cec_get_next_command(cec_command *command);
825ddb96
LOK
133#endif
134
abbca718 135#ifdef __cplusplus
f958766e 136extern DECLSPEC int cec_transmit(const CEC::cec_command *data);
abbca718 137#else
f958766e 138extern DECLSPEC int cec_transmit(const cec_command *data);
abbca718
LOK
139#endif
140
6dfe9213 141#ifdef __cplusplus
f958766e 142extern DECLSPEC int cec_set_logical_address(CEC::cec_logical_address iLogicalAddress);
6dfe9213 143#else
f958766e 144extern DECLSPEC int cec_set_logical_address(cec_logical_address iLogicalAddress);
6dfe9213
LOK
145#endif
146
f958766e 147extern DECLSPEC int cec_set_physical_address(uint16_t iPhysicalAddress);
2492216a 148
1969b140
LOK
149#ifdef __cplusplus
150extern DECLSPEC int cec_set_osd_string(CEC::cec_logical_address iLogicalAddress, CEC::cec_display_control duration, const char *strMessage);
151#else
152extern DECLSPEC int cec_set_osd_string(cec_logical_address iLogicalAddress, cec_display_control duration, const char *strMessage);
153#endif
154
8b7e5ff6
LOK
155extern DECLSPEC int cec_switch_monitoring(int bEnable);
156
6a1c0009
LOK
157#ifdef __cplusplus
158extern DECLSPEC CEC::cec_version cec_get_device_cec_version(CEC::cec_logical_address iLogicalAddress);
159#else
160extern DECLSPEC cec_version cec_get_device_cec_version(cec_logical_address iLogicalAddress);
161#endif
162
a3269a0a
LOK
163#ifdef __cplusplus
164extern DECLSPEC int cec_get_device_menu_language(CEC::cec_logical_address iLogicalAddress, CEC::cec_menu_language *language);
165#else
44c74256 166extern DECLSPEC int cec_get_device_menu_language(cec_logical_address iLogicalAddress, cec_menu_language *language);
a3269a0a 167#endif
44c74256 168
44c74256
LOK
169#ifdef __cplusplus
170extern DECLSPEC uint64_t cec_get_device_vendor_id(CEC::cec_logical_address iLogicalAddress);
171#else
172extern DECLSPEC uint64_t cec_get_device_vendor_id(cec_logical_address iLogicalAddress);
173#endif
174
eab72c40
LOK
175#ifdef __cplusplus
176extern DECLSPEC uint16_t cec_get_device_physical_address(CEC::cec_logical_address iLogicalAddress);
177#else
178extern DECLSPEC uint16_t cec_get_device_physical_address(cec_logical_address iLogicalAddress);
179#endif
180
b4b1b49b
LOK
181#ifdef __cplusplus
182extern DECLSPEC CEC::cec_logical_address cec_get_active_source(void);
183#else
184extern DECLSPEC cec_logical_address cec_get_active_source(void);
185#endif
186
187#ifdef __cplusplus
188extern DECLSPEC int cec_is_active_source(CEC::cec_logical_address iAddress);
189#else
190extern DECLSPEC int cec_is_active_source(cec_logical_address iAddress);
191#endif
192
e55f3f70
LOK
193#ifdef __cplusplus
194extern DECLSPEC CEC::cec_power_status cec_get_device_power_status(CEC::cec_logical_address iLogicalAddress);
195#else
196extern DECLSPEC cec_power_status cec_get_device_power_status(cec_logical_address iLogicalAddress);
197#endif
198
57f45e6c
LOK
199#ifdef __cplusplus
200extern DECLSPEC int cec_poll_device(CEC::cec_logical_address iLogicalAddress);
201#else
202extern DECLSPEC int cec_poll_device(cec_logical_address iLogicalAddress);
203#endif
204
6d858ba4
LOK
205#ifdef __cplusplus
206extern DECLSPEC CEC::cec_logical_addresses cec_get_active_devices(void);
207#else
208extern DECLSPEC cec_logical_addresses cec_get_active_devices(void);
209#endif
210
211#ifdef __cplusplus
212extern DECLSPEC int cec_is_active_device(CEC::cec_logical_address iAddress);
213#else
214extern DECLSPEC int cec_is_active_device(cec_logical_address iAddress);
215#endif
216
217#ifdef __cplusplus
218extern DECLSPEC int cec_is_active_device_type(CEC::cec_device_type type);
219#else
220extern DECLSPEC int cec_is_active_device_type(cec_device_type type);
221#endif
222
d2f1c157
LOK
223#ifdef __cplusplus
224extern DECLSPEC int cec_set_hdmi_port(CEC::cec_logical_address iBaseDevice, uint8_t iPort);
225#else
226extern DECLSPEC int cec_set_hdmi_port(cec_logical_address iBaseDevice, uint8_t iPort);
227#endif
16b1e052 228
5c73f7f7 229extern DECLSPEC int cec_volume_up(int bSendRelease);
04e637f9 230
5c73f7f7 231extern DECLSPEC int cec_volume_down(int bSendRelease);
a33794d8 232
5c73f7f7 233extern DECLSPEC int cec_mute_audio(int bSendRelease);
a33794d8
LOK
234
235#ifdef __cplusplus
236extern DECLSPEC int cec_send_keypress(CEC::cec_logical_address iDestination, CEC::cec_user_control_code key, int bWait);
237#else
238extern DECLSPEC int cec_send_keypress(cec_logical_address iDestination, cec_user_control_code key, int bWait);
239#endif
240
241#ifdef __cplusplus
242extern DECLSPEC int cec_send_key_release(CEC::cec_logical_address iDestination, int bWait);
243#else
244extern DECLSPEC int cec_send_key_release(cec_logical_address iDestination, int bWait);
245#endif
04e637f9 246
ed21be2a 247#ifdef __cplusplus
f71a1df9 248extern DECLSPEC CEC::cec_osd_name cec_get_device_osd_name(CEC::cec_logical_address iAddress);
ed21be2a 249#else
f71a1df9 250extern DECLSPEC cec_osd_name cec_get_device_osd_name(cec_logical_address iAddress);
ed21be2a 251#endif
04e637f9 252
2dbd78f8
LOK
253extern DECLSPEC int cec_enable_physical_address_detection(void);
254
f42d3e0f
LOK
255#ifdef __cplusplus
256extern DECLSPEC int cec_set_stream_path_logical(CEC::cec_logical_address iAddress);
257#else
258extern DECLSPEC int cec_set_stream_path_logical(cec_logical_address iAddress);
259#endif
260
261extern DECLSPEC int cec_set_stream_path_physical(uint16_t iPhysicalAddress);
262
80b72250
LOK
263#ifdef __cplusplus
264extern DECLSPEC CEC::cec_logical_addresses cec_get_logical_addresses(void);
265#else
266extern DECLSPEC cec_logical_addresses cec_get_logical_addresses(void);
267#endif
268
abbca718
LOK
269#ifdef __cplusplus
270};
271#endif
272
273#endif /* CECEXPORTS_C_H_ */