On Thu, Mar 03, 2011 at 01:35:20PM +1000, Peter Hutterer wrote: > I'm trying to make sense of the suppress handling in the code and it's > confusing me. > > In wcmEvent() we call wcmCheckSuppress() which compares old and new state > against the suppress value and then returns: > 0 if the event is to be discarded > 1 if there was some state change > 2 if there was only motion state change above the suppress limit but nothing > else changed > > In the case of 0, we just return from wcmEvent. > Otherwise, we pass this into commonDispatchDevice(): > - if suppress is 1, we reset x/y to oldx/oldy and continue processing (but > obviously skipping motion). > - if suppress is 2, we ignore the data and don't send an event > > which suggests that for high values of suppress, we either won't get > any relative motion events or we simply won't get any events. The commit > history isn't really telling and doesn't give a reason why this is there. > > so, what again are we actually trying to do?
nevermind, of course 30 sec after sending this it suddenly made sense. the code in commonDispatchDevice is in if (delta < 1) condition and thus if we have movement of less than one device coordinate and no other data, we can just exit early and ignore the rest of the event processing. Cheers, Peter ------------------------------------------------------------------------------ Free Software Download: Index, Search & Analyze Logs and other IT data in Real-Time with Splunk. Collect, index and harness all the fast moving IT data generated by your applications, servers and devices whether physical, virtual or in the cloud. Deliver compliance at lower cost and gain new business insights. http://p.sf.net/sfu/splunk-dev2dev _______________________________________________ Linuxwacom-devel mailing list Linuxwacom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel