Lines Matching refs:axes
128 int axes[4]; member
164 static void analog_decode(struct analog *analog, int *axes, int *initial, int buttons) in analog_decode() argument
171 if (axes[3] < ((initial[3] * ((i << 1) + 1)) >> 3)) { in analog_decode()
185 input_report_key(dev, analog_pads[0], axes[2] < (initial[2] >> 1)); in analog_decode()
187 input_report_key(dev, analog_pads[1], axes[3] < (initial[3] >> 1)); in analog_decode()
189 input_report_key(dev, analog_pads[2], axes[2] > (initial[2] + (initial[2] >> 1))); in analog_decode()
191 input_report_key(dev, analog_pads[3], axes[3] > (initial[3] + (initial[3] >> 1))); in analog_decode()
195 input_report_abs(dev, analog_axes[j++], axes[i]); in analog_decode()
254 port->axes[j] = (DELTA(start, time[i]) << ANALOG_FUZZ_BITS) / port->loop; in analog_cooked_read()
301 port->bads -= gameport_cooked_read(port->gameport, port->axes, &port->buttons); in analog_timer()
319 analog_decode(port->analog + i, port->axes, port->initial, port->buttons); in analog_timer()
438 x = port->axes[i]; in analog_init_device()
439 y = (port->axes[0] + port->axes[1]) >> 1; in analog_init_device()
440 z = y - port->axes[i]; in analog_init_device()
451 if (i == 2) x = port->axes[i]; in analog_init_device()
489 analog_decode(analog, port->axes, port->initial, port->buttons); in analog_init_device()
553 for (i = 0; i < 4; i++) max[i] = port->axes[i] << 1; in analog_init_masks()
561 gameport_calibrate(port->gameport, port->axes, max); in analog_init_masks()
565 port->initial[i] = port->axes[i]; in analog_init_masks()
618 if (!gameport_cooked_read(gameport, port->axes, &port->buttons)) in analog_init_port()
621 if (port->axes[i] != -1) port->mask |= 1 << i; in analog_init_port()