| 1 |
/* |
| 2 |
* Copyright 2021 Rémi Bernon for CodeWeavers |
| 3 |
* |
| 4 |
* This library is free software; you can redistribute it and/or |
| 5 |
* modify it under the terms of the GNU Lesser General Public |
| 6 |
* License as published by the Free Software Foundation; either |
| 7 |
* version 2.1 of the License, or (at your option) any later version. |
| 8 |
* |
| 9 |
* This library is distributed in the hope that it will be useful, |
| 10 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 12 |
* Lesser General Public License for more details. |
| 13 |
* |
| 14 |
* You should have received a copy of the GNU Lesser General Public |
| 15 |
* License along with this library; if not, write to the Free Software |
| 16 |
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA |
| 17 |
*/ |
| 18 |
|
| 19 |
#ifdef __WIDL__ |
| 20 |
#pragma winrt ns_prefix |
| 21 |
#endif |
| 22 |
|
| 23 |
import "inspectable.idl"; |
| 24 |
import "asyncinfo.idl"; |
| 25 |
import "eventtoken.idl"; |
| 26 |
import "windowscontracts.idl"; |
| 27 |
import "windows.foundation.idl"; |
| 28 |
import "windows.devices.haptics.idl"; |
| 29 |
import "windows.gaming.input.forcefeedback.idl"; |
| 30 |
import "windows.system.idl"; |
| 31 |
import "windows.devices.power.idl"; |
| 32 |
|
| 33 |
namespace Windows.Gaming.Input { |
| 34 |
typedef enum ArcadeStickButtons ArcadeStickButtons; |
| 35 |
typedef enum FlightStickButtons FlightStickButtons; |
| 36 |
typedef enum GamepadButtons GamepadButtons; |
| 37 |
typedef enum GameControllerButtonLabel GameControllerButtonLabel; |
| 38 |
typedef enum GameControllerSwitchKind GameControllerSwitchKind; |
| 39 |
typedef enum GameControllerSwitchPosition GameControllerSwitchPosition; |
| 40 |
typedef enum RacingWheelButtons RacingWheelButtons; |
| 41 |
typedef struct ArcadeStickReading ArcadeStickReading; |
| 42 |
typedef struct FlightStickReading FlightStickReading; |
| 43 |
typedef struct GamepadReading GamepadReading; |
| 44 |
typedef struct GamepadVibration GamepadVibration; |
| 45 |
typedef struct RacingWheelReading RacingWheelReading; |
| 46 |
interface IArcadeStick; |
| 47 |
interface IArcadeStickStatics; |
| 48 |
interface IArcadeStickStatics2; |
| 49 |
interface IFlightStick; |
| 50 |
interface IFlightStickStatics; |
| 51 |
interface IGameController; |
| 52 |
interface IGameControllerBatteryInfo; |
| 53 |
interface IGamepad; |
| 54 |
interface IGamepad2; |
| 55 |
interface IGamepadStatics; |
| 56 |
interface IGamepadStatics2; |
| 57 |
interface IRacingWheel; |
| 58 |
interface IRacingWheelStatics; |
| 59 |
interface IRacingWheelStatics2; |
| 60 |
interface IRawGameController; |
| 61 |
interface IRawGameController2; |
| 62 |
runtimeclass ArcadeStick; |
| 63 |
runtimeclass FlightStick; |
| 64 |
runtimeclass Gamepad; |
| 65 |
runtimeclass Headset; |
| 66 |
runtimeclass RacingWheel; |
| 67 |
runtimeclass RawGameController; |
| 68 |
|
| 69 |
declare { |
| 70 |
interface Windows.Foundation.EventHandler<Windows.Gaming.Input.ArcadeStick *>; |
| 71 |
interface Windows.Foundation.EventHandler<Windows.Gaming.Input.FlightStick *>; |
| 72 |
interface Windows.Foundation.EventHandler<Windows.Gaming.Input.Gamepad *>; |
| 73 |
interface Windows.Foundation.EventHandler<Windows.Gaming.Input.RacingWheel *>; |
| 74 |
interface Windows.Foundation.EventHandler<Windows.Gaming.Input.RawGameController *>; |
| 75 |
interface Windows.Foundation.TypedEventHandler<Windows.Gaming.Input.IGameController *, Windows.Gaming.Input.Headset *>; |
| 76 |
interface Windows.Foundation.TypedEventHandler<Windows.Gaming.Input.IGameController *, Windows.System.UserChangedEventArgs *>; |
| 77 |
interface Windows.Foundation.Collections.IIterator<Windows.Gaming.Input.ArcadeStick *>; |
| 78 |
interface Windows.Foundation.Collections.IIterable<Windows.Gaming.Input.ArcadeStick *>; |
| 79 |
interface Windows.Foundation.Collections.IVectorView<Windows.Gaming.Input.ArcadeStick *>; |
| 80 |
interface Windows.Foundation.Collections.IIterator<Windows.Gaming.Input.FlightStick *>; |
| 81 |
interface Windows.Foundation.Collections.IIterable<Windows.Gaming.Input.FlightStick *>; |
| 82 |
interface Windows.Foundation.Collections.IVectorView<Windows.Gaming.Input.FlightStick *>; |
| 83 |
interface Windows.Foundation.Collections.IIterator<Windows.Gaming.Input.Gamepad *>; |
| 84 |
interface Windows.Foundation.Collections.IIterable<Windows.Gaming.Input.Gamepad *>; |
| 85 |
interface Windows.Foundation.Collections.IVectorView<Windows.Gaming.Input.Gamepad *>; |
| 86 |
interface Windows.Foundation.Collections.IVector<Windows.Gaming.Input.Gamepad *>; |
| 87 |
interface Windows.Foundation.Collections.IIterator<Windows.Gaming.Input.RacingWheel *>; |
| 88 |
interface Windows.Foundation.Collections.IIterable<Windows.Gaming.Input.RacingWheel *>; |
| 89 |
interface Windows.Foundation.Collections.IVectorView<Windows.Gaming.Input.RacingWheel *>; |
| 90 |
interface Windows.Foundation.Collections.IVector<Windows.Gaming.Input.RacingWheel *>; |
| 91 |
interface Windows.Foundation.Collections.IIterator<Windows.Gaming.Input.RawGameController *>; |
| 92 |
interface Windows.Foundation.Collections.IIterable<Windows.Gaming.Input.RawGameController *>; |
| 93 |
interface Windows.Foundation.Collections.IVectorView<Windows.Gaming.Input.RawGameController *>; |
| 94 |
interface Windows.Foundation.Collections.IVector<Windows.Gaming.Input.RawGameController *>; |
| 95 |
} |
| 96 |
|
| 97 |
[ |
| 98 |
contract(Windows.Foundation.UniversalApiContract, 3.0), |
| 99 |
flags |
| 100 |
] |
| 101 |
enum ArcadeStickButtons |
| 102 |
{ |
| 103 |
None = 0x0, |
| 104 |
StickUp = 0x1, |
| 105 |
StickDown = 0x2, |
| 106 |
StickLeft = 0x4, |
| 107 |
StickRight = 0x8, |
| 108 |
Action1 = 0x10, |
| 109 |
Action2 = 0x20, |
| 110 |
Action3 = 0x40, |
| 111 |
Action4 = 0x80, |
| 112 |
Action5 = 0x100, |
| 113 |
Action6 = 0x200, |
| 114 |
Special1 = 0x400, |
| 115 |
Special2 = 0x800 |
| 116 |
}; |
| 117 |
|
| 118 |
[ |
| 119 |
contract(Windows.Foundation.UniversalApiContract, 4.0), |
| 120 |
flags |
| 121 |
] |
| 122 |
enum FlightStickButtons |
| 123 |
{ |
| 124 |
None = 0x0, |
| 125 |
FirePrimary = 0x1, |
| 126 |
FireSecondary = 0x2, |
| 127 |
}; |
| 128 |
|
| 129 |
[ |
| 130 |
contract(Windows.Foundation.UniversalApiContract, 1.0), |
| 131 |
flags |
| 132 |
] |
| 133 |
enum GamepadButtons |
| 134 |
{ |
| 135 |
None = 0x0, |
| 136 |
Menu = 0x1, |
| 137 |
View = 0x2, |
| 138 |
A = 0x4, |
| 139 |
B = 0x8, |
| 140 |
X = 0x10, |
| 141 |
Y = 0x20, |
| 142 |
DPadUp = 0x40, |
| 143 |
DPadDown = 0x80, |
| 144 |
DPadLeft = 0x100, |
| 145 |
DPadRight = 0x200, |
| 146 |
LeftShoulder = 0x400, |
| 147 |
RightShoulder = 0x800, |
| 148 |
LeftThumbstick = 0x1000, |
| 149 |
RightThumbstick = 0x2000, |
| 150 |
[contract(Windows.Foundation.UniversalApiContract, 3.0)] |
| 151 |
Paddle1 = 0x4000, |
| 152 |
[contract(Windows.Foundation.UniversalApiContract, 3.0)] |
| 153 |
Paddle2 = 0x8000, |
| 154 |
[contract(Windows.Foundation.UniversalApiContract, 3.0)] |
| 155 |
Paddle3 = 0x10000, |
| 156 |
[contract(Windows.Foundation.UniversalApiContract, 3.0)] |
| 157 |
Paddle4 = 0x20000 |
| 158 |
}; |
| 159 |
|
| 160 |
[contract(Windows.Foundation.UniversalApiContract, 3.0)] |
| 161 |
enum GameControllerButtonLabel |
| 162 |
{ |
| 163 |
None = 0, |
| 164 |
XboxBack = 1, |
| 165 |
XboxStart = 2, |
| 166 |
XboxMenu = 3, |
| 167 |
XboxView = 4, |
| 168 |
XboxUp = 5, |
| 169 |
XboxDown = 6, |
| 170 |
XboxLeft = 7, |
| 171 |
XboxRight = 8, |
| 172 |
XboxA = 9, |
| 173 |
XboxB = 10, |
| 174 |
XboxX = 11, |
| 175 |
XboxY = 12, |
| 176 |
XboxLeftBumper = 13, |
| 177 |
XboxLeftTrigger = 14, |
| 178 |
XboxLeftStickButton = 15, |
| 179 |
XboxRightBumper = 16, |
| 180 |
XboxRightTrigger = 17, |
| 181 |
XboxRightStickButton = 18, |
| 182 |
XboxPaddle1 = 19, |
| 183 |
XboxPaddle2 = 20, |
| 184 |
XboxPaddle3 = 21, |
| 185 |
XboxPaddle4 = 22, |
| 186 |
Mode = 23, |
| 187 |
Select = 24, |
| 188 |
Menu = 25, |
| 189 |
View = 26, |
| 190 |
Back = 27, |
| 191 |
Start = 28, |
| 192 |
Options = 29, |
| 193 |
Share = 30, |
| 194 |
Up = 31, |
| 195 |
Down = 32, |
| 196 |
Left = 33, |
| 197 |
Right = 34, |
| 198 |
LetterA = 35, |
| 199 |
LetterB = 36, |
| 200 |
LetterC = 37, |
| 201 |
LetterL = 38, |
| 202 |
LetterR = 39, |
| 203 |
LetterX = 40, |
| 204 |
LetterY = 41, |
| 205 |
LetterZ = 42, |
| 206 |
Cross = 43, |
| 207 |
Circle = 44, |
| 208 |
Square = 45, |
| 209 |
Triangle = 46, |
| 210 |
LeftBumper = 47, |
| 211 |
LeftTrigger = 48, |
| 212 |
LeftStickButton = 49, |
| 213 |
Left1 = 50, |
| 214 |
Left2 = 51, |
| 215 |
Left3 = 52, |
| 216 |
RightBumper = 53, |
| 217 |
RightTrigger = 54, |
| 218 |
RightStickButton = 55, |
| 219 |
Right1 = 56, |
| 220 |
Right2 = 57, |
| 221 |
Right3 = 58, |
| 222 |
Paddle1 = 59, |
| 223 |
Paddle2 = 60, |
| 224 |
Paddle3 = 61, |
| 225 |
Paddle4 = 62, |
| 226 |
Plus = 63, |
| 227 |
Minus = 64, |
| 228 |
DownLeftArrow = 65, |
| 229 |
DialLeft = 66, |
| 230 |
DialRight = 67, |
| 231 |
Suspension = 68 |
| 232 |
}; |
| 233 |
|
| 234 |
[contract(Windows.Foundation.UniversalApiContract, 4.0)] |
| 235 |
enum GameControllerSwitchKind |
| 236 |
{ |
| 237 |
TwoWay = 0, |
| 238 |
FourWay = 1, |
| 239 |
EightWay = 2 |
| 240 |
}; |
| 241 |
|
| 242 |
[contract(Windows.Foundation.UniversalApiContract, 4.0)] |
| 243 |
enum GameControllerSwitchPosition |
| 244 |
{ |
| 245 |
Center = 0, |
| 246 |
Up = 1, |
| 247 |
UpRight = 2, |
| 248 |
Right = 3, |
| 249 |
DownRight = 4, |
| 250 |
Down = 5, |
| 251 |
DownLeft = 6, |
| 252 |
Left = 7, |
| 253 |
UpLeft = 8 |
| 254 |
}; |
| 255 |
|
| 256 |
[ |
| 257 |
contract(Windows.Foundation.UniversalApiContract, 3.0), |
| 258 |
flags |
| 259 |
] |
| 260 |
enum RacingWheelButtons |
| 261 |
{ |
| 262 |
None = 0x0, |
| 263 |
PreviousGear = 0x1, |
| 264 |
NextGear = 0x2, |
| 265 |
DPadUp = 0x4, |
| 266 |
DPadDown = 0x8, |
| 267 |
DPadLeft = 0x10, |
| 268 |
DPadRight = 0x20, |
| 269 |
Button1 = 0x40, |
| 270 |
Button2 = 0x80, |
| 271 |
Button3 = 0x100, |
| 272 |
Button4 = 0x200, |
| 273 |
Button5 = 0x400, |
| 274 |
Button6 = 0x800, |
| 275 |
Button7 = 0x1000, |
| 276 |
Button8 = 0x2000, |
| 277 |
Button9 = 0x4000, |
| 278 |
Button10 = 0x8000, |
| 279 |
Button11 = 0x10000, |
| 280 |
Button12 = 0x20000, |
| 281 |
Button13 = 0x40000, |
| 282 |
Button14 = 0x80000, |
| 283 |
Button15 = 0x100000, |
| 284 |
Button16 = 0x200000, |
| 285 |
}; |
| 286 |
|
| 287 |
[contract(Windows.Foundation.UniversalApiContract, 3.0)] |
| 288 |
struct ArcadeStickReading |
| 289 |
{ |
| 290 |
UINT64 Timestamp; |
| 291 |
Windows.Gaming.Input.ArcadeStickButtons Buttons; |
| 292 |
}; |
| 293 |
|
| 294 |
[contract(Windows.Foundation.UniversalApiContract, 4.0)] |
| 295 |
struct FlightStickReading |
| 296 |
{ |
| 297 |
UINT64 Timestamp; |
| 298 |
Windows.Gaming.Input.FlightStickButtons Buttons; |
| 299 |
Windows.Gaming.Input.GameControllerSwitchPosition HatSwitch; |
| 300 |
DOUBLE Roll; |
| 301 |
DOUBLE Pitch; |
| 302 |
DOUBLE Yaw; |
| 303 |
DOUBLE Throttle; |
| 304 |
}; |
| 305 |
|
| 306 |
[contract(Windows.Foundation.UniversalApiContract, 1.0)] |
| 307 |
struct GamepadReading |
| 308 |
{ |
| 309 |
UINT64 Timestamp; |
| 310 |
Windows.Gaming.Input.GamepadButtons Buttons; |
| 311 |
DOUBLE LeftTrigger; |
| 312 |
DOUBLE RightTrigger; |
| 313 |
DOUBLE LeftThumbstickX; |
| 314 |
DOUBLE LeftThumbstickY; |
| 315 |
DOUBLE RightThumbstickX; |
| 316 |
DOUBLE RightThumbstickY; |
| 317 |
}; |
| 318 |
|
| 319 |
[contract(Windows.Foundation.UniversalApiContract, 1.0)] |
| 320 |
struct GamepadVibration |
| 321 |
{ |
| 322 |
DOUBLE LeftMotor; |
| 323 |
DOUBLE RightMotor; |
| 324 |
DOUBLE LeftTrigger; |
| 325 |
DOUBLE RightTrigger; |
| 326 |
}; |
| 327 |
|
| 328 |
[contract(Windows.Foundation.UniversalApiContract, 3.0)] |
| 329 |
struct RacingWheelReading |
| 330 |
{ |
| 331 |
UINT64 Timestamp; |
| 332 |
Windows.Gaming.Input.RacingWheelButtons Buttons; |
| 333 |
INT32 PatternShifterGear; |
| 334 |
DOUBLE Wheel; |
| 335 |
DOUBLE Throttle; |
| 336 |
DOUBLE Brake; |
| 337 |
DOUBLE Clutch; |
| 338 |
DOUBLE Handbrake; |
| 339 |
}; |
| 340 |
|
| 341 |
[ |
| 342 |
contract(Windows.Foundation.UniversalApiContract, 3.0), |
| 343 |
exclusiveto(Windows.Gaming.Input.ArcadeStick), |
| 344 |
uuid(b14a539d-befb-4c81-8051-15ecf3b13036) |
| 345 |
] |
| 346 |
interface IArcadeStick : IInspectable |
| 347 |
requires Windows.Gaming.Input.IGameController |
| 348 |
{ |
| 349 |
HRESULT GetButtonLabel([in] Windows.Gaming.Input.ArcadeStickButtons button, |
| 350 |
[out, retval] Windows.Gaming.Input.GameControllerButtonLabel *value); |
| 351 |
HRESULT GetCurrentReading([out, retval] Windows.Gaming.Input.ArcadeStickReading *value); |
| 352 |
} |
| 353 |
|
| 354 |
[ |
| 355 |
contract(Windows.Foundation.UniversalApiContract, 3.0), |
| 356 |
exclusiveto(Windows.Gaming.Input.ArcadeStick), |
| 357 |
uuid(5c37b8c8-37b1-4ad8-9458-200f1a30018e) |
| 358 |
] |
| 359 |
interface IArcadeStickStatics : IInspectable |
| 360 |
{ |
| 361 |
[eventadd] HRESULT ArcadeStickAdded([in] Windows.Foundation.EventHandler<Windows.Gaming.Input.ArcadeStick *> *value, |
| 362 |
[out, retval] EventRegistrationToken *token); |
| 363 |
[eventremove] HRESULT ArcadeStickAdded([in] EventRegistrationToken token); |
| 364 |
[eventadd] HRESULT ArcadeStickRemoved([in] Windows.Foundation.EventHandler<Windows.Gaming.Input.ArcadeStick *> *value, |
| 365 |
[out, retval] EventRegistrationToken *token); |
| 366 |
[eventremove] HRESULT ArcadeStickRemoved([in] EventRegistrationToken token); |
| 367 |
[propget] HRESULT ArcadeSticks([out, retval] Windows.Foundation.Collections.IVectorView<Windows.Gaming.Input.ArcadeStick *> **value); |
| 368 |
} |
| 369 |
|
| 370 |
[ |
| 371 |
contract(Windows.Foundation.UniversalApiContract, 4.0), |
| 372 |
exclusiveto(Windows.Gaming.Input.ArcadeStick), |
| 373 |
uuid(52b5d744-bb86-445a-b59c-596f0e2a49df) |
| 374 |
] |
| 375 |
interface IArcadeStickStatics2 : IInspectable |
| 376 |
requires Windows.Gaming.Input.IArcadeStickStatics |
| 377 |
{ |
| 378 |
HRESULT FromGameController([in] Windows.Gaming.Input.IGameController *controller, |
| 379 |
[out, retval] Windows.Gaming.Input.ArcadeStick **value); |
| 380 |
} |
| 381 |
|
| 382 |
[ |
| 383 |
contract(Windows.Foundation.UniversalApiContract, 4.0), |
| 384 |
exclusiveto(Windows.Gaming.Input.FlightStick), |
| 385 |
uuid(b4a2c01c-b83b-4459-a1a9-97b03c33da7c) |
| 386 |
] |
| 387 |
interface IFlightStick : IInspectable |
| 388 |
requires Windows.Gaming.Input.IGameController |
| 389 |
{ |
| 390 |
[propget] HRESULT HatSwitchKind([out, retval] Windows.Gaming.Input.GameControllerSwitchKind *value); |
| 391 |
HRESULT GetButtonLabel([in] Windows.Gaming.Input.FlightStickButtons button, |
| 392 |
[out, retval] Windows.Gaming.Input.GameControllerButtonLabel *value); |
| 393 |
HRESULT GetCurrentReading([out, retval] Windows.Gaming.Input.FlightStickReading *value); |
| 394 |
} |
| 395 |
|
| 396 |
[ |
| 397 |
contract(Windows.Foundation.UniversalApiContract, 4.0), |
| 398 |
exclusiveto(Windows.Gaming.Input.FlightStick), |
| 399 |
uuid(5514924a-fecc-435e-83dc-5cec8a18a520) |
| 400 |
] |
| 401 |
interface IFlightStickStatics : IInspectable |
| 402 |
{ |
| 403 |
[eventadd] HRESULT FlightStickAdded([in] Windows.Foundation.EventHandler<Windows.Gaming.Input.FlightStick *> *value, |
| 404 |
[out, retval] EventRegistrationToken *token); |
| 405 |
[eventremove] HRESULT FlightStickAdded([in] EventRegistrationToken token); |
| 406 |
[eventadd] HRESULT FlightStickRemoved([in] Windows.Foundation.EventHandler<Windows.Gaming.Input.FlightStick *> *value, |
| 407 |
[out, retval] EventRegistrationToken *token); |
| 408 |
[eventremove] HRESULT FlightStickRemoved([in] EventRegistrationToken token); |
| 409 |
[propget] HRESULT FlightSticks([out, retval] Windows.Foundation.Collections.IVectorView<Windows.Gaming.Input.FlightStick *> **value); |
| 410 |
HRESULT FromGameController([in] Windows.Gaming.Input.IGameController *controller, |
| 411 |
[out, retval] Windows.Gaming.Input.FlightStick **value); |
| 412 |
} |
| 413 |
|
| 414 |
[ |
| 415 |
contract(Windows.Foundation.UniversalApiContract, 1.0), |
| 416 |
uuid(1baf6522-5f64-42c5-8267-b9fe2215bfbd) |
| 417 |
] |
| 418 |
interface IGameController : IInspectable |
| 419 |
{ |
| 420 |
[eventadd] HRESULT HeadsetConnected([in] Windows.Foundation.TypedEventHandler<Windows.Gaming.Input.IGameController *, Windows.Gaming.Input.Headset *> *handler, |
| 421 |
[out, retval] EventRegistrationToken *token); |
| 422 |
[eventremove] HRESULT HeadsetConnected([in] EventRegistrationToken token); |
| 423 |
[eventadd] HRESULT HeadsetDisconnected([in] Windows.Foundation.TypedEventHandler<Windows.Gaming.Input.IGameController *, Windows.Gaming.Input.Headset *> *handler, |
| 424 |
[out, retval] EventRegistrationToken *token); |
| 425 |
[eventremove] HRESULT HeadsetDisconnected([in] EventRegistrationToken token); |
| 426 |
[eventadd] HRESULT UserChanged([in] Windows.Foundation.TypedEventHandler<Windows.Gaming.Input.IGameController *, Windows.System.UserChangedEventArgs *> *handler, |
| 427 |
[out, retval] EventRegistrationToken *token); |
| 428 |
[eventremove] HRESULT UserChanged([in] EventRegistrationToken token); |
| 429 |
[propget] HRESULT Headset([out, retval] Windows.Gaming.Input.Headset **value); |
| 430 |
[propget] HRESULT IsWireless([out, retval] boolean *value); |
| 431 |
[propget] HRESULT User([out, retval] Windows.System.User **value); |
| 432 |
} |
| 433 |
|
| 434 |
[ |
| 435 |
contract(Windows.Foundation.UniversalApiContract, 1.0), |
| 436 |
exclusiveto(Windows.Gaming.Input.Gamepad), |
| 437 |
uuid(bc7bb43c-0a69-3903-9e9d-a50f86a45de5) |
| 438 |
] |
| 439 |
interface IGamepad : IInspectable |
| 440 |
requires Windows.Gaming.Input.IGameController |
| 441 |
{ |
| 442 |
[propget] HRESULT Vibration([out, retval] Windows.Gaming.Input.GamepadVibration *value); |
| 443 |
[propput] HRESULT Vibration([in] Windows.Gaming.Input.GamepadVibration value); |
| 444 |
HRESULT GetCurrentReading([out, retval] Windows.Gaming.Input.GamepadReading *value); |
| 445 |
} |
| 446 |
|
| 447 |
[ |
| 448 |
contract(Windows.Foundation.UniversalApiContract, 3.0), |
| 449 |
exclusiveto(Windows.Gaming.Input.Gamepad), |
| 450 |
uuid(3c1689bd-5915-4245-b0c0-c89fae0308ff) |
| 451 |
] |
| 452 |
interface IGamepad2 : IInspectable |
| 453 |
requires Windows.Gaming.Input.IGamepad, |
| 454 |
Windows.Gaming.Input.IGameController |
| 455 |
{ |
| 456 |
HRESULT GetButtonLabel([in] Windows.Gaming.Input.GamepadButtons button, |
| 457 |
[out, retval] Windows.Gaming.Input.GameControllerButtonLabel *value); |
| 458 |
} |
| 459 |
|
| 460 |
[ |
| 461 |
contract(Windows.Foundation.UniversalApiContract, 3.0), |
| 462 |
exclusiveto(Windows.Gaming.Input.RacingWheel), |
| 463 |
uuid(f546656f-e106-4c82-a90f-554012904b85) |
| 464 |
] |
| 465 |
interface IRacingWheel : IInspectable |
| 466 |
requires Windows.Gaming.Input.IGameController |
| 467 |
{ |
| 468 |
[propget] HRESULT HasClutch([out, retval] boolean *value); |
| 469 |
[propget] HRESULT HasHandbrake([out, retval] boolean *value); |
| 470 |
[propget] HRESULT HasPatternShifter([out, retval] boolean *value); |
| 471 |
[propget] HRESULT MaxPatternShifterGear([out, retval] INT32 *value); |
| 472 |
[propget] HRESULT MaxWheelAngle([out, retval] DOUBLE *value); |
| 473 |
[propget] HRESULT WheelMotor([out, retval] Windows.Gaming.Input.ForceFeedback.ForceFeedbackMotor **value); |
| 474 |
HRESULT GetButtonLabel([in] Windows.Gaming.Input.RacingWheelButtons button, [out, retval] Windows.Gaming.Input.GameControllerButtonLabel *value); |
| 475 |
HRESULT GetCurrentReading([out, retval] Windows.Gaming.Input.RacingWheelReading *value); |
| 476 |
} |
| 477 |
|
| 478 |
[ |
| 479 |
contract(Windows.Foundation.UniversalApiContract, 3.0), |
| 480 |
exclusiveto(Windows.Gaming.Input.RacingWheel), |
| 481 |
uuid(3ac12cd5-581b-4936-9f94-69f1e6514c7d) |
| 482 |
] |
| 483 |
interface IRacingWheelStatics : IInspectable |
| 484 |
{ |
| 485 |
[eventadd] HRESULT RacingWheelAdded([in] Windows.Foundation.EventHandler<RacingWheel *> *value, [out, retval] EventRegistrationToken *token); |
| 486 |
[eventremove] HRESULT RacingWheelAdded([in] EventRegistrationToken token); |
| 487 |
[eventadd] HRESULT RacingWheelRemoved([in] Windows.Foundation.EventHandler<RacingWheel *> *value, [out, retval] EventRegistrationToken *token); |
| 488 |
[eventremove] HRESULT RacingWheelRemoved([in] EventRegistrationToken token); |
| 489 |
[propget] HRESULT RacingWheels([out, retval] Windows.Foundation.Collections.IVectorView<RacingWheel *> **value); |
| 490 |
} |
| 491 |
|
| 492 |
[ |
| 493 |
contract(Windows.Foundation.UniversalApiContract, 4.0), |
| 494 |
exclusiveto(Windows.Gaming.Input.RacingWheel), |
| 495 |
uuid(e666bcaa-edfd-4323-a9f6-3c384048d1ed) |
| 496 |
] |
| 497 |
interface IRacingWheelStatics2 : IInspectable |
| 498 |
requires Windows.Gaming.Input.IRacingWheelStatics |
| 499 |
{ |
| 500 |
HRESULT FromGameController([in] Windows.Gaming.Input.IGameController *controller, |
| 501 |
[out, retval] Windows.Gaming.Input.RacingWheel **value); |
| 502 |
} |
| 503 |
|
| 504 |
[ |
| 505 |
contract(Windows.Foundation.UniversalApiContract, 4.0), |
| 506 |
exclusiveto(Windows.Gaming.Input.RawGameController), |
| 507 |
uuid(7cad6d91-a7e1-4f71-9a78-33e9c5dfea62) |
| 508 |
] |
| 509 |
interface IRawGameController : IInspectable |
| 510 |
requires Windows.Gaming.Input.IGameController |
| 511 |
{ |
| 512 |
[propget] HRESULT AxisCount([out, retval] INT32 *value); |
| 513 |
[propget] HRESULT ButtonCount([out, retval] INT32 *value); |
| 514 |
[propget] HRESULT ForceFeedbackMotors([out, retval] Windows.Foundation.Collections.IVectorView<Windows.Gaming.Input.ForceFeedback.ForceFeedbackMotor *> **value); |
| 515 |
[propget] HRESULT HardwareProductId([out, retval] UINT16 *value); |
| 516 |
[propget] HRESULT HardwareVendorId([out, retval] UINT16 *value); |
| 517 |
[propget] HRESULT SwitchCount([out, retval] INT32 *value); |
| 518 |
HRESULT GetButtonLabel([in] INT32 index, [out, retval] Windows.Gaming.Input.GameControllerButtonLabel *value); |
| 519 |
HRESULT GetCurrentReading([in] UINT32 buttons_size, [out, size_is(buttons_size)] boolean *buttons, |
| 520 |
[in] UINT32 switches_size, [out, size_is(switches_size)] Windows.Gaming.Input.GameControllerSwitchPosition *switches, |
| 521 |
[in] UINT32 axes_size, [out, size_is(axes_size)] DOUBLE *axes, |
| 522 |
[out, retval] UINT64 *timestamp); |
| 523 |
HRESULT GetSwitchKind([in] INT32 index, [out, retval] Windows.Gaming.Input.GameControllerSwitchKind *value); |
| 524 |
} |
| 525 |
|
| 526 |
[ |
| 527 |
contract(Windows.Foundation.UniversalApiContract, 5.0), |
| 528 |
exclusiveto(Windows.Gaming.Input.RawGameController), |
| 529 |
uuid(43c0c035-bb73-4756-a787-3ed6bea617bd) |
| 530 |
] |
| 531 |
interface IRawGameController2 : IInspectable |
| 532 |
requires Windows.Gaming.Input.IRawGameController, |
| 533 |
Windows.Gaming.Input.IGameController |
| 534 |
{ |
| 535 |
[propget] HRESULT SimpleHapticsControllers([out, retval] Windows.Foundation.Collections.IVectorView<Windows.Devices.Haptics.SimpleHapticsController *> **value); |
| 536 |
[propget] HRESULT NonRoamableId([out, retval] HSTRING *value); |
| 537 |
[propget] HRESULT DisplayName([out, retval] HSTRING *value); |
| 538 |
} |
| 539 |
|
| 540 |
[ |
| 541 |
object, |
| 542 |
uuid(8bbce529-d49c-39e9-9560-e47dde96b7c8) |
| 543 |
] |
| 544 |
interface IGamepadStatics : IInspectable |
| 545 |
{ |
| 546 |
[eventadd] HRESULT GamepadAdded([in] Windows.Foundation.EventHandler<Gamepad *> *value, [out, retval] EventRegistrationToken *token); |
| 547 |
[eventremove] HRESULT GamepadAdded([in] EventRegistrationToken token); |
| 548 |
[eventadd] HRESULT GamepadRemoved([in] Windows.Foundation.EventHandler<Gamepad *> *value, [out, retval] EventRegistrationToken *token); |
| 549 |
[eventremove] HRESULT GamepadRemoved([in] EventRegistrationToken token); |
| 550 |
[propget] HRESULT Gamepads([out, retval] Windows.Foundation.Collections.IVectorView<Gamepad *> **value); |
| 551 |
} |
| 552 |
|
| 553 |
[ |
| 554 |
contract(Windows.Foundation.UniversalApiContract, 4.0), |
| 555 |
exclusiveto(Windows.Gaming.Input.Gamepad), |
| 556 |
uuid(42676dc5-0856-47c4-9213-b395504c3a3c) |
| 557 |
] |
| 558 |
interface IGamepadStatics2 : IInspectable |
| 559 |
requires Windows.Gaming.Input.IGamepadStatics |
| 560 |
{ |
| 561 |
HRESULT FromGameController([in] Windows.Gaming.Input.IGameController *controller, |
| 562 |
[out, retval] Windows.Gaming.Input.Gamepad **value); |
| 563 |
} |
| 564 |
|
| 565 |
[ |
| 566 |
contract(Windows.Foundation.UniversalApiContract, 1.0), |
| 567 |
exclusiveto(Windows.Gaming.Input.Headset), |
| 568 |
uuid(3fd156ef-6925-3fa8-9181-029c5223ae3b) |
| 569 |
] |
| 570 |
interface IHeadset : IInspectable |
| 571 |
{ |
| 572 |
[propget] HRESULT CaptureDeviceId([out, retval] HSTRING *value); |
| 573 |
[propget] HRESULT RenderDeviceId([out, retval] HSTRING *value); |
| 574 |
} |
| 575 |
|
| 576 |
[ |
| 577 |
object, |
| 578 |
uuid(eb8d0792-e95a-4b19-afc7-0a59f8bf759e) |
| 579 |
] |
| 580 |
interface IRawGameControllerStatics : IInspectable |
| 581 |
{ |
| 582 |
[eventadd] HRESULT RawGameControllerAdded([in] Windows.Foundation.EventHandler<Windows.Gaming.Input.RawGameController *> *handler, |
| 583 |
[out, retval] EventRegistrationToken *token); |
| 584 |
[eventremove] HRESULT RawGameControllerAdded([in] EventRegistrationToken token); |
| 585 |
[eventadd] HRESULT RawGameControllerRemoved([in] Windows.Foundation.EventHandler<Windows.Gaming.Input.RawGameController *> *handler, |
| 586 |
[out, retval] EventRegistrationToken *token); |
| 587 |
[eventremove] HRESULT RawGameControllerRemoved([in] EventRegistrationToken token); |
| 588 |
[propget] HRESULT RawGameControllers([out, retval] Windows.Foundation.Collections.IVectorView<Windows.Gaming.Input.RawGameController *> **value); |
| 589 |
HRESULT FromGameController([in] Windows.Gaming.Input.IGameController *game_controller, [out, retval] Windows.Gaming.Input.RawGameController **value); |
| 590 |
} |
| 591 |
|
| 592 |
[ |
| 593 |
contract(Windows.Foundation.UniversalApiContract, 4.0), |
| 594 |
uuid(dcecc681-3963-4da6-955d-553f3b6f6161) |
| 595 |
] |
| 596 |
interface IGameControllerBatteryInfo : IInspectable |
| 597 |
{ |
| 598 |
HRESULT TryGetBatteryReport([out, retval] Windows.Devices.Power.BatteryReport **value); |
| 599 |
} |
| 600 |
|
| 601 |
[ |
| 602 |
contract(Windows.Foundation.UniversalApiContract, 3.0), |
| 603 |
marshaling_behavior(agile), |
| 604 |
static(Windows.Gaming.Input.IArcadeStickStatics, Windows.Foundation.UniversalApiContract, 3.0), |
| 605 |
static(Windows.Gaming.Input.IArcadeStickStatics2, Windows.Foundation.UniversalApiContract, 4.0), |
| 606 |
threading(both) |
| 607 |
] |
| 608 |
runtimeclass ArcadeStick |
| 609 |
{ |
| 610 |
[default] interface Windows.Gaming.Input.IArcadeStick; |
| 611 |
interface Windows.Gaming.Input.IGameController; |
| 612 |
[contract(Windows.Foundation.UniversalApiContract, 4.0)] interface Windows.Gaming.Input.IGameControllerBatteryInfo; |
| 613 |
} |
| 614 |
|
| 615 |
[ |
| 616 |
contract(Windows.Foundation.UniversalApiContract, 4.0), |
| 617 |
marshaling_behavior(agile), |
| 618 |
static(Windows.Gaming.Input.IFlightStickStatics, Windows.Foundation.UniversalApiContract, 4.0), |
| 619 |
threading(both) |
| 620 |
] |
| 621 |
runtimeclass FlightStick |
| 622 |
{ |
| 623 |
[default] interface Windows.Gaming.Input.IFlightStick; |
| 624 |
interface Windows.Gaming.Input.IGameController; |
| 625 |
interface Windows.Gaming.Input.IGameControllerBatteryInfo; |
| 626 |
} |
| 627 |
|
| 628 |
[ |
| 629 |
contract(Windows.Foundation.UniversalApiContract, 1.0), |
| 630 |
marshaling_behavior(agile), |
| 631 |
static(Windows.Gaming.Input.IGamepadStatics, Windows.Foundation.UniversalApiContract, 1.0), |
| 632 |
static(Windows.Gaming.Input.IGamepadStatics2, Windows.Foundation.UniversalApiContract, 4.0), |
| 633 |
threading(both) |
| 634 |
] |
| 635 |
runtimeclass Gamepad |
| 636 |
{ |
| 637 |
[default] interface Windows.Gaming.Input.IGamepad; |
| 638 |
interface Windows.Gaming.Input.IGameController; |
| 639 |
[contract(Windows.Foundation.UniversalApiContract, 3.0)] interface Windows.Gaming.Input.IGamepad2; |
| 640 |
[contract(Windows.Foundation.UniversalApiContract, 4.0)] interface Windows.Gaming.Input.IGameControllerBatteryInfo; |
| 641 |
} |
| 642 |
|
| 643 |
[ |
| 644 |
contract(Windows.Foundation.UniversalApiContract, 1.0), |
| 645 |
marshaling_behavior(agile), |
| 646 |
threading(both) |
| 647 |
] |
| 648 |
runtimeclass Headset |
| 649 |
{ |
| 650 |
[default] interface Windows.Gaming.Input.IHeadset; |
| 651 |
[contract(Windows.Foundation.UniversalApiContract, 4.0)] interface Windows.Gaming.Input.IGameControllerBatteryInfo; |
| 652 |
} |
| 653 |
|
| 654 |
[ |
| 655 |
contract(Windows.Foundation.UniversalApiContract, 3.0), |
| 656 |
marshaling_behavior(agile), |
| 657 |
static(Windows.Gaming.Input.IRacingWheelStatics, Windows.Foundation.UniversalApiContract, 3.0), |
| 658 |
static(Windows.Gaming.Input.IRacingWheelStatics2, Windows.Foundation.UniversalApiContract, 4.0), |
| 659 |
threading(both) |
| 660 |
] |
| 661 |
runtimeclass RacingWheel |
| 662 |
{ |
| 663 |
[default] interface Windows.Gaming.Input.IRacingWheel; |
| 664 |
interface Windows.Gaming.Input.IGameController; |
| 665 |
[contract(Windows.Foundation.UniversalApiContract, 4.0)] interface Windows.Gaming.Input.IGameControllerBatteryInfo; |
| 666 |
} |
| 667 |
|
| 668 |
[ |
| 669 |
contract(Windows.Foundation.UniversalApiContract, 4.0), |
| 670 |
marshaling_behavior(agile), |
| 671 |
static(Windows.Gaming.Input.IRawGameControllerStatics, Windows.Foundation.UniversalApiContract, 4.0), |
| 672 |
threading(both) |
| 673 |
] |
| 674 |
runtimeclass RawGameController |
| 675 |
{ |
| 676 |
[default] interface Windows.Gaming.Input.IRawGameController; |
| 677 |
interface Windows.Gaming.Input.IGameController; |
| 678 |
interface Windows.Gaming.Input.IGameControllerBatteryInfo; |
| 679 |
[contract(Windows.Foundation.UniversalApiContract, 5.0)] interface Windows.Gaming.Input.IRawGameController2; |
| 680 |
} |
| 681 |
} |