Mercurial > molko
comparison libmlk-core/mlk/core/gamepad.h @ 634:3930234ab1f5
examples: add basic gamepad
author | David Demelier <markand@malikania.fr> |
---|---|
date | Tue, 29 Aug 2023 13:34:10 +0200 |
parents | f76cada0bbb2 |
children |
comparison
equal
deleted
inserted
replaced
633:6271599928d4 | 634:3930234ab1f5 |
---|---|
172 /** \cond MLK_PRIVATE_DECLS */ | 172 /** \cond MLK_PRIVATE_DECLS */ |
173 void *handle; | 173 void *handle; |
174 /** \endcond MLK_PRIVATE_DECLS */ | 174 /** \endcond MLK_PRIVATE_DECLS */ |
175 }; | 175 }; |
176 | 176 |
177 #if 0 | |
178 | |
179 /** | 177 /** |
180 * \struct mlk_gamepad_iter | 178 * \struct mlk_gamepad_iter |
181 * \brief Iterate over all plugged gamepads. | 179 * \brief Iterate over all plugged gamepads. |
182 */ | 180 */ |
183 struct mlk_gamepad_iter { | 181 struct mlk_gamepad_iter { |
195 * ::mlk_gamepad_open. | 193 * ::mlk_gamepad_open. |
196 */ | 194 */ |
197 int index; | 195 int index; |
198 | 196 |
199 /** \cond MLK_PRIVATE_DECLS */ | 197 /** \cond MLK_PRIVATE_DECLS */ |
200 int end; | 198 void *list; |
199 int listsz; | |
200 int listit; | |
201 /** \endcond MLK_PRIVATE_DECLS */ | 201 /** \endcond MLK_PRIVATE_DECLS */ |
202 }; | 202 }; |
203 | 203 |
204 #if defined(__cplusplus) | 204 #if defined(__cplusplus) |
205 extern "C" { | 205 extern "C" { |
247 * \return 1 if there are still devices available | 247 * \return 1 if there are still devices available |
248 */ | 248 */ |
249 int | 249 int |
250 mlk_gamepad_iter_next(struct mlk_gamepad_iter *iter); | 250 mlk_gamepad_iter_next(struct mlk_gamepad_iter *iter); |
251 | 251 |
252 #endif | |
253 | |
254 #if defined(__cplusplus) | 252 #if defined(__cplusplus) |
255 } | 253 } |
256 #endif | 254 #endif |
257 | 255 |
258 #endif /* !MLK_CORE_GAMEPAD_H */ | 256 #endif /* !MLK_CORE_GAMEPAD_H */ |