/**
* @brief Enumeration for error code.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
*/
typedef enum {
TTS_ERROR_NONE = TIZEN_ERROR_NONE, /**< Successful */
TTS_ERROR_ENGINE_NOT_FOUND = TIZEN_ERROR_TTS | 0x03, /**< No available engine */
TTS_ERROR_OPERATION_FAILED = TIZEN_ERROR_TTS | 0x04, /**< Operation failed */
TTS_ERROR_AUDIO_POLICY_BLOCKED = TIZEN_ERROR_TTS | 0x05, /**< Audio policy blocked */
- TTS_ERROR_NOT_SUPPORTED_FEATURE = TIZEN_ERROR_TTS | 0x06, /**< Not supported feature of current engine @if MOBILE (Since 3.0) @elseif WEARABLE (Since 2.3.2) @endif */
- TTS_ERROR_SERVICE_RESET = TIZEN_ERROR_TTS | 0x07, /**< Service reset @if MOBILE (Since 3.0) @elseif WEARABLE (Since 2.3.2) @endif */
+ TTS_ERROR_NOT_SUPPORTED_FEATURE = TIZEN_ERROR_TTS | 0x06, /**< Not supported feature of current engine (Since 3.0) */
+ TTS_ERROR_SERVICE_RESET = TIZEN_ERROR_TTS | 0x07, /**< Service reset (Since 3.0) */
TTS_ERROR_SCREEN_READER_OFF = TIZEN_ERROR_TTS | 0x08 /**< Screen reader is off (Since 6.5) */
} tts_error_e;
/**
* @brief Enumeration for TTS mode.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
*/
typedef enum {
TTS_MODE_DEFAULT = 0, /**< Default mode for normal application */
/**
* @brief Enumeration for state.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
*/
typedef enum {
TTS_STATE_CREATED = 0, /**< 'CREATED' state */
/**
* @brief Definition for automatic speaking speed.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
*/
#define TTS_SPEED_AUTO 0
/**
* @brief Definition for automatic voice type.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
*/
#define TTS_VOICE_TYPE_AUTO 0
/**
* @brief Definition for male voice type.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
*/
#define TTS_VOICE_TYPE_MALE 1
/**
* @brief Definition for female voice type.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
*/
#define TTS_VOICE_TYPE_FEMALE 2
/**
* @brief Definition for child voice type.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
*/
#define TTS_VOICE_TYPE_CHILD 3
/**
* @brief The TTS handle.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
*/
typedef struct tts_s *tts_h;
* @brief Called when the state of TTS is changed.
* @details If the daemon must stop player because of changing engine and
* the daemon must pause player because of other requests, this callback function is called.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] previous The previous state
* @param[in] current The current state
/**
* @brief Called when utterance has started.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] utt_id The utterance ID passed from the add text function
* @param[in] user_data The user data passed from the callback registration function
/**
* @brief Called when utterance is finished.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] utt_id The utterance ID passed from the add text function
* @param[in] user_data The user data passed from the callback registration function
/**
* @brief Called when an error occurs.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] utt_id The utterance ID passed from the add text function
* @param[in] reason The error code
/**
* @brief Called to retrieve the supported voice.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] language Language specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code (for example, "ko_KR" for Korean, "en_US" for American English)
* @param[in] voice_type A voice type (e.g. #TTS_VOICE_TYPE_MALE, #TTS_VOICE_TYPE_FEMALE)
/**
* @brief Called when the default voice is changed.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] previous_language The previous language
* @param[in] previous_voice_type The previous voice type
/**
* @brief Called when the engine is changed.
- * @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
+ * @since_tizen 3.0
* @param[in] tts The TTS handle
* @param[in] engine_id Engine ID
* @param[in] language The default language specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code (for example, "ko_KR" for Korean, "en_US" for American English)
/**
* @brief Creates a handle for TTS.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @remarks If the function succeeds, @a tts handle must be released with tts_destroy().
* @param[out] tts The TTS handle
* @return @c 0 on success,
/**
* @brief Destroys the handle and disconnects the daemon.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Sets the TTS mode.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] mode The mode
* @return @c 0 on success,
/**
* @brief Gets the TTS mode.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[out] mode The mode
* @return @c 0 on success,
* @details Using this API, the application can set a credential.
* The credential is a key to verify the authorization about using the engine.
* If the application sets the credential, it will be able to use functions of the engine entirely.
- * @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
+ * @since_tizen 3.0
* @remarks The necessity of the credential depends on the engine. In case of the engine which is basically embedded in Tizen, the credential is not necessary so far.
* However, if the user wants to apply the 3rd party's engine, the credential may be necessary. In that case, please follow the policy provided by the corresponding engine.
* @param[in] tts The TTS handle
/**
* @brief Connects the daemon asynchronously.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Disconnects the daemon.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Retrieves all supported voices of the current engine using callback function.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] callback The callback function to invoke
* @param[in] user_data The user data to be passed to the callback function
/**
* @brief Gets the default voice set by the user.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @remarks If the function succeeds, @a language must be released with free().
* @param[in] tts The TTS handle
* @param[out] language Language specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code (for example, "ko_KR" for Korean, "en_US" for American English)
* Using this API, the application can set the private data and use the corresponding key of the engine.
* For example, if the engine provides 'girl's voice' as a voice type, the application can set the private data as the following.
* int ret = tts_set_private_data(#tts_h, "voice_type", "GIRL");
- * @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
+ * @since_tizen 3.0
* @remarks If the engine is replaced with the other engine, the key may be ignored.
* @param[in] tts The TTS handle
* @param[in] key The field name of private data
* @brief Gets the private data from tts engine.
* @details The private data is the information provided by the engine.
* Using this API, the application can get the private data which corresponds to the key from the engine.
- * @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
+ * @since_tizen 3.0
* @remarks The @a data must be released using free() when it is no longer required.
* If the engine is replaced with the other engine, the key may be ignored.
* @param[in] tts The TTS handle
/**
* @brief Gets the maximum byte size for text.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[out] size The maximum byte size for text
* @return @c 0 on success,
/**
* @brief Gets the current state of TTS.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[out] state The current state of TTS
* @return @c 0 on success,
/**
* @brief Gets the speed range.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[out] min The minimum speed value
* @param[out] normal The normal speed value
/**
* @brief Gets the current error message.
- * @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
+ * @since_tizen 3.0
* @remarks This function should be called from a tts error callback. Calling in any other context will result in an Operation failed error.
* A successful call will allocate @a err_msg, which must be released by calling free() when it is no longer required.
* @param[in] tts The TTS handle
/**
* @brief Adds a text to the queue.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @remarks Locale(e.g. setlocale()) MUST be set for utf8 text validation check.
* @param[in] tts The TTS handle
* @param[in] text An input text based utf8
/**
* @brief Starts synthesizing voice from the text and plays the synthesized audio data.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Stops playing the utterance and clears the queue.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Pauses the currently playing utterance.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Registers a callback function to be called when the TTS state changes.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] callback The callback function to register
* @param[in] user_data The user data to be passed to the callback function
/**
* @brief Unregisters the callback function.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Registers a callback function to detect utterance start.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] callback The callback function to register
* @param[in] user_data The user data to be passed to the callback function
/**
* @brief Unregisters the callback function.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Registers a callback function to detect utterance completion.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] callback The callback function to register
* @param[in] user_data The user data to be passed to the callback function
/**
* @brief Unregisters the callback function.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Registers a callback function to detect errors.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] callback The callback function to register
* @param[in] user_data The user data to be passed to the callback function
/**
* @brief Unregisters the callback function.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Registers a callback function to detect default voice change.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @param[in] callback The callback function to register
* @param[in] user_data The user data to be passed to the callback function
/**
* @brief Unregisters the callback function.
- * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
+ * @since_tizen 2.3
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value
/**
* @brief Registers a callback function to detect the engine change.
- * @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
+ * @since_tizen 3.0
* @param[in] tts The TTS handle
* @param[in] callback The callback function to register
* @param[in] user_data The user data to be passed to the callback function
/**
* @brief Unregisters the callback function.
- * @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
+ * @since_tizen 3.0
* @param[in] tts The TTS handle
* @return @c 0 on success,
* otherwise a negative error value