Re: [Linuxwacom-devel] [PATCH v2] make gesture distances be relative to hw maximums.

2011-08-31 Thread Chris Bagwell
On Tue, Aug 30, 2011 at 11:01 PM, Favux ... favux...@gmail.com wrote:
 Hi Chris,

 Testing the tag gesture3 with Natty's 2.6.38.11 kernel's wacom.ko I'd
 say both scroll and zoom responsiveness are improved.

 There's less lag, and while there is still a little pointer jumping
 once you get the feel you can keep it where you want it while
 zooming.

Good to get zooming opinion.  I never used it before so couldn't tell
much if its improved.

Are you seeing pointer jumping during whole time of zoom or only when
initially attempting to zoom?

I still expect it during initial touching.  Right now, it has only a
hard coded 10ms holdoff to prevent movement while its deciding if your
going to put down a second finger or not.  Thats to short and
definitely I see movement during initial touch.  FYI: modify
wcmTouchFilter.c:WACOM_GESTURE_LAG_TIME if you want to play with
better values.

I haven't touched this yet because I'm going to make it a
provisionable SingleTouchTimeout.


 I do have a question about the scroll implementation.  Once the scroll
 gesture is recognized the momentum carries it to the end of the
 contents.  That doesn't seem to be natural to me.  There doesn't
 appear to be a way to stop in a document or thread.  And the speed
 means you had better be a very fast reader.

The only option right now is to modify the Wacom Touch Gesture
Parameters to increase the ScrollDistance.  This will require more
movement to send those scroll button events.. which should have a side
affect of not so many pending events on the queue to process.

If you find a comfortable value, let us know.  Maybe it should become
new default.

Real momentum support doesn't exist in code (not like
xf86-input-synaptics has).  Thats a ways down the road...


 I'll test input-wacom-0.11.1 next.  Do you need the single finger
 patches tested?

Naah... unless you have a ISDV4 tablet PC to test on.


 Favux


--
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free Love Thy Logs t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
___
Linuxwacom-devel mailing list
Linuxwacom-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel


Re: [Linuxwacom-devel] [PATCH v2] make gesture distances be relative to hw maximums.

2011-08-31 Thread Chris Bagwell
On Wed, Aug 31, 2011 at 5:05 PM, Favux ... favux...@gmail.com wrote:
 On Wed, Aug 31, 2011 at 9:45 AM, Chris Bagwell ch...@cnpbagwell.com wrote:
 On Tue, Aug 30, 2011 at 11:01 PM, Favux ... favux...@gmail.com wrote:
 Hi Chris,

 Testing the tag gesture3 with Natty's 2.6.38.11 kernel's wacom.ko I'd
 say both scroll and zoom responsiveness are improved.

 There's less lag, and while there is still a little pointer jumping
 once you get the feel you can keep it where you want it while
 zooming.

 Good to get zooming opinion.  I never used it before so couldn't tell
 much if its improved.

 Are you seeing pointer jumping during whole time of zoom or only when
 initially attempting to zoom?

 Only when initially attempting to zoom.

OK, good.  That part is on my list to fix.


 I still expect it during initial touching.  Right now, it has only a
 hard coded 10ms holdoff to prevent movement while its deciding if your
 going to put down a second finger or not.  Thats to short and
 definitely I see movement during initial touch.  FYI: modify
 wcmTouchFilter.c:WACOM_GESTURE_LAG_TIME if you want to play with
 better values.

 I haven't touched this yet because I'm going to make it a
 provisionable SingleTouchTimeout.


 I do have a question about the scroll implementation.  Once the scroll
 gesture is recognized the momentum carries it to the end of the
 contents.  That doesn't seem to be natural to me.  There doesn't
 appear to be a way to stop in a document or thread.  And the speed
 means you had better be a very fast reader.

 The only option right now is to modify the Wacom Touch Gesture
 Parameters to increase the ScrollDistance.  This will require more
 movement to send those scroll button events.. which should have a side
 affect of not so many pending events on the queue to process.

 If you find a comfortable value, let us know.  Maybe it should become
 new default.

 Using xsetwacom and setting ScrollDistance to 180 (or thereabouts)
 yields the kind of scrolling I would expect.  This is really excellent
 Chris, the best it has been.

Hmm, I'm a little confused on that.  Isn't your original value 600 or
greater than that?

Did lowering the value slow down scrolling, speed it up, or stop some
infinite scrolling?

If it didn't speed it up then there must be some secondary bug I need
to investigate.

Chris

--
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free Love Thy Logs t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
___
Linuxwacom-devel mailing list
Linuxwacom-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel


Re: [Linuxwacom-devel] [PATCH v2] make gesture distances be relative to hw maximums.

2011-08-31 Thread Favux ...
On Wed, Aug 31, 2011 at 8:18 PM, Chris Bagwell ch...@cnpbagwell.com wrote:
 Using xsetwacom and setting ScrollDistance to 180 (or thereabouts)
 yields the kind of scrolling I would expect.  This is really excellent
 Chris, the best it has been.

 Hmm, I'm a little confused on that.  Isn't your original value 600 or
 greater than that?

 Did lowering the value slow down scrolling, speed it up, or stop some
 infinite scrolling?

 If it didn't speed it up then there must be some secondary bug I need
 to investigate.

 Chris


Sorry Chris, my fault.

I forgot I had been doing some testing in my Natty partition.  When I
originally reported that scroll was too fast that was with a
ScrollDistance set near the old default of 20 in my
52-wacom-options.conf in /etc/X11/xorg.conf.d.

With your current patches in gesture3 I get a default of  667.  For my
taste that has the opposite problem in that the scroll is too slow.
So 180 picks it right up.  That may be a little fast and I might
settle on 220 or something.

The upshot is I think you could halve the default.  For me that would
amount to about 330.  That is still a little slow for my taste but I
think it would be a reasonable default for the driver.

Favux

--
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free Love Thy Logs t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
___
Linuxwacom-devel mailing list
Linuxwacom-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel


Re: [Linuxwacom-devel] [PATCH v2] make gesture distances be relative to hw maximums.

2011-08-31 Thread Chris Bagwell
On Wed, Aug 31, 2011 at 10:01 PM, Favux ... favux...@gmail.com wrote:
 On Wed, Aug 31, 2011 at 8:18 PM, Chris Bagwell ch...@cnpbagwell.com wrote:
 Using xsetwacom and setting ScrollDistance to 180 (or thereabouts)
 yields the kind of scrolling I would expect.  This is really excellent
 Chris, the best it has been.

 Hmm, I'm a little confused on that.  Isn't your original value 600 or
 greater than that?

 Did lowering the value slow down scrolling, speed it up, or stop some
 infinite scrolling?

 If it didn't speed it up then there must be some secondary bug I need
 to investigate.

 Chris


 Sorry Chris, my fault.

 I forgot I had been doing some testing in my Natty partition.  When I
 originally reported that scroll was too fast that was with a
 ScrollDistance set near the old default of 20 in my
 52-wacom-options.conf in /etc/X11/xorg.conf.d.

 With your current patches in gesture3 I get a default of  667.  For my
 taste that has the opposite problem in that the scroll is too slow.
 So 180 picks it right up.  That may be a little fast and I might
 settle on 220 or something.

 The upshot is I think you could halve the default.  For me that would
 amount to about 330.  That is still a little slow for my taste but I
 think it would be a reasonable default for the driver.

 Favux


OK. Good to hear.  I think it does seem just a little to slow as well
but haven't experimented to much.

My non-wacom touchscreen has much lower resolution and defaults to 151
(!) based on current logic.  It also seems a little slow and even
feels the same speed as Bamboo so thats a good sign we are calculating
right.

So I think its safe to reduce that value some.

Chris

--
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free Love Thy Logs t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
___
Linuxwacom-devel mailing list
Linuxwacom-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel


Re: [Linuxwacom-devel] [PATCH v2] make gesture distances be relative to hw maximums.

2011-08-30 Thread Favux ...
Hi Chris,

Testing the tag gesture3 with Natty's 2.6.38.11 kernel's wacom.ko I'd
say both scroll and zoom responsiveness are improved.

There's less lag, and while there is still a little pointer jumping
once you get the feel you can keep it where you want it while
zooming.

I do have a question about the scroll implementation.  Once the scroll
gesture is recognized the momentum carries it to the end of the
contents.  That doesn't seem to be natural to me.  There doesn't
appear to be a way to stop in a document or thread.  And the speed
means you had better be a very fast reader.

I'll test input-wacom-0.11.1 next.  Do you need the single finger
patches tested?

Favux

--
Special Offer -- Download ArcSight Logger for FREE!
Finally, a world-class log management solution at an even better 
price-free! And you'll get a free Love Thy Logs t-shirt when you
download Logger. Secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsisghtdev2dev
___
Linuxwacom-devel mailing list
Linuxwacom-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel


Re: [Linuxwacom-devel] [PATCH v2] make gesture distances be relative to hw maximums.

2011-08-29 Thread Chris Bagwell
No takers on reviewing this series of patches, eh?

Favux, any chance you could test it briefly and report if gestures on
Bamboo either improved or at least didn't regress?

They kinda have to improve since 2 finger gestures do not work with
stock xf86-input-wacom and upstream kernel drivers.

Its a pretty small repo so this is probably easiest way; so you can
blow the whole directory away when your done.

git clone git://github.com/cbagwell/xf86-input-wacom.git
cd xf86-input-wacom
git checkout gesture3

Chris

