msm_gestures.h 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #ifndef __LINUX_MSM_GESTURES_H
  2. #define __LINUX_MSM_GESTURES_H
  3. #include <linux/types.h>
  4. #include <linux/ioctl.h>
  5. #include <media/msm_camera.h>
  6. #define MSM_GES_IOCTL_CTRL_COMMAND \
  7. _IOW('V', BASE_VIDIOC_PRIVATE + 20, struct v4l2_control)
  8. #define VIDIOC_MSM_GESTURE_EVT \
  9. _IOWR('V', BASE_VIDIOC_PRIVATE + 21, struct v4l2_event)
  10. #define MSM_GES_GET_EVT_PAYLOAD \
  11. _IOW('V', BASE_VIDIOC_PRIVATE + 22, struct msm_ges_evt)
  12. #define VIDIOC_MSM_GESTURE_CAM_EVT \
  13. _IOWR('V', BASE_VIDIOC_PRIVATE + 23, int)
  14. #define MSM_GES_RESP_V4L2 MSM_CAM_RESP_MAX
  15. #define MSM_GES_RESP_MAX (MSM_GES_RESP_V4L2 + 1)
  16. #define MSM_SVR_RESP_MAX MSM_GES_RESP_MAX
  17. #define MSM_V4L2_GES_BASE 100
  18. #define MSM_V4L2_GES_OPEN (MSM_V4L2_GES_BASE + 0)
  19. #define MSM_V4L2_GES_CLOSE (MSM_V4L2_GES_BASE + 1)
  20. #define MSM_V4L2_GES_CAM_OPEN (MSM_V4L2_GES_BASE + 2)
  21. #define MSM_V4L2_GES_CAM_CLOSE (MSM_V4L2_GES_BASE + 3)
  22. #define MSM_GES_APP_EVT_MIN (V4L2_EVENT_PRIVATE_START + 0x14)
  23. #define MSM_GES_APP_NOTIFY_EVENT (MSM_GES_APP_EVT_MIN + 0)
  24. #define MSM_GES_APP_NOTIFY_ERROR_EVENT (MSM_GES_APP_EVT_MIN + 1)
  25. #define MSM_GES_APP_EVT_MAX (MSM_GES_APP_EVT_MIN + 2)
  26. #define MSM_GESTURE_CID_CTRL_CMD V4L2_CID_BRIGHTNESS
  27. #define MAX_GES_EVENTS 25
  28. struct msm_ges_ctrl_cmd {
  29. int type;
  30. void *value;
  31. int len;
  32. int fd;
  33. uint32_t cookie;
  34. };
  35. struct msm_ges_evt {
  36. void *evt_data;
  37. int evt_len;
  38. };
  39. #endif /*__LINUX_MSM_GESTURES_H*/