Python Wacom Interface

前端 未结 2 1665
独厮守ぢ
独厮守ぢ 2021-01-15 14:12

I am trying to write a python script on Windows 7 to interact with my Wacom Bamboo Pen tablet. Wacom recommends using the WinTab API, and it works fine, but not for my appli

2条回答
  •  臣服心动
    2021-01-15 14:32

    I think, in wintab you can get the raw coordinates. At least in Python wrapper for wintab you can access them:

    cgkit.wintab.Packet.x
    

    In absolute mode, contains the scaled cursor location along the x axis. In relative mode, contains the scaled change in cursor position.

    cgkit.wintab.Packet.y
    

    In absolute mode, contains the scaled cursor location along the y axis. In relative mode, contains the scaled change in cursor position.

    I'm investigating for myself if there is an cross-platform api for tablets, but if you need windows-only solution that should work.

提交回复
热议问题