Mount Fuji Engine  0.8b
Enumerations | Functions
Input Functions

Enumerations

enum  MFInputDevice {
  IDD_Gamepad, IDD_Mouse, IDD_Keyboard, IDD_Accelerometer,
  IDD_TouchPanel, IDD_Max, IDD_ForceInt = 0x7FFFFFFF
}
 Input devices. More...
 
enum  MFInputDeviceStatus {
  IDS_Unavailable = 0, IDS_Ready = 1, IDS_Disconnected, IDS_Waiting,
  IDS_Max, IDS_ForceInt = 0x7FFFFFFF
}
 Input device status. More...
 
enum  MFGamepadFlags
 Gamepad Flags. More...
 
enum  MFGamepadButton {
  Button_P2_Cross = 0, Button_P2_Circle = 1, Button_P2_Box = 2, Button_P2_Triangle = 3,
  Button_P2_L1 = 4, Button_P2_R1 = 5, Button_P2_L2 = 6, Button_P2_R2 = 7,
  Button_P2_Start = 8, Button_P2_Select = 9, Button_P2_L3 = 10, Button_P2_R3 = 11,
  Button_PP_Cross = 0, Button_PP_Circle = 1, Button_PP_Box = 2, Button_PP_Triangle = 3,
  Button_PP_L = 6, Button_PP_R = 7, Button_PP_Start = 8, Button_PP_Select = 9,
  Button_XB_A = 0, Button_XB_B = 1, Button_XB_X = 2, Button_XB_Y = 3,
  Button_XB_White = 4, Button_XB_Black = 5, Button_XB_LTrig = 6, Button_XB_RTrig = 7,
  Button_XB_Start = 8, Button_XB_Back = 9, Button_XB_LThumb = 10, Button_XB_RThumb = 11,
  Button_X3_A = 0, Button_X3_B = 1, Button_X3_X = 2, Button_X3_Y = 3,
  Button_X3_LB = 4, Button_X3_RB = 5, Button_X3_LT = 6, Button_X3_RT = 7,
  Button_X3_Start = 8, Button_X3_Back = 9, Button_X3_LThumb = 10, Button_X3_RThumb = 11,
  Button_GC_A = 0, Button_GC_X = 1, Button_GC_B = 2, Button_GC_Y = 3,
  Button_GC_Z = 5, Button_GC_L = 6, Button_GC_R = 7, Button_GC_Start = 8,
  Button_DC_A = 0, Button_DC_B = 1, Button_DC_X = 2, Button_DC_Y = 3,
  Button_DC_L = 6, Button_DC_R = 7, Button_DC_Start = 8, Button_DUp = 12,
  Button_DDown, Button_DLeft, Button_DRight, Axis_LX = 16,
  Axis_LY, Axis_RX, Axis_RY , GamepadType_Max,
  GamepadType_ForceInt = 0x7FFFFFFF, Button_GH_Green = Button_P2_R2, Button_GH_Red = Button_P2_Circle, Button_GH_Yellow = Button_P2_Triangle,
  Button_GH_Blue = Button_P2_Cross, Button_GH_Orange = Button_P2_Box, Button_GH_Start = Button_P2_Start, Button_GH_Select = Button_P2_Select,
  Button_GH_Solo = Button_P2_L1, Button_GH_TiltTrigger = Button_P2_L2, Button_GH_StrumDown = Button_DDown, Button_GH_StrumUp = Button_DUp,
  Button_GH_Whammy = Axis_LX, Button_GH_Tilt = Axis_RY, Button_GH_Roll = Axis_LY, Button_GH_PickupSwitch = Axis_RX,
  Button_GH_Slider = Axis_RX, Button_Drum_Red = Button_P2_Circle, Button_Drum_Yellow = Button_P2_Triangle, Button_Drum_Blue = Button_P2_Box,
  Button_Drum_Green = Button_P2_Cross, Button_Drum_Kick = Button_P2_L1, Button_Drum_Hat = Button_Drum_Yellow, Button_Drum_Snare = Button_Drum_Red,
  Button_Drum_Tom1 = Button_Drum_Blue, Button_Drum_Tom2 = Button_Drum_Green, Button_Drum_Cymbal = Button_P2_R1, Button_Drum_Start = Button_P2_Start,
  Button_Drum_Select = Button_P2_Select
}
 Enums to access gamepad buttons. More...
 
