|
@@ -120,14 +120,6 @@ e.g.
|
|
|
Note that if you are using main callbacks instead of a standard C main() function, your SDL_AppEvent() callback will run as these events arrive and you do not need to use SDL_SetEventFilter.
|
|
|
|
|
|
|
|
|
-Notes -- Accelerometer as Joystick
|
|
|
-==============================================================================
|
|
|
-
|
|
|
-SDL for iPhone supports polling the built in accelerometer as a joystick device. For an example on how to do this, see the accelerometer.c in the demos directory.
|
|
|
-
|
|
|
-The main thing to note when using the accelerometer with SDL is that while the iPhone natively reports accelerometer as floating point values in units of g-force, SDL_GetJoystickAxis() reports joystick values as signed integers. Hence, in order to convert between the two, some clamping and scaling is necessary on the part of the iPhone SDL joystick driver. To convert SDL_GetJoystickAxis() reported values BACK to units of g-force, simply multiply the values by SDL_IPHONE_MAX_GFORCE / 0x7FFF.
|
|
|
-
|
|
|
-
|
|
|
Notes -- Keyboard
|
|
|
==============================================================================
|
|
|
|