Move unreleased definitions to the internal header 19/293219/1
authorSuyeon Hwang <stom.hwang@samsung.com>
Tue, 18 Apr 2023 02:39:17 +0000 (11:39 +0900)
committerSuyeon Hwang <stom.hwang@samsung.com>
Tue, 23 May 2023 02:22:36 +0000 (11:22 +0900)
Change-Id: I4746d219d5385713b278bca58abf9115061837c3
Signed-off-by: Suyeon Hwang <stom.hwang@samsung.com>
client/tts_client.h
include/tts.h
include/tts_internal.h

index 4faebc065f1ca5086ead85d151488a6de8d4b58f..1a7d04689b33489410b200c62ba592409b07ac33 100644 (file)
@@ -18,6 +18,7 @@
 #include <Ecore.h>
 
 #include "tts.h"
+#include "tts_internal.h"
 #include "tts_config_mgr.h"
 #include "tts_main.h"
 
index 985d63870a2f370ec6ee2249c26148adfc493339..f337fcbaee855eb491c88ff204b6db8506bb2344 100644 (file)
@@ -96,18 +96,6 @@ typedef enum {
 } tts_service_state_e;
 
 
-/**
- * @brief Enumeration for synthesized pcm event.
- * @since_tizen 7.5
-*/
-typedef enum {
-       TTS_SYNTHESIZED_PCM_EVENT_FAIL = -1, /**< 'Error' event */
-       TTS_SYNTHESIZED_PCM_EVENT_START, /**< 'Started' event */
-       TTS_SYNTHESIZED_PCM_EVENT_CONTINUE, /**< 'Finished' event */
-       TTS_SYNTHESIZED_PCM_EVENT_FINISH, /**< 'Finished' event */
-} tts_synthesized_pcm_event_e;
-
-
 /**
  * @brief Definition for automatic speaking speed.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
@@ -281,22 +269,6 @@ typedef void (*tts_screen_reader_changed_cb)(tts_h tts, bool is_on, void* user_d
 typedef void (*tts_service_state_changed_cb)(tts_h tts, tts_service_state_e previous, tts_service_state_e current, void* user_data);
 
 
-/**
- * @brief Called when the synthesized pcm data is come from the engine.
- * @since_tizen 7.5
- * @remarks The @a tts handle should not be destroyed in the callback.
- * @param[in] tts The TTS handle, the same handle for which the callback was set.
- * @param[in] event The event type
- * @param[in] buffer The synthesized pcm data
- * @param[in] buffer_size The size of the buffer
- * @param[in] user_data The user data passed from the callback registration function
- * @pre An application registers this callback using tts_set_synthesized_pcm_cb() to get pcm data.
- * @see tts_set_synthesized_pcm_cb()
- * @see tts_unset_synthesized_pcm_cb()
- */
-typedef void (*tts_synthesized_pcm_cb)(tts_h tts, tts_synthesized_pcm_event_e event, char* buffer, int buffer_size, void *user_data);
-
-
 /**
  * @brief Creates a handle for TTS.
  * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
@@ -1042,41 +1014,6 @@ int tts_set_service_state_changed_cb(tts_h tts, tts_service_state_changed_cb cal
 */
 int tts_unset_service_state_changed_cb(tts_h tts);
 
-
-/**
- * @brief Sets the default to be called when the synthesized pcm data is recieved.
- * @since_tizen 7.5
- * @param[in] tts The TTS handle
- * @param callback The callback function to register
- * @param user_data The user data to be passed to the callback function
- * @return @c 0 on success,
- *                otherwise a negative error value
- * @retval #TTS_ERROR_NONE Successful
- * @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported
- * @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #TTS_ERROR_INVALID_STATE Invalid state
- * @pre The TTS state should be #TTS_STATE_CREATED.
- * @see tts_synthesized_pcm_cb()
- * @see tts_unset_synthesized_pcm_cb()
- */
-int tts_set_synthesized_pcm_cb(tts_h tts, tts_synthesized_pcm_cb callback, void* user_data);
-
-
-/**
- * @brief Unsets the callback function.
- * @since_tizen 7.5
- * @param tts The TTS handle
- * @return @c 0 on success,
- *                otherwise a negative error value
- * @retval #TTS_ERROR_NONE Successful
- * @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported
- * @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #TTS_ERROR_INVALID_STATE Invalid state
- * @pre The TTS state should be #TTS_STATE_CREATED.
- * @see tts_set_synthesized_pcm_cb()
-  */
-int tts_unset_synthesized_pcm_cb(tts_h tts);
-
 #ifdef __cplusplus
 }
 #endif
