summaryrefslogtreecommitdiff
path: root/common/rawaccel-base.hpp
diff options
context:
space:
mode:
authora1xd <[email protected]>2021-03-30 18:27:02 -0400
committera1xd <[email protected]>2021-03-30 18:27:02 -0400
commitfa3ebfb1eb054ba88824a908c996094bb98e85c5 (patch)
treebf52cf6d5de16714dba11e96719ce1434a686779 /common/rawaccel-base.hpp
parentput utility in namespace (diff)
downloadrawaccel-fa3ebfb1eb054ba88824a908c996094bb98e85c5.tar.xz
rawaccel-fa3ebfb1eb054ba88824a908c996094bb98e85c5.zip
refactor lut/motivity
Diffstat (limited to 'common/rawaccel-base.hpp')
-rw-r--r--common/rawaccel-base.hpp21
1 files changed, 20 insertions, 1 deletions
diff --git a/common/rawaccel-base.hpp b/common/rawaccel-base.hpp
index ac60ff0..6996164 100644
--- a/common/rawaccel-base.hpp
+++ b/common/rawaccel-base.hpp
@@ -13,19 +13,38 @@ namespace rawaccel {
inline constexpr size_t MAX_DEV_ID_LEN = 200;
+ inline constexpr size_t LUT_CAPACITY = 1025;
+
enum class accel_mode {
classic,
jump,
natural,
- motivity,
power,
+ motivity,
noaccel
};
+ enum class table_mode {
+ off,
+ binlog,
+ linear
+ };
+
+ struct table_args {
+ table_mode mode = table_mode::off;
+ bool transfer = true;
+ unsigned char partitions = 2;
+ short num_elements = 8;
+ double start = 0;
+ double stop = 8;
+ };
+
struct accel_args {
accel_mode mode = accel_mode::noaccel;
bool legacy = false;
+ table_args lut_args = {};
+
double offset = 0;
double cap = 1.5;
double accel_classic = 0.005;