User Tools

Site Tools


api_reference

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
api_reference [2017/05/02 16:49]
curtisb [Core Functions]
api_reference [2018/03/14 14:55]
ideumadmin
Line 1: Line 1:
 +{{htmlmetatags>​metatag-og:​title=(GestureWorks 2 - API Reference)
 +metatag-description=(A reference for of the GestureWorks API methods, functions and data structures.) ​
 +metatag-keywords=(gesture authoring, multitouch authoring, gesture-based authoring, gesture markup, gestureml, gesture mark up language, GestureWorks,​ multitouch SDK, Unity, Unity3D, C++, UI gestures, screen gestures, visualizer, API, SDK) 
 +metatag-og:​description=(A reference for of the GestureWorks API methods, functions and data structures.) ​
 +metatag-og:​type=(article) ​
 +metatag-og:​url=(http://​gwiki.gestureworks.com/​doku.php/​api_reference) ​
 +metatag-og:​site_name=(GestureWorks 2 Wiki- Comprehensive Gesture-Processing Library for Windows Applications) ​
 +metatag-og:​image=(http://​gestureworks.com/​images/​828138ec-d80c-419b-192f-cde0258f2108.png)}}
 +
 ====== API Reference ====== ====== API Reference ======
 ===== Overview ===== ===== Overview =====
-The GestureWorks ​Core API consists of a series of methods, functions and data structures which are used to connect applications to GestureWorks,​ prompt the core to analyze and process gestures, then return structured gesture event data to the application layer.+The GestureWorks API consists of a series of methods, functions and data structures which are used to connect applications to GestureWorks,​ prompt the core to analyze and process gestures, then return structured gesture event data to the application layer.
  
  
Line 42: Line 51:
  float position_y;  float position_y;
  int timestamp;  int timestamp;
 + };
 +
 +===bool addTouchPointToObject(GestureWorks *gesture_works,​ const char *object_id, int point_id)===
 +Associates a touch event with a TouchObject.
 +
 +===bool objectHasTouchPoint(GestureWorks *gesture_works,​ int point_id)===
 +Tests to see if any current TouchObject already has the touch event.
 +
 +===void updateFrame(GestureWorks *gesture_works)===
 +Updates a frame of GestureWorks.
 +
 +===void updateScreenFrame(GestureWorks *gesture_works)===
 +Updates a frame of GestureWorks running in screen mode.
 +
 +===int getGestureEvents(GestureWorks *gesture_works,​ GestureInfo **gestures)===
 +Retrieves all of the gestures for a frame.
 +
 + static const int MAX_GESTURES_FRAME = 100;
 + static const int MAX_GESTURE_VALUES = 25;
 + static const int MAX_GESTURE_NAME = 100;
 + struct GestureInfo
 + {
 + int id;
 + char gesture_type[MAX_GESTURE_NAME];​
 + char gesture_id[MAX_GESTURE_NAME];​
 + char target[MAX_GESTURE_NAME];​
 + int source;
 + int n;
 + int hold_n;
 + float x;
 + float y;
 + int timestamp;
 + int phase;
 + struct GestureValue
 + {
 + char name[MAX_GESTURE_NAME];​
 + float value;
 + };
 + GestureValue values[MAX_GESTURE_VALUES];​
 + int gesture_values_count;​
  };  };
  
  
  
api_reference.txt ยท Last modified: 2019/01/21 16:34 (external edit)