如何在 Windows 中仅调整垂直鼠标灵敏度?

如何在 Windows 中仅调整垂直鼠标灵敏度?

我已经用了便宜的 Logitech M215 无线鼠标好几年了。它仍然运行良好。

对于我的笔记本电脑,我购买了两个额外的鼠标 - 都是罗技鼠标 - 期望它们具有相同的性能。问题是:两个鼠标的垂直灵敏度都很差。沿 x 轴的灵敏度很好,但沿 y 轴的灵敏度很慢,以至于我讨厌使用它们。(这个问题在我的台式电脑上重复出现。)

我知道如何在 Windows 中调整指针速度,但我并不想缩放两个轴,只缩放 y 轴。显然在 Ubuntu 中有一种方法可以做到这一点,我搜索了很多论坛,问了与我现在问的问题基本相同的问题,但都无济于事。这个问题甚至有人在这里问过,但评论没有任何帮助。

有人知道在 Windows 8.1 中执行此操作的方法吗?我很乐意进行任何注册表更改/下载任何可能有帮助的软件。

答案1

这是一个不完美但有用的选项。它最初由 Nextron 用户提供,网址为https://autohotkey.com/board/topic/13531-adjusting-mouse-sensitivity-via-hotkey/

此脚本为您提供了在 Windows 上独立修改 X 和 Y 灵敏度的余地,并且它适用于所有鼠标和所有版本的 Windows。它并不完美,因为您必须使用灵敏度的整数倍,并且它通过乘以鼠标移动脉冲来操作。

  1. 安装自动热键。
  2. 修改下面的自动热键脚本。new MouseAccelerator(0, 1)将其中的 改为new MouseAccelerator (<amount to multiply X sensitivity by> - 1, <amount to multiply Y sensitivity by> - 1)。例如,MouseAccelerator(0, 1)使 Y 轴移动加倍但不影响 X 轴移动,MouseAccelerator(2, 1)使水平移动加倍并垂直移​​动加倍,等等。
  3. 运行修改后的脚本。F12想关闭时点击。

    ;The SendInput DllCall is specifically 32-bit. So check for the correct bitness of AutoHotkey and if not, try to run the right one.
    If (A_PtrSize=8){
        SplitPath, A_AhkPath,,Dir
        Run %Dir%\AutoHotkeyU32.exe %A_ScriptFullPath%
        ExitApp
    }
    
    ;Call below to accelerate the mouse input. The first two parameters are the integer factors of artificial amplification added on top of the physical input.
    ;The first is for horizontal/x-axis movement, the second for vertical/y-axis movement.
    new MouseAccelerator(0, 1)
    
    F12::ExitApp
    
    
    ; Gets called when mouse moves or stops
    ; x and y are DELTA moves (Amount moved since last message), NOT coordinates.
    MouseAcceleratorEvent(x := 0, y := 0, accelerationx := 2, accelerationy := 2){
        static MouseAcceleratorPaused
        If !(MouseAcceleratorPaused){
            MouseAcceleratorPaused:=true
            VarSetCapacity( MouseInput, 28, 0 )
            NumPut( x * accelerationx, MouseInput, 4, "Int" ) ; dx
            NumPut( y * accelerationy, MouseInput, 8, "Int" ) ; dy
            NumPut( 0x0001, MouseInput, 16, "UInt" ) ; MOUSEEVENTF_MOVE = 0x0001
            DllCall("SendInput", "UInt", 1, "UInt", &MouseInput, "Int", 28 )
            sleep,-1
            MouseAcceleratorPaused:=false
        }
    }
    
    ; ================================== LIBRARY ========================================
    ; Instantiate this class and pass it a func name or a Function Object
    ; The specified function will be called with the delta move for the X and Y axes
    ; Normally, there is no windows message "mouse stopped", so one is simulated.
    ; After 10ms of no mouse movement, the callback is called with 0 for X and Y
    ; https://autohotkey.com/boards/viewtopic.php?f=19&t=10159
    Class MouseAccelerator {
        __New(accelerationx:=2, accelerationy:=2, callback:="MouseAcceleratorEvent"){
            static DevSize := 8 + A_PtrSize
            static RIDEV_INPUTSINK := 0x00000100
    
            this.TimeoutFn := this.TimeoutFunc.Bind(this)
    
            this.Callback := callback
            this.Accelerationx := accelerationx
            this.Accelerationy := accelerationy
            ; Register mouse for WM_INPUT messages.
            VarSetCapacity(RAWINPUTDEVICE, DevSize)
            NumPut(1, RAWINPUTDEVICE, 0, "UShort")
            NumPut(2, RAWINPUTDEVICE, 2, "UShort")
            NumPut(RIDEV_INPUTSINK, RAWINPUTDEVICE, 4, "Uint")
            ; WM_INPUT needs a hwnd to route to, so get the hwnd of the AHK Gui.
            ; It doesn't matter if the GUI is showing, it still exists
            Gui +hwndhwnd
            NumPut(hwnd, RAWINPUTDEVICE, 8, "Uint")
    
            this.RAWINPUTDEVICE := RAWINPUTDEVICE
            DllCall("RegisterRawInputDevices", "Ptr", &RAWINPUTDEVICE, "UInt", 1, "UInt", DevSize )
            fn := this.MouseMoved.Bind(this)
            OnMessage(0x00FF, fn)
        }
    
        __Delete(){
            static RIDEV_REMOVE := 0x00000001
            static DevSize := 8 + A_PtrSize
            RAWINPUTDEVICE := this.RAWINPUTDEVICE
            NumPut(RIDEV_REMOVE, RAWINPUTDEVICE, 4, "Uint")
            DllCall("RegisterRawInputDevices", "Ptr", &RAWINPUTDEVICE, "UInt", 1, "UInt", DevSize )
        }
    
        ; Called when the mouse moved.
        ; Messages tend to contain small (+/- 1) movements, and happen frequently (~20ms)
        MouseMoved(wParam, lParam){
            ; RawInput statics
            static DeviceSize := 2 * A_PtrSize, iSize := 0, sz := 0, offsets := {x: (20+A_PtrSize*2), y: (24+A_PtrSize*2)}, uRawInput
    
            static axes := {x: 1, y: 2}
    
            ; Find size of rawinput data - only needs to be run the first time.
            if (!iSize){
                r := DllCall("GetRawInputData", "UInt", lParam, "UInt", 0x10000003, "Ptr", 0, "UInt*", iSize, "UInt", 8 + (A_PtrSize * 2))
                VarSetCapacity(uRawInput, iSize)
            }
            sz := iSize ; param gets overwritten with # of bytes output, so preserve iSize
            ; Get RawInput data
            r := DllCall("GetRawInputData", "UInt", lParam, "UInt", 0x10000003, "Ptr", &uRawInput, "UInt*", sz, "UInt", 8 + (A_PtrSize * 2))
    
            x := NumGet(&uRawInput, offsets.x, "Int")
            y := NumGet(&uRawInput, offsets.y, "Int")
    
            this.Callback.(x, y, this.Accelerationx, this.Accelerationy)
    
            ; There is no message for "Stopped", so simulate one
            fn := this.TimeoutFn
            SetTimer, % fn, -10
        }
    
        TimeoutFunc(){
            this.Callback.(0, 0)
        }
    
    }
    

答案2

我有 M310,也遇到过同样的问题。有些人用压缩空气清洁镜头,成功了。但对我来说,其实是我的鼠标垫出了问题……将鼠标垫旋转 90 度,看看是否有效果。

答案3

我想在这里提出类似案例的解决方案。我的垂直和水平敏感度之间相当不平衡。

最后,我取消选中“鼠标属性”中的“增强指针精度”,恢复了平衡。

这不太清楚。因为我花了很多时间,而且几乎是碰巧找到了解决方案,所以我想在这里把它固定下来。

答案4

是否有类似 Razer Synapse 的 Logitech 鼠标自定义软件?您可能可以在其中找到自定义灵敏度设置。

相关内容