index ab07e2452c2545adc535055f0d3a1c4ad8dc033d..0aeee265f063cb7a8522ad12396b1896d75690c2 100644 (file)
@@ -27,11 +27,41 @@ extern "C"
 {
 #endif
 
+
+/**
+ * @brief Enumeration for synthesized pcm event.
+ * @since_tizen 7.5
+*/
+typedef enum {
+       TTS_SYNTHESIZED_PCM_EVENT_FAIL = -1, /**< 'Error' event */
+       TTS_SYNTHESIZED_PCM_EVENT_START, /**< 'Started' event */
+       TTS_SYNTHESIZED_PCM_EVENT_CONTINUE, /**< 'Finished' event */
+       TTS_SYNTHESIZED_PCM_EVENT_FINISH, /**< 'Finished' event */
+} tts_synthesized_pcm_event_e;
+
+
 /**
  * @brief Definition for TTS interrupt mode
  */
 #define TTS_MODE_INTERRUPT             3
 
+
+/**
+ * @brief Called when the synthesized pcm data is come from the engine.
+ * @since_tizen 7.5
+ * @remarks The @a tts handle should not be destroyed in the callback.
+ * @param[in] tts The TTS handle, the same handle for which the callback was set.
+ * @param[in] event The event type
+ * @param[in] buffer The synthesized pcm data
+ * @param[in] buffer_size The size of the buffer
+ * @param[in] user_data The user data passed from the callback registration function
+ * @pre An application registers this callback using tts_set_synthesized_pcm_cb() to get pcm data.
+ * @see tts_set_synthesized_pcm_cb()
+ * @see tts_unset_synthesized_pcm_cb()
+ */
+typedef void (*tts_synthesized_pcm_cb)(tts_h tts, tts_synthesized_pcm_event_e event, char* buffer, int buffer_size, void *user_data);
+
+
 /**
  * @brief Sets server tts.
  * @details Using this API, the application can ask server tts with a credential.
@@ -121,6 +151,41 @@ int tts_play_pcm(tts_h tts);
 int tts_stop_pcm(tts_h tts);
 
 
+/**
+ * @brief Sets the default to be called when the synthesized pcm data is recieved.
+ * @since_tizen 7.5
+ * @param[in] tts The TTS handle
+ * @param callback The callback function to register
+ * @param user_data The user data to be passed to the callback function
+ * @return @c 0 on success,
+ *                otherwise a negative error value
+ * @retval #TTS_ERROR_NONE Successful
+ * @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported
+ * @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #TTS_ERROR_INVALID_STATE Invalid state
+ * @pre The TTS state should be #TTS_STATE_CREATED.
+ * @see tts_synthesized_pcm_cb()
+ * @see tts_unset_synthesized_pcm_cb()
+ */
+int tts_set_synthesized_pcm_cb(tts_h tts, tts_synthesized_pcm_cb callback, void* user_data);
+
+
+/**
+ * @brief Unsets the callback function.
+ * @since_tizen 7.5
+ * @param tts The TTS handle
+ * @return @c 0 on success,
+ *                otherwise a negative error value
+ * @retval #TTS_ERROR_NONE Successful
+ * @retval #TTS_ERROR_NOT_SUPPORTED TTS NOT supported
+ * @retval #TTS_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #TTS_ERROR_INVALID_STATE Invalid state
+ * @pre The TTS state should be #TTS_STATE_CREATED.
+ * @see tts_set_synthesized_pcm_cb()
+  */
+int tts_unset_synthesized_pcm_cb(tts_h tts);
+
+
 
 #ifdef __cplusplus
 }