From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chase Douglas Subject: Re: [PATCH 2/6] Input: elantech - use firmware provided x, y ranges Date: Tue, 06 Sep 2011 11:58:30 -0700 Message-ID: <4E666D56.1020009@canonical.com> References: <1313632629-23603-1-git-send-email-jj_ding@emc.com.tw> <1313632629-23603-3-git-send-email-jj_ding@emc.com.tw> <20110818074756.GE10093@core.coreip.homeip.net> <4E5FCE58.9060906@canonical.com> <87sjobk711.fsf@emc.com.tw> <4E665249.2040602@canonical.com> <20110906173649.GA7419@core.coreip.homeip.net> <4E6660D7.9040800@canonical.com> <20110906184735.GA3433@polaris.bitmath.org> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: Received: from youngberry.canonical.com ([91.189.89.112]:49214 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753076Ab1IFS6g (ORCPT ); Tue, 6 Sep 2011 14:58:36 -0400 In-Reply-To: <20110906184735.GA3433@polaris.bitmath.org> Sender: linux-input-owner@vger.kernel.org List-Id: linux-input@vger.kernel.org To: Henrik Rydberg Cc: Dmitry Torokhov , JJ Ding , linux-input@vger.kernel.org, linux-kernel@vger.kernel.org, Seth Forshee , Aaron Huang , Tom Lin , Eric Piel , Daniel Kurtz , Alessandro Rubini On 09/06/2011 11:47 AM, Henrik Rydberg wrote: >>>> I see that the current code scales the coordinates for v2, but it's only >>>> half-resolution. That's not a huge deal since the resolution of modern >>>> touchpads is very high. We could leave it scaled to not break abi, if >>>> that was a concern. However, with new devices it makes sense to state >>>> the ranges in terms of what the device actually supports. Otherwise, >>>> we're just masking out useful data that userspace could be using. >>>> >>> >>> I disagree. I believe that ST and MT ranges reported for the same >>> working surface should match, especially since many devices derive ST >>> data from MT. >>> >>> As far as devices that have ranges 0-15 in MT mode - I am not sure how >>> useful such MT steam anyway and if we are better of just ignore them >>> (maybe just use the data to report number of fingers on the surface but >>> otherwise use standard ST protocol). >> >> The MT data could still be useful for pinch to zoom or potentially >> rotate (though most low res devices probably are only semi-mt). I don't >> want to forsake pinch to zoom just because we can't pass on the >> resolution of MT data properly. > > We are not forsaking anything. At best, the detail missed out by using > the same scaling for ST and MT is the ability to distinguish the axis > with the best or poorest resolution. However, some devices report > higher MT than ST resolution, not because it is better (it is indeed > worse), but simply to not lose bits in the filtering process. In other > words: the logic is not without corner cases, and it only makes a > difference to the transitional devices that are not fully MT > capable. If this really was a concern, userspace could use the ST > coordinates for some transformations instead. So what do we want userspace to do? In the absence of supplying this information we need to provide guidelines. We could say: * Always use ST coords + finger count for drag gestures (i.e. scrolling) * Use MT coords for pinch and rotate If this is acceptable, we should add it to the documentation. Thoughts? -- Chase