include/SDL_haptic.h
branchgsoc2008_force_feedback
changeset 2645 269ba4f28d0e
parent 2630 776f7f800131
child 2646 9408be170bff
     1.1 --- a/include/SDL_haptic.h	Tue Aug 12 20:49:31 2008 +0000
     1.2 +++ b/include/SDL_haptic.h	Sun Aug 24 17:17:45 2008 +0000
     1.3 @@ -240,6 +240,15 @@
     1.4   * \sa SDL_HapticGetEffectStatus
     1.5   */
     1.6  #define SDL_HAPTIC_STATUS     (1<<14) /* Device can be queried for effect status */
     1.7 +/**
     1.8 + * \def SDL_HAPTIC_PAUSE
     1.9 + *
    1.10 + * \brief Device can be paused.
    1.11 + *
    1.12 + * \sa SDL_HapticPause
    1.13 + * \sa SDL_HapticUnpause
    1.14 + */
    1.15 +#define SDL_HAPTIC_PAUSE      (1<<15) /* Device can be paused. */
    1.16  
    1.17  
    1.18  /*
    1.19 @@ -1068,6 +1077,38 @@
    1.20   */
    1.21  extern DECLSPEC int SDLCALL SDL_HapticSetAutocenter(SDL_Haptic * haptic, int autocenter);
    1.22  
    1.23 +/**
    1.24 + * \fn extern DECLSPEC int SDLCALL SDL_HapticPause(SDL_Haptic * haptic)
    1.25 + *
    1.26 + * \brief Pauses the haptic device.
    1.27 + *
    1.28 + * Device must support the SDL_HAPTIC_PAUSE feature.  Call SDL_HapticUnpause
    1.29 + *  to resume playback.
    1.30 + *
    1.31 + * Do not modify the effects nor add new ones while the device is paused.
    1.32 + *  That can cause all sorts of weird errors.
    1.33 + *
    1.34 + *    \param haptic Haptic device to pause.
    1.35 + *    \return 0 on success or -1 on error.
    1.36 + *
    1.37 + * \sa SDL_HapticUnpause
    1.38 + */
    1.39 +extern DECLSPEC int SDLCALL SDL_HapticPause(SDL_Haptic * haptic);
    1.40 +
    1.41 +/**
    1.42 + * \fn extern DECLSPEC int SDLCALL SDL_HapticUnpause(SDL_Haptic * haptic)
    1.43 + *
    1.44 + * \brief Unpauses the haptic device.
    1.45 + *
    1.46 + * Call to unpause after SDL_HapticPause.
    1.47 + *
    1.48 + *    \param haptic Haptic device to pause.
    1.49 + *     \return 0 on success or -1 on error.
    1.50 + *
    1.51 + * \sa SDL_HapticPause
    1.52 + */
    1.53 +extern DECLSPEC int SDLCALL SDL_HapticUnpause(SDL_Haptic * haptic);
    1.54 +
    1.55  
    1.56  /* Ends C function definitions when using C++ */
    1.57  #ifdef __cplusplus