On Wed, Oct 26, 2016 at 11:56:57PM -0700, Ping Cheng wrote: > On Wednesday, October 26, 2016, Peter Hutterer <peter.hutte...@who-t.net> > wrote: > > > On Wed, Oct 26, 2016 at 06:24:48PM -0700, Ping Cheng wrote: > > > On Fri, Oct 7, 2016 at 10:25 AM, Jason Gerecke <killert...@gmail.com > > <javascript:;>> wrote: > > > > The driver has historically normalized the pressure range of all kernel > > > > devices to 0..2047 rather than using their native range to keep things > > > > like the application of the pressure curve simple. Pens that report > > more > > > > than 2048 pressure levels are also normalized down to this range > > though, > > > > reducing their precision. In order to accomodate the new 8K pen (and > > any > > > > future pens with even higher precision), this patch bumps up the full- > > > > scale range to be 0..65535. This number was chosen both because it far > > > > exceeds anything currently known about, and also because it matches the > > > > normalization range used over the wire by the Wayland tablet protocol. > > > > > > > > Note that the WACOM_PROP_PRESSURE_THRESHOLD value has been tied to the > > > > normalized (2048-level) pressure range for some time, meaning that we > > > > cannot simply change the range without causing a change in the > > perceived > > > > threshold for users. To ensure compatibility, the value is interpreted > > > > as a fraction of 2048 and then scaled to the actual normalization > > range. > > > > > > > > Signed-off-by: Jason Gerecke <jason.gere...@wacom.com <javascript:;>> > > > > > > Reviewed-by: Ping Cheng <pi...@wacom.com <javascript:;>> for the set of > > 2 patches. > > > > > > Thank you for considering backward compatibility. That's a bonus for > > > many system admins who use xsetwacom/xinput to configure the driver. > > > > > > Please update this patch as Peter suggested though. > > > > uhm, just something else I noticed. we precalculate the pressure curve, so > > we now have 256 KB in the driver allocated just for the values. We should > > probably split this out to be allocated on demand > > > How do you plan to make it on demand? Will it add a new API?
Changing pPressCurve[FILTER_PRESSURE_RES + 1] to a dynamically allocated memory should be enough, no new API is needed, this is just an implementation detail. Cheers, Peter ------------------------------------------------------------------------------ The Command Line: Reinvented for Modern Developers Did the resurgence of CLI tooling catch you by surprise? Reconnect with the command line and become more productive. Learn the new .NET and ASP.NET CLI. Get your free copy! http://sdm.link/telerik _______________________________________________ Linuxwacom-devel mailing list Linuxwacom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel