cec: moved method decriptions from cecc.h to cec.h
[deb_libcec.git] / include / cecc.h
... / ...
CommitLineData
1#pragma once
2/*
3 * This file is part of the libCEC(R) library.
4 *
5 * libCEC(R) is Copyright (C) 2011 Pulse-Eight Limited. All rights reserved.
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
37#include <cectypes.h>
38
39#ifdef __cplusplus
40extern "C" {
41#endif
42
43#ifdef __cplusplus
44extern DECLSPEC int cec_init(const char *strDeviceName, CEC::cec_logical_address iLogicalAddress = CEC::CECDEVICE_PLAYBACKDEVICE1, uint16_t iPhysicalAddress = CEC_DEFAULT_PHYSICAL_ADDRESS);
45#else
46extern DECLSPEC int cec_init(const char *strDeviceName, cec_logical_address iLogicalAddress = CECDEVICE_PLAYBACKDEVICE1, uint16_t iPhysicalAddress = CEC_DEFAULT_PHYSICAL_ADDRESS);
47#endif
48
49#ifdef __cplusplus
50extern DECLSPEC int cec_init_typed(const char *strDeviceName, CEC::cec_device_type_list devicesTypes);
51#else
52extern DECLSPEC int cec_init_typed(const char *strDeviceName, cec_device_type_list devicesTypes);
53#endif
54
55
56extern DECLSPEC void cec_destroy(void);
57
58extern DECLSPEC int cec_open(const char *strPort, uint32_t iTimeout);
59
60extern DECLSPEC void cec_close(void);
61
62#ifdef __cplusplus
63extern DECLSPEC int8_t cec_find_adapters(CEC::cec_adapter *deviceList, uint8_t iBufSize, const char *strDevicePath = NULL);
64#else
65extern DECLSPEC int8_t cec_find_adapters(cec_adapter *deviceList, uint8_t iBufSize, const char *strDevicePath = NULL);
66#endif
67
68extern DECLSPEC int cec_ping_adapters(void);
69
70extern DECLSPEC int cec_start_bootloader(void);
71
72extern DECLSPEC int8_t cec_get_min_lib_version(void);
73
74extern DECLSPEC int8_t cec_get_lib_version_major(void);
75
76extern DECLSPEC int8_t cec_get_lib_version_minor(void);
77
78#ifdef __cplusplus
79extern DECLSPEC int cec_power_on_devices(CEC::cec_logical_address address = CEC::CECDEVICE_TV);
80#else
81extern DECLSPEC int cec_power_on_devices(cec_logical_address address = CECDEVICE_TV);
82#endif
83
84#ifdef __cplusplus
85extern DECLSPEC int cec_standby_devices(CEC::cec_logical_address address = CEC::CECDEVICE_BROADCAST);
86#else
87extern DECLSPEC int cec_standby_devices(cec_logical_address address = CECDEVICE_BROADCAST);
88#endif
89
90extern DECLSPEC int cec_set_active_view(void);
91
92extern DECLSPEC int cec_set_inactive_view(void);
93
94#ifdef __cplusplus
95extern DECLSPEC int cec_get_next_log_message(CEC::cec_log_message *message);
96#else
97extern DECLSPEC int cec_get_next_log_message(cec_log_message *message);
98#endif
99
100#ifdef __cplusplus
101extern DECLSPEC int cec_get_next_keypress(CEC::cec_keypress *key);
102#else
103extern DECLSPEC int cec_get_next_keypress(cec_keypress *key);
104#endif
105
106#ifdef __cplusplus
107extern DECLSPEC int cec_get_next_command(CEC::cec_command *command);
108#else
109extern DECLSPEC int cec_get_next_command(cec_command *command);
110#endif
111
112#ifdef __cplusplus
113extern DECLSPEC int cec_transmit(const CEC::cec_command &data);
114#else
115extern DECLSPEC int cec_transmit(const cec_command &data);
116#endif
117
118#ifdef __cplusplus
119extern DECLSPEC int cec_set_logical_address(CEC::cec_logical_address iLogicalAddress = CEC::CECDEVICE_PLAYBACKDEVICE1);
120#else
121extern DECLSPEC int cec_set_logical_address(cec_logical_address myAddress, cec_logical_address targetAddress);
122#endif
123
124extern DECLSPEC int cec_set_physical_address(uint16_t iPhysicalAddress = CEC_DEFAULT_PHYSICAL_ADDRESS);
125
126#ifdef __cplusplus
127extern DECLSPEC int cec_set_osd_string(CEC::cec_logical_address iLogicalAddress, CEC::cec_display_control duration, const char *strMessage);
128#else
129extern DECLSPEC int cec_set_osd_string(cec_logical_address iLogicalAddress, cec_display_control duration, const char *strMessage);
130#endif
131
132extern DECLSPEC int cec_switch_monitoring(int bEnable);
133
134#ifdef __cplusplus
135extern DECLSPEC CEC::cec_version cec_get_device_cec_version(CEC::cec_logical_address iLogicalAddress);
136#else
137extern DECLSPEC cec_version cec_get_device_cec_version(cec_logical_address iLogicalAddress);
138#endif
139
140#ifdef __cplusplus
141extern DECLSPEC int cec_get_device_menu_language(CEC::cec_logical_address iLogicalAddress, CEC::cec_menu_language *language);
142#else
143extern DECLSPEC int cec_get_device_menu_language(cec_logical_address iLogicalAddress, cec_menu_language *language);
144#endif
145
146#ifdef __cplusplus
147extern DECLSPEC uint64_t cec_get_device_vendor_id(CEC::cec_logical_address iLogicalAddress);
148#else
149extern DECLSPEC uint64_t cec_get_device_vendor_id(cec_logical_address iLogicalAddress);
150#endif
151
152#ifdef __cplusplus
153extern DECLSPEC CEC::cec_power_status cec_get_device_power_status(CEC::cec_logical_address iLogicalAddress);
154#else
155extern DECLSPEC cec_power_status cec_get_device_power_status(cec_logical_address iLogicalAddress);
156#endif
157
158#ifdef __cplusplus
159extern DECLSPEC int cec_poll_device(CEC::cec_logical_address iLogicalAddress);
160#else
161extern DECLSPEC int cec_poll_device(cec_logical_address iLogicalAddress);
162#endif
163
164#ifdef __cplusplus
165};
166#endif
167
168#endif /* CECEXPORTS_C_H_ */