arch/sdl/include/joy.h File Reference

#include "types.h"
#include "fix.h"

Classes

struct  joystick_device
struct  joystick_axis
struct  joystick_button

Defines

#define MAX_JOY_DEVS   8
#define JOY_1_BUTTON_A   1
#define JOY_1_BUTTON_B   2
#define JOY_2_BUTTON_A   4
#define JOY_2_BUTTON_B   8
#define JOY_ALL_BUTTONS   (1+2+4+8)
#define JOY_1_X_AXIS   1
#define JOY_1_Y_AXIS   2
#define JOY_2_X_AXIS   4
#define JOY_2_Y_AXIS   8
#define JOY_ALL_AXIS   (1+2+4+8)
#define JOY_SLOW_READINGS   1
#define JOY_POLLED_READINGS   2
#define JOY_BIOS_READINGS   4
#define JOY_FRIENDLY_READINGS   8
#define JOY_MAX_AXES   32
#define JOY_MAX_BUTTONS   64
#define JOY_NUM_AXES   4

Functions

int joy_init ()
void joy_close ()
void joy_set_cen ()
void joy_get_pos (int *x, int *y)
int joy_get_btns ()
int joy_get_button_up_cnt (int btn)
int joy_get_button_down_cnt (int btn)
fix joy_get_button_down_time (int btn)
int j_Update_state ()
int j_Get_joydev_axis_number (int all_axis_number)
int j_Get_joydev_button_number (int all_button_number)
ubyte joystick_read_raw_axis (ubyte mask, int *axis)
void joy_flush ()
ubyte joy_get_present_mask ()
void joy_set_timer_rate (int max_value)
int joy_get_timer_rate ()
int joy_get_button_state (int btn)
void joy_get_cal_vals (int *axis_min, int *axis_center, int *axis_max)
void joy_set_cal_vals (int *axis_min, int *axis_center, int *axis_max)
int joy_get_scaled_reading (int raw, int axn)
void joy_set_slow_reading (int flag)
void joy_set_min (int axis_number, int value)
void joy_set_center (int axis_number, int value)
void joy_set_max (int axis_number, int value)

Variables

char joy_installed
char joy_present
int j_num_axes
int j_num_buttons
int joy_deadzone
joystick_device j_joystick [MAX_JOY_DEVS]
joystick_axis j_axis [JOY_MAX_AXES]
joystick_button j_button [JOY_MAX_BUTTONS]

Define Documentation

#define JOY_1_BUTTON_A   1
 

#define JOY_1_BUTTON_B   2
 

#define JOY_1_X_AXIS   1
 

#define JOY_1_Y_AXIS   2
 

#define JOY_2_BUTTON_A   4
 

#define JOY_2_BUTTON_B   8
 

#define JOY_2_X_AXIS   4
 

#define JOY_2_Y_AXIS   8
 

#define JOY_ALL_AXIS   (1+2+4+8)
 

#define JOY_ALL_BUTTONS   (1+2+4+8)
 

#define JOY_BIOS_READINGS   4
 

#define JOY_FRIENDLY_READINGS   8
 

#define JOY_MAX_AXES   32
 

#define JOY_MAX_BUTTONS   64
 

#define JOY_NUM_AXES   4
 

#define JOY_POLLED_READINGS   2
 

#define JOY_SLOW_READINGS   1
 

#define MAX_JOY_DEVS   8
 


Function Documentation

int j_Get_joydev_axis_number int  all_axis_number  ) 
 

int j_Get_joydev_button_number int  all_button_number  ) 
 

int j_Update_state  ) 
 

void joy_close  ) 
 

void joy_flush  ) 
 

int joy_get_btns  ) 
 

int joy_get_button_down_cnt int  btn  ) 
 

fix joy_get_button_down_time int  btn  ) 
 

int joy_get_button_state int  btn  ) 
 

int joy_get_button_up_cnt int  btn  ) 
 

void joy_get_cal_vals int *  axis_min,
int *  axis_center,
int *  axis_max
 

void joy_get_pos int *  x,
int *  y
 

ubyte joy_get_present_mask  ) 
 

int joy_get_scaled_reading int  raw,
int  axn
 

int joy_get_timer_rate  ) 
 

int joy_init  ) 
 

void joy_set_cal_vals int *  axis_min,
int *  axis_center,
int *  axis_max
 

void joy_set_cen  ) 
 

void joy_set_center int  axis_number,
int  value
 

void joy_set_max int  axis_number,
int  value
 

void joy_set_min int  axis_number,
int  value
 

void joy_set_slow_reading int  flag  ) 
 

void joy_set_timer_rate int  max_value  ) 
 

ubyte joystick_read_raw_axis ubyte  mask,
int *  axis
 


Variable Documentation

joystick_axis j_axis[JOY_MAX_AXES]
 

joystick_button j_button[JOY_MAX_BUTTONS]
 

joystick_device j_joystick[MAX_JOY_DEVS]
 

int j_num_axes
 

int j_num_buttons
 

int joy_deadzone
 

char joy_installed
 

char joy_present
 


Generated on Mon Aug 28 20:55:29 2006 for D1X-Rebirth by  doxygen 1.4.6