There have been a gradual increase in number of sensors that are being built into smartphones, in order to make them more intuitive. This has pushed the boundaries for more alternative methods of interaction with the smartphone. Device gesture recognition has been one such aspect that has garnered a lot of interest of developers. The Accelerometer Actions used in iPhone application development is one such framework which takes in accelerometer actions from the controller and generates corresponding callbacks as per defined in the classes.
This little framework is very easy to integrate into the source code of the application and opens a whole new dimensions of interactions. Developers can use these enhanced interactions in the iPhone and the iPod Touch applications to add more functionality. What is more important to understand is the fact that these group of classes have a very little footprint and does not pose a lot of burden in the performance of the application.
The idea is very simple and involves the application to respond to specific motion that take place during the course of a specific gesture. For example, you might tilt the device in a particular direction to incorporate some action. Currently Accelerometer Action Framework supports seven gestures that can be used by the iPhone app developers. Rotation of device sideways in a clockwise direction.
• Rotation of device sideways in an counter-clockwise direction.
• Moving the top part of the device from right to left.
• Moving the top part of the device from left to right.
• Moving the top part of the device in the upward direction
• Moving the top part of the device in the downward direction
• Strongly shaking the device
Although all of these gestures can be pre-defined in classes and then called on an event occurrence, they are only available in the portrait mode and no support is yet available for landscape mode. When the user invokes any of the following gestures, the accelerometer registers a constant acceleration because of the gravity. This action can then be corresponded to the group of classes defined in the code.
A simple example of using this framework could be gesture based call management. If someone calls you, with your iPhone sitting on the table, a simple action to silent the phone using the gesture “Rotating the device from left to right like if you are turning a key to open a door” can be invoked. So when the iPhone is rotated in clockwise direction, the call management service would silence the ringer. Another example would be tilt to zoom in or zoom out of picture. There are a lot of similar real world applications of using this accelerometer based action framework, which developers can utilize.
Call Us @ 888-276-4064 or feel free to get in touch with us for Mobile Applications Development.