aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/include/ptrveloc.h
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-04-16 09:37:37 +0200
committermarha <marha@users.sourceforge.net>2012-04-16 09:43:48 +0200
commit00eae6f01bf11ec6a90dfc68e607b6a1a250a118 (patch)
treeb814d518076840b7433d02bc3b5957c1dd54de25 /xorg-server/include/ptrveloc.h
parenta50d2ee664302147942dd5ed6428f9bab9d4e76a (diff)
parentd6d3999ccb2cb72d55820770260172eccbbb68d7 (diff)
downloadvcxsrv-00eae6f01bf11ec6a90dfc68e607b6a1a250a118.tar.gz
vcxsrv-00eae6f01bf11ec6a90dfc68e607b6a1a250a118.tar.bz2
vcxsrv-00eae6f01bf11ec6a90dfc68e607b6a1a250a118.zip
Merge remote-tracking branch 'origin/released'
Conflicts: xorg-server/Xext/securitysrv.h xorg-server/glx/glxext.h xorg-server/glx/indirect_reqsize.c xorg-server/glx/indirect_size_get.c xorg-server/hw/xwin/winclip.c xorg-server/hw/xwin/winfont.c xorg-server/hw/xwin/winglobals.c xorg-server/hw/xwin/winglobals.h xorg-server/hw/xwin/winmonitors.h xorg-server/include/closestr.h xorg-server/include/pixmapstr.h xorg-server/include/servermd.h xorg-server/include/site.h xorg-server/include/windowstr.h xorg-server/include/xkbstr.h
Diffstat (limited to 'xorg-server/include/ptrveloc.h')
-rw-r--r--xorg-server/include/ptrveloc.h71
1 files changed, 38 insertions, 33 deletions
diff --git a/xorg-server/include/ptrveloc.h b/xorg-server/include/ptrveloc.h
index 4f76b0094..8778646f5 100644
--- a/xorg-server/include/ptrveloc.h
+++ b/xorg-server/include/ptrveloc.h
@@ -48,8 +48,8 @@ struct _DeviceVelocityRec;
* returns actual acceleration depending on velocity, acceleration control,...
*/
typedef double (*PointerAccelerationProfileFunc)
- (DeviceIntPtr dev, struct _DeviceVelocityRec* vel,
- double velocity, double threshold, double accelCoeff);
+ (DeviceIntPtr dev, struct _DeviceVelocityRec * vel,
+ double velocity, double threshold, double accelCoeff);
/**
* a motion history, with just enough information to
@@ -57,9 +57,9 @@ typedef double (*PointerAccelerationProfileFunc)
* a more or less straight line
*/
typedef struct _MotionTracker {
- double dx, dy; /* accumulated delta for each axis */
- int time; /* time of creation */
- int dir; /* initial direction bitfield */
+ double dx, dy; /* accumulated delta for each axis */
+ int time; /* time of creation */
+ int dir; /* initial direction bitfield */
} MotionTracker, *MotionTrackerPtr;
/**
@@ -68,25 +68,25 @@ typedef struct _MotionTracker {
typedef struct _DeviceVelocityRec {
MotionTrackerPtr tracker;
int num_tracker;
- int cur_tracker; /* current index */
- double velocity; /* velocity as guessed by algorithm */
- double last_velocity; /* previous velocity estimate */
- double last_dx; /* last time-difference */
- double last_dy; /* phase of last/current estimate */
- double corr_mul; /* config: multiply this into velocity */
- double const_acceleration; /* config: (recipr.) const deceleration */
- double min_acceleration; /* config: minimum acceleration */
- short reset_time; /* config: reset non-visible state after # ms */
- short use_softening; /* config: use softening of mouse values */
- double max_rel_diff; /* config: max. relative difference */
- double max_diff; /* config: max. difference */
- int initial_range; /* config: max. offset used as initial velocity */
- Bool average_accel; /* config: average acceleration over velocity */
+ int cur_tracker; /* current index */
+ double velocity; /* velocity as guessed by algorithm */
+ double last_velocity; /* previous velocity estimate */
+ double last_dx; /* last time-difference */
+ double last_dy; /* phase of last/current estimate */
+ double corr_mul; /* config: multiply this into velocity */
+ double const_acceleration; /* config: (recipr.) const deceleration */
+ double min_acceleration; /* config: minimum acceleration */
+ short reset_time; /* config: reset non-visible state after # ms */
+ short use_softening; /* config: use softening of mouse values */
+ double max_rel_diff; /* config: max. relative difference */
+ double max_diff; /* config: max. difference */
+ int initial_range; /* config: max. offset used as initial velocity */
+ Bool average_accel; /* config: average acceleration over velocity */
PointerAccelerationProfileFunc Profile;
PointerAccelerationProfileFunc deviceSpecificProfile;
- void* profile_private;/* extended data, see SetAccelerationProfile() */
- struct { /* to be able to query this information */
- int profile_number;
+ void *profile_private; /* extended data, see SetAccelerationProfile() */
+ struct { /* to be able to query this information */
+ int profile_number;
} statistics;
} DeviceVelocityRec, *DeviceVelocityPtr;
@@ -96,49 +96,54 @@ typedef struct _DeviceVelocityRec {
*/
typedef struct _PredictableAccelSchemeRec {
DeviceVelocityPtr vel;
- long* prop_handlers;
+ long *prop_handlers;
int num_prop_handlers;
} PredictableAccelSchemeRec, *PredictableAccelSchemePtr;
extern _X_EXPORT void
-InitVelocityData(DeviceVelocityPtr vel);
+ InitVelocityData(DeviceVelocityPtr vel);
extern _X_EXPORT void
-InitTrackers(DeviceVelocityPtr vel, int ntracker);
+ InitTrackers(DeviceVelocityPtr vel, int ntracker);
extern _X_EXPORT BOOL
ProcessVelocityData2D(DeviceVelocityPtr vel, double dx, double dy, int time);
extern _X_EXPORT double
+
BasicComputeAcceleration(DeviceIntPtr dev, DeviceVelocityPtr vel,
- double velocity, double threshold, double acc);
+ double velocity, double threshold, double acc);
extern _X_EXPORT void
-FreeVelocityData(DeviceVelocityPtr vel);
+ FreeVelocityData(DeviceVelocityPtr vel);
extern _X_EXPORT int
-SetAccelerationProfile(DeviceVelocityPtr vel, int profile_num);
+ SetAccelerationProfile(DeviceVelocityPtr vel, int profile_num);
extern _X_EXPORT DeviceVelocityPtr
GetDevicePredictableAccelData(DeviceIntPtr dev);
extern _X_EXPORT void
+
SetDeviceSpecificAccelerationProfile(DeviceVelocityPtr vel,
PointerAccelerationProfileFunc profile);
extern _X_INTERNAL void
-AccelerationDefaultCleanup(DeviceIntPtr dev);
+ AccelerationDefaultCleanup(DeviceIntPtr dev);
extern _X_INTERNAL Bool
+
InitPredictableAccelerationScheme(DeviceIntPtr dev,
- struct _ValuatorAccelerationRec* protoScheme);
+ struct _ValuatorAccelerationRec *protoScheme);
extern _X_INTERNAL void
-acceleratePointerPredictable(DeviceIntPtr dev, ValuatorMask* val,
+
+acceleratePointerPredictable(DeviceIntPtr dev, ValuatorMask *val,
CARD32 evtime);
extern _X_INTERNAL void
-acceleratePointerLightweight(DeviceIntPtr dev, ValuatorMask* val,
+
+acceleratePointerLightweight(DeviceIntPtr dev, ValuatorMask *val,
CARD32 evtime);
-#endif /* POINTERVELOCITY_H */
+#endif /* POINTERVELOCITY_H */