enum  MFMouseMode { MouseMode_Shared, MouseMode_Exclusive, MouseMode_Max, MouseMode_ForceInt = 0x7FFFFFFF }
 Mouse access modes. More...
 
enum  MFMouseButton {
  Mouse_XPos, Mouse_YPos, Mouse_XDelta, Mouse_YDelta,
  Mouse_Wheel, Mouse_Wheel2, Mouse_MaxAxis, Mouse_LeftButton = Mouse_MaxAxis,
  Mouse_RightButton, Mouse_MiddleButton, Mouse_Extra1, Mouse_Extra2,
  Mouse_Extra3, Mouse_Extra4, Mouse_Extra5, Mouse_Max,
  Mouse_MaxButtons = Mouse_Max - Mouse_LeftButton, Mouse_ForceInt = 0x7FFFFFFF
}
 Enums to access mouse buttons. More...
 
enum  MFKeyboardStatusState {
  KSS_NumLock, KSS_CapsLock, KSS_ScrollLock, KSS_Insert,
  KSS_Max, KSS_ForceInt = 0x7FFFFFFF
}
 Keyboard status flags. More...
 
enum  MFKeyboardButton {
  Key_Unknown = -1, Key_None = 0, Key_Up, Key_Down,
  Key_Left, Key_Right , Key_Max, Key_ForceInt = 0x7FFFFFFF
}
 Keyboard key enums. More...
 
enum  MFAccelerometerInput
 Accelerometer input. More...
 
enum  MFTouchPanelInput
 Touch panel input. More...
 

Functions

MF_API bool MFInput_IsAvailable (int device, int deviceID)
 Tests is an input device is available. More...
 
MF_API bool MFInput_IsConnected (int device, int deviceID)
 Tests is an input device is connected. More...
 
MF_API bool MFInput_IsReady (int device, int deviceID)
 Tests is an input device is ready. More...
 
MF_API float MFInput_Read (int button, int device, int deviceID=0, float *pPrevState=NULL)
 Read input from a device. More...
 
MF_API bool MFInput_WasPressed (int button, int device, int deviceID=0)
 Test if a button was pressed this frame. More...
 
MF_API bool MFInput_WasReleased (int button, int device, int deviceID=0)
 Test if a button was released this frame. More...
 
MF_API uint32 MFInput_GetDeviceFlags (int device, int deviceID=0)
 Get input device flags. More...
 
MF_API int MFInput_GetNumGamepads ()
 Get the number of available gamepads. More...
 
MF_API int MFInput_GetNumKeyboards ()
 Get the number of available keyboards. More...
 
MF_API int MFInput_GetNumPointers ()
 Get the number of available pointers. More...
 
MF_API MFVector MFInput_ReadMousePos (int mouseID=-1)
 Read the absolute position of the mouse pointer. More...
 
MF_API MFVector MFInput_ReadMouseDelta (int mouseID=-1)
 Read the mouse movement delta for this frame. More...
 
MF_API void MFInput_SetMouseMode (int mode)
 Set the mouse access mode. More...
 
MF_API void MFInput_SetMouseAcceleration (float multiplier)
 Set the mouse movement multiplier. More...
 
MF_API void MFInput_SetMouseClippingRect (int mouseID, MFRect *pRect)
 Sets a clipping rect for the mouse pointer. More...
 
MF_API const char * MFInput_EnumerateString (int button, int device, int deviceID=0, bool includeDevice=false, bool includeDeviceID=false)
 Generate a string representing the input button/device configuration. More...
 
MF_API void MFInput_SetDeadZone (float deadZone)
 Set the analog dead zone. More...
 
MF_API float MFInput_GetDeadZone ()
 Get the analog dead zone. More...
 
MF_API const char * MFInput_GetDeviceName (int device, int deviceID)
 Get a device name. More...
 
MF_API const char * MFInput_GetGamepadButtonName (int button, int deviceID)
 Get the button name from a gamepad. More...
 
MF_API bool MFInput_GetKeyboardStatusState (int keyboardState, int keyboardID=-1)
 Get the state of the keyboard status flags. More...
 

Detailed Description