Feedback API
English Spanish
Qt Mobility 1.1 Features
News
Qt Mobility 1.1.3 Release is available now for commercial app development and deployment on Ovi store. Qt Mobility 1.2.0 release is available now.
Summary
The Feedback API is a new API designed to help applications respond to user interaction and give feedback. That can be haptics or audio feedback.
Key features
The feedback API provides three kinds of feedback,
- Theme-based feedback:
You can decide on the reaction of your application by asking the system to execute a feedback that is theme specific. So for instance if you have a UI component that should be used as a button, you can make that happen.
- Custom haptics:
You can start a specific haptics feedback. You get to specify the duration, intensity, period, … That is useful if you need to be in complete control of the feedback that you want, for example in games. The system will play this feedback on an actuator. You can query the available actuators and their properties (name, state…) through the QFeedbackActuator class.
- File support:
For some technologies, you can get the feedback stored in a file. That can be a haptics feedback with all it parameters, a wave file… So there is support for loading those files and play them. There is currently the support for Immersion IVT files (for platforms that support it) and a Phonon backend to play sound.
Back-ends
Each kind of feedback is implemented by means of a plug-in back-end architecture. We currently have support for the MeeGo (through the MeeGo Touch API) and Symbian^3 platforms. Support is as follows,
Platform | Theme-based | Custom | File-based |
MeeGo | Yes | Yes | Yes |
Symbian^3 | Yes | Yes | No |
The back-end plug-ins' source code is available in plugins/feedback. Note also that since the underlying support for the hardware is completely different in Maemo 5, the MeeGo plug-in will not work on (as is not trivially portable to) that platform.
Haptics Player example application
The small example demonstrating the feedback API is called "haptics player". It allows to use all the features from the API. Select the kind of feedback from the tabs, and set the parameters on its form.