mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2026-01-05 11:20:19 +01:00
filter: drop an unused function and an unused struct
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
6edf2ed5ee
commit
b64828e79a
2 changed files with 0 additions and 46 deletions
|
|
@ -43,21 +43,6 @@ struct tablet_accelerator_flat {
|
|||
yres_scale; /* 1000dpi : tablet res */
|
||||
};
|
||||
|
||||
struct trackpoint_accelerator {
|
||||
struct motion_filter base;
|
||||
|
||||
struct device_float_coords history[4];
|
||||
size_t history_size;
|
||||
|
||||
double scale_factor;
|
||||
double max_accel;
|
||||
double max_delta;
|
||||
|
||||
double incline; /* incline of the function */
|
||||
double offset; /* offset of the function */
|
||||
};
|
||||
|
||||
|
||||
static inline struct normalized_coords
|
||||
tablet_accelerator_filter_flat_mouse(struct tablet_accelerator_flat *filter,
|
||||
const struct device_float_coords *units)
|
||||
|
|
|
|||
|
|
@ -129,37 +129,6 @@ calculate_acceleration(struct pointer_accelerator_x230 *accel,
|
|||
return factor; /* unitless factor */
|
||||
}
|
||||
|
||||
/**
|
||||
* Calculate the acceleration factor for the given delta with the timestamp.
|
||||
*
|
||||
* @param accel The acceleration filter
|
||||
* @param unaccelerated The raw delta in the device's dpi
|
||||
* @param data Caller-specific data
|
||||
* @param time Current time in µs
|
||||
*
|
||||
* @return A unitless acceleration factor, to be applied to the delta
|
||||
*/
|
||||
static inline double
|
||||
calculate_acceleration_factor(struct pointer_accelerator_x230 *accel,
|
||||
const struct device_float_coords *unaccelerated,
|
||||
void *data,
|
||||
uint64_t time)
|
||||
{
|
||||
double velocity; /* units/us in device-native dpi*/
|
||||
double accel_factor;
|
||||
|
||||
trackers_feed(&accel->trackers, unaccelerated, time);
|
||||
velocity = trackers_velocity(&accel->trackers, time);
|
||||
accel_factor = calculate_acceleration(accel,
|
||||
data,
|
||||
velocity,
|
||||
accel->last_velocity,
|
||||
time);
|
||||
accel->last_velocity = velocity;
|
||||
|
||||
return accel_factor;
|
||||
}
|
||||
|
||||
static struct normalized_coords
|
||||
accelerator_filter_x230(struct motion_filter *filter,
|
||||
const struct device_float_coords *raw,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue