Lines Matching refs:dx

461 DoGetDirection(int dx, int dy)  in DoGetDirection()  argument
466 if (abs(dx) < 2 && abs(dy) < 2) { in DoGetDirection()
468 if (dx > 0 && dy > 0) in DoGetDirection()
470 else if (dx > 0 && dy < 0) in DoGetDirection()
472 else if (dx < 0 && dy < 0) in DoGetDirection()
474 else if (dx < 0 && dy > 0) in DoGetDirection()
477 else if (dx > 0) in DoGetDirection()
479 else if (dx < 0) in DoGetDirection()
492 r = atan2(dy, dx); in DoGetDirection()
528 GetDirection(int dx, int dy) in GetDirection() argument
533 if (abs(dx) <= DIRECTION_CACHE_RANGE && abs(dy) <= DIRECTION_CACHE_RANGE) { in GetDirection()
535 dir = cache[DIRECTION_CACHE_RANGE + dx][DIRECTION_CACHE_RANGE + dy]; in GetDirection()
537 dir = DoGetDirection(dx, dy); in GetDirection()
538 cache[DIRECTION_CACHE_RANGE + dx][DIRECTION_CACHE_RANGE + dy] = dir; in GetDirection()
543 dir = DoGetDirection(dx, dy); in GetDirection()
561 FeedTrackers(DeviceVelocityPtr vel, double dx, double dy, int cur_t) in FeedTrackers() argument
566 vel->tracker[n].dx += dx; in FeedTrackers()
570 vel->tracker[n].dx = 0.0; in FeedTrackers()
573 vel->tracker[n].dir = GetDirection(dx, dy); in FeedTrackers()
575 dx, dy, vel->tracker[n].dir, in FeedTrackers()
588 double dist = sqrt(tracker->dx * tracker->dx + tracker->dy * tracker->dy); in CalcTracker()
677 used_offset, tracker->dx, tracker->dy, in QueryTrackers()
692 ProcessVelocityData2D(DeviceVelocityPtr vel, double dx, double dy, int time) in ProcessVelocityData2D() argument
698 FeedTrackers(vel, dx, dy, time); in ProcessVelocityData2D()
1086 double dx = 0, dy = 0; in acceleratePointerPredictable() local
1099 dx = valuator_mask_get_double(val, 0); in acceleratePointerPredictable()
1106 if (dx != 0.0 || dy != 0.0) { in acceleratePointerPredictable()
1108 if (ProcessVelocityData2D(velocitydata, dx, dy, evtime)) { in acceleratePointerPredictable()
1124 ApplySoftening(velocitydata, &dx, &dy); in acceleratePointerPredictable()
1125 ApplyConstantDeceleration(velocitydata, &dx, &dy); in acceleratePointerPredictable()
1127 if (dx != 0.0) in acceleratePointerPredictable()
1128 valuator_mask_set_double(val, 0, mult * dx); in acceleratePointerPredictable()
1131 DebugAccelF("delta x:%.3f y:%.3f\n", mult * dx, mult * dy); in acceleratePointerPredictable()
1136 velocitydata->last_dx = dx; in acceleratePointerPredictable()
1149 double dx = 0.0, dy = 0.0; in acceleratePointerLightweight() local
1152 dx = valuator_mask_get(val, 0); in acceleratePointerLightweight()
1165 if ((fabs(dx) + fabs(dy)) >= dev->ptrfeed->ctrl.threshold) { in acceleratePointerLightweight()
1166 if (dx != 0.0) { in acceleratePointerLightweight()
1167 tmpf = (dx * (double) (dev->ptrfeed->ctrl.num)) / in acceleratePointerLightweight()
1180 mult = pow(dx * dx + dy * dy, in acceleratePointerLightweight()
1183 if (dx != 0.0) in acceleratePointerLightweight()
1184 valuator_mask_set_double(val, 0, mult * dx); in acceleratePointerLightweight()