2024年3月9日发(作者:)
第一章 摘要在Linux内核支持的基础上,Android在其2.0源码中加入多点触摸功能。
由此触摸屏在Android的frameworks被完全分为2种实现途径:单点触摸屏的单点方式,
多点触摸屏的单点和多点方式。
第二章 软件位在Linux的input.h中,多点触摸功能依赖于以下几个主要的软件位:
………………………..
#define SYN_REPORT 0
#define SYN_CONFIG 1
#define SYN_MT_REPORT 2
………………………...
#define ABS_MT_TOUCH_MAJOR 0x30 /* Major axis of touching ellipse */
#define ABS_MT_TOUCH_MINOR 0x31 /* Minor axis (omit if circular) */
#define ABS_MT_WIDTH_MAJOR 0x32 /* Major axis of approaching ellipse */
#define ABS_MT_WIDTH_MINOR 0x33 /* Minor axis (omit if circular) */
#define ABS_MT_ORIENTATION 0x34 /* Ellipse orientation */
#define ABS_MT_POSITION_X 0x35 /* Center X ellipse position */
#define ABS_MT_POSITION_Y 0x36 /* Center Y ellipse position */
#define ABS_MT_TOOL_TYPE 0x37 /* Type of touching device */
#define ABS_MT_BLOB_ID 0x38 /* Group a set of packets as a blob */
…………………………
在Android中对应的软件位定义在中:
…………………..
public class RawInputEvent {
……………….
public static final int CLASS_TOUCHSCREEN_MT = 0x00000010;
………………..
public static final int ABS_MT_TOUCH_MAJOR = 0x30;
public static final int ABS_MT_TOUCH_MINOR = 0x31;
发布评论