On Sun, Aug 28, 2011 at 4:30 PM,  ch...@cnpbagwell.com wrote:
 From: Chris Bagwell ch...@cnpbagwell.com

 Gestures will work on wider range of hardware with different
 resolutions now.

 Signed-off-by: Chris Bagwell ch...@cnpbagwell.com
 ---

 I had developed this on a non-wacom touchscreen originally and didn't
 bother to test this version on Bamboo.  Turned out init order was different
 and causing -1 to be seen for some values.  Got rid of Default concept for
 Gesture info stored in Common structure to prevent being overwrite by -1.

 Pushed to github gesture3 branch.

  src/wcmCommon.c         |    8 +++-
  src/wcmTouchFilter.c    |   36 ++--
  src/wcmValidateDevice.c |   12 ++--
  src/xf86Wacom.c         |    1 +
  src/xf86Wacom.h         |    2 ++
  src/xf86WacomDefs.h     |    4 +---
  6 files changed, 39 insertions(+), 24 deletions(-)

 diff --git a/src/wcmCommon.c b/src/wcmCommon.c
 index e4ff7d9..9e71c37 100644
 --- a/src/wcmCommon.c
 +++ b/src/wcmCommon.c
 @@ -1393,13 +1393,11 @@ WacomCommonPtr wcmNewCommon(void)
        common-wcmFlags = 0;               /* various flags */
        common-wcmProtocolLevel = WCM_PROTOCOL_4; /* protocol level */
        common-wcmTPCButton = 0;          /* set Tablet PC button on/off */
 -       common-wcmGestureParameters.wcmZoomDistance = 50;
 -       common-wcmGestureParameters.wcmZoomDistanceDefault = 50;
 +       common-wcmGestureParameters.wcmZoomDistance = -1;
        common-wcmGestureParameters.wcmScrollDirection = 0;
 -       common-wcmGestureParameters.wcmScrollDistance = 20;
 -       common-wcmGestureParameters.wcmScrollDistanceDefault = 20;
 +       common-wcmGestureParameters.wcmScrollDistance = -1;
 +       common-wcmGestureParameters.wcmInlineDistance = -1;
        common-wcmGestureParameters.wcmTapTime = 250;
 -       common-wcmGestureParameters.wcmTapTimeDefault = 250;
        common-wcmRotate = ROTATE_NONE;   /* default tablet rotation to off */
        common-wcmMaxX = 0;               /* max digitizer logical X value */
        common-wcmMaxY = 0;               /* max digitizer logical Y value */
 diff --git a/src/wcmTouchFilter.c b/src/wcmTouchFilter.c
 index 1600705..0e1e258 100644
 --- a/src/wcmTouchFilter.c
 +++ b/src/wcmTouchFilter.c
 @@ -24,7 +24,6 @@
  #include math.h

  /* Defines for 2FC Gesture */
 -#define WACOM_INLINE_DISTANCE        40
  #define WACOM_HORIZ_ALLOWED           1
  #define WACOM_VERT_ALLOWED            2
  #define WACOM_GESTURE_LAG_TIME       10
 @@ -43,6 +42,20 @@
  static void wcmFingerScroll(WacomDevicePtr priv);
  static void wcmFingerZoom(WacomDevicePtr priv);

 +void wcmInitGestureSizes(InputInfoPtr pInfo)
 +{
 +       WacomDevicePtr priv = (WacomDevicePtr) pInfo-private;
 +       WacomCommonPtr common = priv-common;
 +       WacomGesturesParameters *gp = common-wcmGestureParameters;
 +
 +       if (gp-wcmZoomDistance == -1)
 +               gp-wcmZoomDistance = priv-maxX * (1600.0 / 14720);
 +       if (gp-wcmScrollDistance == -1)
 +               gp-wcmScrollDistance = priv-maxX * (640.0 / 14720);
 +       if (gp-wcmInlineDistance == -1)
 +               gp-wcmInlineDistance = priv-maxX * (1280.0 / 14720);
 +}
 +
  static double touchDistance(WacomDeviceState ds0, WacomDeviceState ds1)
  {
        int xDelta = ds0.x - ds1.x;
 @@ -61,17 +74,18 @@ static Bool pointsInLine(WacomCommonPtr common, 
 WacomDeviceState ds0,
                        WACOM_HORIZ_ALLOWED : WACOM_VERT_ALLOWED;
        int vertical_rotated = (rotated) ?
                        WACOM_VERT_ALLOWED : WACOM_HORIZ_ALLOWED;
 +       int inline_distance = common-wcmGestureParameters.wcmInlineDistance;

        if (!common-wcmGestureParameters.wcmScrollDirection)
        {
 -               if ((abs(ds0.x - ds1.x)  WACOM_INLINE_DISTANCE) 
 -                       (abs(ds0.y - ds1.y)  WACOM_INLINE_DISTANCE))
 +               if ((abs(ds0.x - ds1.x)  inline_distance) 
 +                       (abs(ds0.y - ds1.y)  inline_distance))
                {
                        common-wcmGestureParameters.wcmScrollDirection = 
 horizon_rotated;
                        ret = TRUE;
                }
 -               if ((abs(ds0.y - ds1.y)  WACOM_INLINE_DISTANCE) 
 -                       (abs(ds0.x - ds1.x)  WACOM_INLINE_DISTANCE))
 +               if ((abs(ds0.y - ds1.y)  inline_distance) 
 +                       (abs(ds0.x - ds1.x)  inline_distance))
                {