summaryrefslogtreecommitdiffstats
path: root/doc/src/examples/hapticsplayer.qdoc
blob: 25a6b5fb83f0ebbfe08ba11cf8d719bb1202b586 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of the documentation of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:FDL$
** GNU Free Documentation License
** Alternatively, this file may be used under the terms of the GNU Free
** Documentation License version 1.3 as published by the Free Software
** Foundation and appearing in the file included in the packaging of
** this file.
**
** Other Usage
** Alternatively, this file may be used in accordance with the terms
** and conditions contained in a signed written agreement between you
** and Nokia.
**
**
**
**
** $QT_END_LICENSE$
**
****************************************************************************/

/*!
    \example hapticsplayer
    \title Haptics Player

    \tableofcontents

    \section1 Overview

    This example shows how to use various haptic effects in an application via
    the \l{Feedback}{QtMobility Feedback API}.

    It provides an example of how to use the QtMobility libraries to:
    \list
    \o play "system theme" haptic effects corresponding to certain predefined events
    \o play a dynamic custom effect, single or repeating
    \o play a custom effect which is stored in a file
    \endlist

    \section2 Use Case

    This example is more feature complete than the \l{hapticsquare}{Haptic Square} example,
    but is intended more as a way to test the haptics provider plugins which
    are available on a system, than as an example for application developers.

    It is useful for people who wish to learn how to use the API to create and
    play custom effects dynamically, or to allow users of an application to
    select which haptic effect to play when a particular event occurs.  It is also useful
    to test how effects are implemented on specific devices.

    It is a more complex example than the \l{hapticsquare}{Haptic Square} example, so it is
    suggested that developers look at that example first.

    \section2 Interface
    The application is designed to work on desktop and mobile platforms with
    minimal differences in code between the platforms.  The interface consists
    of three tabs which allow the user to select and play different custom,
    system theme, and file effects, respectively.  The custom effect tab also
    allows the user to modify the custom effect dynamically, and see the effect
    of attack and fade, intensity and duration, and periodicity, on the user
    experience.

    \section2 Known Issues
    The example will not work correctly on platforms which do not have a
    QFeedbackHapticInterface (haptic effect provider) plugin loaded.  On such
    platforms, the example will do nothing.
*/