aboutsummaryrefslogtreecommitdiff
path: root/drivers/input/touchscreen/ts_filter_group.h
diff options
context:
space:
mode:
authormerge <null@invalid>2009-01-19 00:47:51 +0000
committerAndy Green <agreen@octopus.localdomain>2009-01-19 00:47:51 +0000
commit3779b1cf0be55e0affcff56379cdfb8a07fdd840 (patch)
treef7b05d2e2188885a37ac3be6fd3c0bf075fe05ac /drivers/input/touchscreen/ts_filter_group.h
parent3a01f98ede89d2d0791393c43625e824f03c3065 (diff)
MERGE-via-pending-tracking-hist-MERGE-via-stable-tracking-fix-touchscreen-filter-include-1232325217
pending-tracking-hist top was MERGE-via-stable-tracking-fix-touchscreen-filter-include-1232325217 / d063e8c6d85c48de80b3d158bfa98d5a97149711 ... parent commitmessage: From: merge <null@invalid> MERGE-via-stable-tracking-hist-fix-touchscreen-filter-include stable-tracking-hist top was fix-touchscreen-filter-include / bb151f28fc8e8923baad96e0f3e8f0ae57af95f5 ... parent commitmessage: From: Nelson Castillo <arhuaco@freaks-unidos.net> Fix touchscreen filter includes Fix #includes to make the kernel compile again. Signed-off-by: Nelson Castillo <arhuaco@freaks-unidos.net>
Diffstat (limited to 'drivers/input/touchscreen/ts_filter_group.h')
-rw-r--r--drivers/input/touchscreen/ts_filter_group.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/drivers/input/touchscreen/ts_filter_group.h b/drivers/input/touchscreen/ts_filter_group.h
new file mode 100644
index 00000000000..c411080eae2
--- /dev/null
+++ b/drivers/input/touchscreen/ts_filter_group.h
@@ -0,0 +1,39 @@
+#ifndef __TS_FILTER_GROUP_H__
+#define __TS_FILTER_GROUP_H__
+
+#include "ts_filter.h"
+
+/*
+ * Touchscreen group filter.
+ *
+ * Copyright (C) 2008 by Openmoko, Inc.
+ * Author: Nelson Castillo <arhuaco@freaks-unidos.net>
+ *
+ */
+
+struct ts_filter_group_configuration {
+ int extent;
+ int close_enough;
+ int threshold;
+ int attempts;
+};
+
+struct ts_filter_group {
+ struct ts_filter tsf;
+ struct ts_filter_group_configuration *config;
+
+ int N; /* How many samples we have */
+ int *samples[MAX_TS_FILTER_COORDS]; /* the samples, our input */
+
+ int *group_size; /* used for temporal computations */
+ int *sorted_samples; /* used for temporal computations */
+
+ int range_max[MAX_TS_FILTER_COORDS]; /* max computed ranges */
+ int range_min[MAX_TS_FILTER_COORDS]; /* min computed ranges */
+
+ int tries_left; /* We finish if we don't get enough samples */
+};
+
+extern struct ts_filter_api ts_filter_group_api;
+
+#endif