RetroArch
GCExtendedGamepadSnapshot.h
Go to the documentation of this file.
1 //
2 // GCExtendedGamepadSnapshot.h
3 // GameController
4 //
5 // Copyright (c) 2012 Apple Inc. All rights reserved.
6 //
7 
8 #import "GameController.h"
9 
23 @property (copy) NSData *snapshotData;
24 
25 - (instancetype)initWithSnapshotData:(NSData *)data;
26 - (instancetype)initWithController:(GCController *)controller snapshotData:(NSData *)data;
27 
28 @end
29 
30 #pragma pack(push, 1)
31 typedef struct {
32  // Standard information
33  uint16_t version; //0x0100
34  uint16_t size; //sizeof(GCExtendedGamepadSnapShotDataV100) or larger
35 
36  // Extended gamepad data
37  // Axes in the range [-1.0, 1.0]
38  float_t dpadX;
39  float_t dpadY;
40 
41  // Buttons in the range [0.0, 1.0]
42  float_t buttonA;
43  float_t buttonB;
44  float_t buttonX;
45  float_t buttonY;
46  float_t leftShoulder;
47  float_t rightShoulder;
48 
49  // Axes in the range [-1.0, 1.0]
50  float_t leftThumbstickX;
51  float_t leftThumbstickY;
54 
55  // Buttons in the range [0.0, 1.0]
56  float_t leftTrigger;
57  float_t rightTrigger;
58 
60 #pragma pack(pop)
61 
68 
float_t dpadY
Definition: GCExtendedGamepadSnapshot.h:39
float_t leftThumbstickX
Definition: GCExtendedGamepadSnapshot.h:50
uint16_t size
Definition: GCExtendedGamepadSnapshot.h:34
float_t leftThumbstickY
Definition: GCExtendedGamepadSnapshot.h:51
float_t buttonA
Definition: GCExtendedGamepadSnapshot.h:42
Definition: ibxm.h:9
GCController * controller
Definition: GCExtendedGamepad.h:31
GLsizei GLsizei GLenum GLenum const GLvoid * data
Definition: glext.h:6303
#define GAMECONTROLLER_EXPORT
Definition: GameController.h:18
float_t buttonX
Definition: GCExtendedGamepadSnapshot.h:44
float_t rightThumbstickX
Definition: GCExtendedGamepadSnapshot.h:52
GAMECONTROLLER_EXPORT BOOL GCExtendedGamepadSnapShotDataV100FromNSData(GCExtendedGamepadSnapShotDataV100 *snapshotData, NSData *data)
Definition: GCExtendedGamepadSnapshot.h:22
Definition: GCController.h:56
float_t buttonY
Definition: GCExtendedGamepadSnapshot.h:45
Definition: GCExtendedGamepad.h:25
GAMECONTROLLER_EXPORT NSData * NSDataFromGCExtendedGamepadSnapShotDataV100(GCExtendedGamepadSnapShotDataV100 *snapshotData)
NSData * snapshotData
Definition: GCExtendedGamepadSnapshot.h:23
unsigned int BOOL
Definition: gctypes.h:51
Definition: GCExtendedGamepadSnapshot.h:31
float_t leftTrigger
Definition: GCExtendedGamepadSnapshot.h:56
float_t dpadX
Definition: GCExtendedGamepadSnapshot.h:38
float_t buttonB
Definition: GCExtendedGamepadSnapshot.h:43
uint16_t version
Definition: GCExtendedGamepadSnapshot.h:33
float_t leftShoulder
Definition: GCExtendedGamepadSnapshot.h:46
float_t rightShoulder
Definition: GCExtendedGamepadSnapshot.h:47
unsigned short uint16_t
Definition: stdint.h:125
float_t rightTrigger
Definition: GCExtendedGamepadSnapshot.h:57
float_t rightThumbstickY
Definition: GCExtendedGamepadSnapshot.h:53