SLOG(LOG_WARN, TAG_STTC, "[WARNING] State changed callback is null");
}
- if(g_connect_timer) {
+ if (g_connect_timer) {
ecore_timer_del(g_connect_timer);
g_connect_timer = NULL;
}
int __stt_cb_error(int uid, int reason)
{
stt_client_s* client = stt_client_get_by_uid(uid);
- if( NULL == client ) {
+ if (NULL == client) {
SLOG(LOG_ERROR, TAG_STTC, "Handle not found");
return -1;
}
STT_INTERNAL_STATE_STARTING = 1,
STT_INTERNAL_STATE_STOPING = 2,
STT_INTERNAL_STATE_CANCELING = 3
-}stt_internal_state_e;
+} stt_internal_state_e;
typedef struct {
/* base info */
/* error data */
int reason;
-}stt_client_s;
+} stt_client_s;
typedef bool (*stt_time_cb)(int index, int event, const char* text, long start_time, long end_time, void *user_data);
response = 1;
else
response = 0;
- }
- else {
+ } else {
SLOG(LOG_ERROR, TAG_STTC, "<<<< stt get hello : invalid uid");
}
dbus_connection_flush(g_conn_listener);
dbus_message_unref(reply);
- }
- else {
+ } else {
SLOG(LOG_ERROR, TAG_STTC, ">>>> stt get hello : fail to create reply message");
}
if (uid > 0 && state >= 0) {
SLOG(LOG_DEBUG, TAG_STTC, "<<<< stt set state : uid(%d), state(%d)", uid, state);
__stt_cb_set_state(uid, state);
- }
- else {
+ } else {
SLOG(LOG_ERROR, TAG_STTC, "<<<< stt set state : invalid uid or state");
}
SLOG(LOG_DEBUG, TAG_STTC, "=====");
SLOG(LOG_DEBUG, TAG_STTC, " ");
- }/* STTD_METHOD_RESULT */
+ } /* STTD_METHOD_RESULT */
else if (dbus_message_is_signal(msg, if_name, STTD_METHOD_ERROR)) {
SLOG(LOG_DEBUG, TAG_STTC, "===== Get Error");
if (dbus_error_is_set(&err)) {
SLOG(LOG_ERROR, TAG_STTC, "<<<< stt Get Error message : Get arguments error (%s)", err.message);
dbus_error_free(&err);
- }
- else {
+ } else {
SLOG(LOG_DEBUG, TAG_STTC, "<<<< stt Get Error message : uid(%d), reason(%d), msg(%s)", uid, reason, err_msg);
__stt_cb_error(uid, reason);
}
SLOG(LOG_DEBUG, TAG_STTC, "=====");
SLOG(LOG_DEBUG, TAG_STTC, " ");
- }/* STTD_METHOD_ERROR */
+ } /* STTD_METHOD_ERROR */
else {
SLOG(LOG_DEBUG, TAG_STTC, "Message is NOT valid");
/* free the message */
dbus_message_unref(msg);
- }/* while */
+ } /* while */
return ECORE_CALLBACK_RENEW;
}
DBusMessage* result_msg = NULL;
int result = 0;
- if(g_conn_sender) {
+ if (g_conn_sender) {
result_msg = dbus_connection_send_with_reply_and_block(g_conn_sender, msg, g_waiting_short_time, &err);
dbus_message_unref(msg);
if (dbus_error_is_set(&err)) {
} else {
result = STT_ERROR_TIMED_OUT;
}
- }else {
+ } else {
SLOG(LOG_WARN, TAG_STTC, "[WARN] dbus connection handle is null (%p)", g_conn_sender);
result = STT_ERROR_OPERATION_FAILED;
}
DBusMessage* result_msg;
int result = STT_ERROR_OPERATION_FAILED;
- if(g_conn_sender) {
+ if (g_conn_sender) {
result_msg = dbus_connection_send_with_reply_and_block(g_conn_sender, msg, g_waiting_time, &err);
dbus_message_unref(msg);
if (dbus_error_is_set(&err)) {
DBUS_TYPE_STRING, &appid,
DBUS_TYPE_INVALID);
#if 1
- if(g_conn_sender) {
+ if (g_conn_sender) {
dbus_message_set_no_reply(msg, TRUE);
if (!dbus_connection_send(g_conn_sender, msg, NULL)) {
DBUS_TYPE_INT32, &uid,
DBUS_TYPE_INVALID);
#if 1
- if(g_conn_sender) {
+ if (g_conn_sender) {
dbus_message_set_no_reply(msg, TRUE);
if (!dbus_connection_send(g_conn_sender, msg, NULL)) {
DBUS_TYPE_INT32, &uid,
DBUS_TYPE_INVALID);
#if 1
- if(g_conn_sender) {
+ if (g_conn_sender) {
dbus_message_set_no_reply(msg, TRUE);
if (!dbus_connection_send(g_conn_sender, msg, NULL)) {
/* error data */
int reason;
-}stt_file_client_s;
+} stt_file_client_s;
int stt_file_client_new();
STT_CONFIG_ERROR_INVALID_LANGUAGE = TIZEN_ERROR_STT | 0x02, /**< Invalid language */
STT_CONFIG_ERROR_ENGINE_NOT_FOUND = TIZEN_ERROR_STT | 0x03, /**< No available engine */
STT_CONFIG_ERROR_OPERATION_FAILED = TIZEN_ERROR_STT | 0x04, /**< Operation failed */
-}stt_config_error_e;
+} stt_config_error_e;
typedef enum {
STT_CONFIG_TYPE_OPTION_SILENCE_DETECTION
-}stt_config_type_e;
+} stt_config_type_e;
typedef bool (*stt_config_supported_engine_cb)(const char* engine_id, const char* engine_name, const char* setting, bool support_silence, void* user_data);
char* agreement;
GSList* languages;
bool support_silence_detection;
-}stt_engine_info_s;
+} stt_engine_info_s;
typedef struct {
char* engine_id;
bool auto_lang;
char* language;
bool silence_detection;
-}stt_config_s;
+} stt_config_s;
typedef struct {
int index;
char* text;
long start_time;
long end_time;
-}stt_result_time_info_s;
+} stt_result_time_info_s;
/* Get engine information */
int stt_parser_get_engine_info(const char* path, stt_engine_info_s** engine_info);
STT_ERROR_ENGINE_NOT_FOUND = TIZEN_ERROR_STT | 0x03, /**< No available engine */
STT_ERROR_OPERATION_FAILED = TIZEN_ERROR_STT | 0x04, /**< Operation failed */
STT_ERROR_NOT_SUPPORTED_FEATURE = TIZEN_ERROR_STT | 0x05 /**< Not supported feature of current engine */
-}stt_error_e;
+} stt_error_e;
/**
* @brief Definition for free form dictation and default type.
STT_STATE_READY = 1, /**< 'READY' state */
STT_STATE_RECORDING = 2, /**< 'RECORDING' state */
STT_STATE_PROCESSING = 3 /**< 'PROCESSING' state*/
-}stt_state_e;
+} stt_state_e;
/**
* @brief Enumeration for result event.
STT_RESULT_EVENT_FINAL_RESULT = 0, /**< Event when the recognition full or last result is ready */
STT_RESULT_EVENT_PARTIAL_RESULT, /**< Event when the recognition partial result is ready */
STT_RESULT_EVENT_ERROR /**< Event when the recognition has failed */
-}stt_result_event_e;
+} stt_result_event_e;
/**
* @brief Enumeration for result time callback event.
STT_RESULT_TIME_EVENT_BEGINNING = 0, /**< Event when the token is beginning type */
STT_RESULT_TIME_EVENT_MIDDLE = 1, /**< Event when the token is middle type */
STT_RESULT_TIME_EVENT_END = 2 /**< Event when the token is end type */
-}stt_result_time_event_e;
+} stt_result_time_event_e;
/**
* @brief Enumeration for silence detection type.
STT_OPTION_SILENCE_DETECTION_FALSE = 0, /**< Silence detection type - False */
STT_OPTION_SILENCE_DETECTION_TRUE = 1, /**< Silence detection type - True */
STT_OPTION_SILENCE_DETECTION_AUTO = 2 /**< Silence detection type - Auto */
-}stt_option_silence_detection_e;
+} stt_option_silence_detection_e;
/**
* @brief A structure of STT handler.
STT_FILE_ERROR_OPERATION_FAILED = -0x0100000 | 0x34, /**< Operation failed */
STT_FILE_ERROR_NOT_SUPPORTED_FEATURE = -0x0100000 | 0x35, /**< Not supported feature of current engine */
STT_FILE_ERROR_NOT_AGREE_SERVICE = -0x0100000 | 0x36 /**< Not agreed service of engine*/
-}stt_file_error_e;
+} stt_file_error_e;
/**
* @brief Enumerations of state.
STT_FILE_STATE_NONE = 0, /**< 'NONE' state */
STT_FILE_STATE_READY = 1, /**< 'READY' state */
STT_FILE_STATE_PROCESSING = 2, /**< 'PROCESSING' state */
-}stt_file_state_e;
+} stt_file_state_e;
/**
* @brief Enumerations of audio type.
STT_FILE_AUDIO_TYPE_RAW_S16 = 0, /**< Signed 16-bit audio sample */
STT_FILE_AUDIO_TYPE_RAW_U8, /**< Unsigned 8-bit audio sample */
STT_FILE_AUDIO_TYPE_MAX
-}stt_file_audio_type_e;
+} stt_file_audio_type_e;
/**
* @brief Enumerations of result event.
STT_FILE_RESULT_EVENT_FINAL_RESULT = 0, /**< Event when the recognition full or last result is ready */
STT_FILE_RESULT_EVENT_PARTIAL_RESULT, /**< Event when the recognition partial result is ready */
STT_FILE_RESULT_EVENT_ERROR /**< Event when the recognition has failed */
-}stt_file_result_event_e;
+} stt_file_result_event_e;
/**
* @brief Enumerations of result time callback event.
STT_FILE_RESULT_TIME_EVENT_BEGINNING = 0, /**< Event when the token is beginning type */
STT_FILE_RESULT_TIME_EVENT_MIDDLE = 1, /**< Event when the token is middle type */
STT_FILE_RESULT_TIME_EVENT_END = 2 /**< Event when the token is end type */
-}stt_file_result_time_event_e;
+} stt_file_result_time_event_e;
/**
* @brief Recognition type : Continuous free dictation.
STT_SETTING_ERROR_ENGINE_NOT_FOUND = TIZEN_ERROR_STT | 0x03, /**< No available engine */
STT_SETTING_ERROR_OPERATION_FAILED = TIZEN_ERROR_STT | 0x04, /**< Operation failed */
STT_SETTING_ERROR_NOT_SUPPORTED_FEATURE = TIZEN_ERROR_STT | 0x05 /**< Not supported feature of current engine */
-}stt_setting_error_e;
+} stt_setting_error_e;
/**
* @brief Enumerations of setting state.
APP_STATE_READY = 1,
APP_STATE_RECORDING = 2,
APP_STATE_PROCESSING = 3
-}app_state_e;
+} app_state_e;
typedef struct {
int pid;
/* Ecore_Timer* timer; */
bool app_agreed;
-}client_info_s;
+} client_info_s;
typedef struct {
int index;
char* text;
long start_time;
long end_time;
-}result_time_info_s;
+} result_time_info_s;
typedef bool (*time_callback)(int index, int event, const char* text, long start_time, long end_time, void *user_data);
SLOG(LOG_DEBUG, TAG_STTD, "[Dbus] result size (%d)", data_count);
for (i = 0; i < data_count; i++) {
if (NULL != data[i]) {
- SLOG(LOG_DEBUG, TAG_STTD, "[Dbus] result (%d, %s)", i, data[i] );
+ SLOG(LOG_DEBUG, TAG_STTD, "[Dbus] result (%d, %s)", i, data[i]);
if (!dbus_message_iter_append_basic(&args, DBUS_TYPE_STRING, &data[i])) {
SLOG(LOG_ERROR, TAG_STTD, "[Dbus] response message : Fail to append result data");
//#define CLIENT_DATA_DEBUG
typedef enum {
- STTD_ERROR_NONE = TIZEN_ERROR_NONE, /**< Successful */
- STTD_ERROR_OUT_OF_MEMORY = TIZEN_ERROR_OUT_OF_MEMORY, /**< Out of Memory */
- STTD_ERROR_IO_ERROR = TIZEN_ERROR_IO_ERROR, /**< I/O error */
- STTD_ERROR_INVALID_PARAMETER = TIZEN_ERROR_INVALID_PARAMETER,/**< Invalid parameter */
- STTD_ERROR_TIMED_OUT = TIZEN_ERROR_TIMED_OUT, /**< No answer from the daemon */
- STTD_ERROR_RECORDER_BUSY = TIZEN_ERROR_RESOURCE_BUSY, /**< Device or resource busy */
- STTD_ERROR_OUT_OF_NETWORK = TIZEN_ERROR_NETWORK_DOWN, /**< Network is down */
- STTD_ERROR_PERMISSION_DENIED = TIZEN_ERROR_PERMISSION_DENIED,/**< Permission denied */
- STTD_ERROR_NOT_SUPPORTED = TIZEN_ERROR_NOT_SUPPORTED, /**< STT NOT supported */
- STTD_ERROR_INVALID_STATE = TIZEN_ERROR_STT | 0x01, /**< Invalid state */
- STTD_ERROR_INVALID_LANGUAGE = TIZEN_ERROR_STT | 0x02, /**< Invalid language */
- STTD_ERROR_ENGINE_NOT_FOUND = TIZEN_ERROR_STT | 0x03, /**< No available engine */
- STTD_ERROR_OPERATION_FAILED = TIZEN_ERROR_STT | 0x04, /**< Operation failed */
- STTD_ERROR_NOT_SUPPORTED_FEATURE= TIZEN_ERROR_STT | 0x05 /**< Not supported feature of current engine */
-}stt_error_e;
+ STTD_ERROR_NONE = TIZEN_ERROR_NONE, /**< Successful */
+ STTD_ERROR_OUT_OF_MEMORY = TIZEN_ERROR_OUT_OF_MEMORY, /**< Out of Memory */
+ STTD_ERROR_IO_ERROR = TIZEN_ERROR_IO_ERROR, /**< I/O error */
+ STTD_ERROR_INVALID_PARAMETER = TIZEN_ERROR_INVALID_PARAMETER,/**< Invalid parameter */
+ STTD_ERROR_TIMED_OUT = TIZEN_ERROR_TIMED_OUT, /**< No answer from the daemon */
+ STTD_ERROR_RECORDER_BUSY = TIZEN_ERROR_RESOURCE_BUSY, /**< Device or resource busy */
+ STTD_ERROR_OUT_OF_NETWORK = TIZEN_ERROR_NETWORK_DOWN, /**< Network is down */
+ STTD_ERROR_PERMISSION_DENIED = TIZEN_ERROR_PERMISSION_DENIED,/**< Permission denied */
+ STTD_ERROR_NOT_SUPPORTED = TIZEN_ERROR_NOT_SUPPORTED, /**< STT NOT supported */
+ STTD_ERROR_INVALID_STATE = TIZEN_ERROR_STT | 0x01, /**< Invalid state */
+ STTD_ERROR_INVALID_LANGUAGE = TIZEN_ERROR_STT | 0x02, /**< Invalid language */
+ STTD_ERROR_ENGINE_NOT_FOUND = TIZEN_ERROR_STT | 0x03, /**< No available engine */
+ STTD_ERROR_OPERATION_FAILED = TIZEN_ERROR_STT | 0x04, /**< Operation failed */
+ STTD_ERROR_NOT_SUPPORTED_FEATURE = TIZEN_ERROR_STT | 0x05 /**< Not supported feature of current engine */
+} stt_error_e;
typedef enum {
STTD_RESULT_STATE_DONE = 0, /**< Sync state change */
STTD_RESULT_STATE_NOT_DONE = 1 /**< Async state change */
-}sttd_result_state_e;
+} sttd_result_state_e;
typedef struct {
char* engine_id;
char* engine_name;
char* ug_name;
-}engine_s;
+} engine_s;
#ifdef __cplusplus
}
return STTD_ERROR_INVALID_STATE;
}
- if( 0 != pthread_mutex_init(&sttd_audio_in_handle_mutex, NULL)) {
+ if (0 != pthread_mutex_init(&sttd_audio_in_handle_mutex, NULL)) {
SLOG(LOG_ERROR, TAG_STTD, "[Recorder ERROR] Fail to initialize audio in handle mutex.");
}
int sttd_recorder_deinitialize()
{
- if( 0 != pthread_mutex_destroy(&sttd_audio_in_handle_mutex)) {
+ if (0 != pthread_mutex_destroy(&sttd_audio_in_handle_mutex)) {
SLOG(LOG_ERROR, TAG_STTD, "[Server ERROR] Fail to destroy audio in handle mutex.");
}
{
int ret = 0;
- if( 0 != pthread_mutex_init(&sttpe_result_mutex, NULL)) {
+ if (0 != pthread_mutex_init(&sttpe_result_mutex, NULL)) {
SLOG(LOG_ERROR, TAG_STTD, "[Server ERROR] Fail to initialize sttpe result mutex.");
}
- if( 0 != pthread_mutex_init(&sttpe_result_time_mutex, NULL)) {
+ if (0 != pthread_mutex_init(&sttpe_result_time_mutex, NULL)) {
SLOG(LOG_ERROR, TAG_STTD, "[Server ERROR] Fail to initialize sttpe sttpe_result_time_mutex.");
}
int sttd_finalize()
{
- if( 0 != pthread_mutex_destroy(&sttpe_result_mutex)) {
+ if (0 != pthread_mutex_destroy(&sttpe_result_mutex)) {
SLOG(LOG_ERROR, TAG_STTD, "[Server ERROR] Fail to destroy sttpe result mutex.");
}
- if( 0 != pthread_mutex_destroy(&sttpe_result_time_mutex)) {
+ if (0 != pthread_mutex_destroy(&sttpe_result_time_mutex)) {
SLOG(LOG_ERROR, TAG_STTD, "[Server ERROR] Fail to destroy sttpe_result_time_mutex.");
}
__read_proc();
- for (i = 0;i < client_count;i++) {
+ for (i = 0; i < client_count; i++) {
int pid = sttd_client_get_pid(client_list[i]);
if (0 > pid) {
SLOG(LOG_ERROR, TAG_STTD, "[ERROR] Invalid pid");
* @brief Enumerations of error codes.
*/
typedef enum {
- STTP_ERROR_NONE = 0, /**< Successful */
- STTP_ERROR_OUT_OF_MEMORY = -ENOMEM, /**< Out of Memory */
- STTP_ERROR_IO_ERROR = -EIO, /**< I/O error */
- STTP_ERROR_INVALID_PARAMETER = -EINVAL, /**< Invalid parameter */
- STTP_ERROR_OUT_OF_NETWORK = -ENETDOWN, /**< Out of network */
- STTP_ERROR_INVALID_STATE = -0x0100031, /**< Invalid state */
- STTP_ERROR_INVALID_LANGUAGE = -0x0100032, /**< Invalid language */
- STTP_ERROR_OPERATION_FAILED = -0x0100034, /**< Operation failed */
- STTP_ERROR_NOT_SUPPORTED_FEATURE= -0x0100035 /**< Not supported feature */
-}sttp_error_e;
+ STTP_ERROR_NONE = 0, /**< Successful */
+ STTP_ERROR_OUT_OF_MEMORY = -ENOMEM, /**< Out of Memory */
+ STTP_ERROR_IO_ERROR = -EIO, /**< I/O error */
+ STTP_ERROR_INVALID_PARAMETER = -EINVAL, /**< Invalid parameter */
+ STTP_ERROR_OUT_OF_NETWORK = -ENETDOWN, /**< Out of network */
+ STTP_ERROR_INVALID_STATE = -0x0100031, /**< Invalid state */
+ STTP_ERROR_INVALID_LANGUAGE = -0x0100032, /**< Invalid language */
+ STTP_ERROR_OPERATION_FAILED = -0x0100034, /**< Operation failed */
+ STTP_ERROR_NOT_SUPPORTED_FEATURE = -0x0100035 /**< Not supported feature */
+} sttp_error_e;
/**
* @brief Enumerations of audio type.
typedef enum {
STTP_AUDIO_TYPE_PCM_S16_LE = 0, /**< Signed 16bit audio type, Little endian */
STTP_AUDIO_TYPE_PCM_U8 /**< Unsigned 8bit audio type */
-}sttp_audio_type_e;
+} sttp_audio_type_e;
/**
* @brief Enumerations of callback event.
STTP_RESULT_EVENT_FINAL_RESULT = 0, /**< Event when the recognition full or last result is ready */
STTP_RESULT_EVENT_PARTIAL_RESULT, /**< Event when the recognition partial result is ready */
STTP_RESULT_EVENT_ERROR /**< Event when the recognition has failed */
-}sttp_result_event_e;
+} sttp_result_event_e;
/**
* @brief Enumerations of result time callback event.
STTP_RESULT_TIME_EVENT_BEGINNING = 0, /**< Event when the token is beginning type */
STTP_RESULT_TIME_EVENT_MIDDLE, /**< Event when the token is middle type */
STTP_RESULT_TIME_EVENT_END /**< Event when the token is end type */
-}sttp_result_time_event_e;
+} sttp_result_time_event_e;
/**
* @brief Enumerations of silence type.
typedef enum {
STTP_SILENCE_TYPE_NO_RECORD_TIMEOUT = 0, /**< No sound is recorded */
STTP_SILENCE_TYPE_END_OF_SPEECH_DETECTED /**< End of speech is detected */
-}sttp_silence_type_e;
+} sttp_silence_type_e;
/**
* @brief Recognition type : free form dictation and default type.
*
* @see sttpe_deinitialize()
*/
-typedef int (* sttpe_initialize)(sttpe_result_cb result_cb, sttpe_silence_detected_cb silence_cb);
+typedef int (*sttpe_initialize)(sttpe_result_cb result_cb, sttpe_silence_detected_cb silence_cb);
/**
* @brief Deinitializes the engine
*
* @see sttpe_initialize()
*/
-typedef int (* sttpe_deinitialize)(void);
+typedef int (*sttpe_deinitialize)(void);
/**
* @brief Retrieves all supported languages of the engine.
*
* @see sttpe_supported_language_cb()
*/
-typedef int (* sttpe_foreach_supported_langs)(sttpe_supported_language_cb callback, void* user_data);
+typedef int (*sttpe_foreach_supported_langs)(sttpe_supported_language_cb callback, void* user_data);
/**
* @brief Checks whether a language is valid or not.
*
* @see sttpe_foreach_supported_languages()
*/
-typedef bool (* sttpe_is_valid_language)(const char* language);
+typedef bool (*sttpe_is_valid_language)(const char* language);
/**
* @brief Gets whether the engine supports silence detection.
*
* @see sttpe_set_silence_detection()
*/
-typedef bool (* sttpe_support_silence_detection)(void);
+typedef bool (*sttpe_support_silence_detection)(void);
/**
* @brief Gets supporting recognition type.
* @return @c true to support recognition type, \n @c false not to support recognition type.
*
*/
-typedef bool (* sttpe_support_recognition_type)(const char* type);
+typedef bool (*sttpe_support_recognition_type)(const char* type);
/**
* @brief Gets recording format of the engine.
* @retval #STTP_ERROR_NONE Successful
* @retval #STTP_ERROR_INVALID_STATE Not initialized
*/
-typedef int (* sttpe_get_recording_format)(sttp_audio_type_e* types, int* rate, int* channels);
+typedef int (*sttpe_get_recording_format)(sttp_audio_type_e* types, int* rate, int* channels);
/**
* @brief Sets silence detection option.
* @retval #STTP_ERROR_INVALID_STATE Not initialized
* @retval #STTP_ERROR_NOT_SUPPORTED_FEATURE Not supported feature
*/
-typedef int (* sttpe_set_silence_detection)(bool value);
+typedef int (*sttpe_set_silence_detection)(bool value);
/**
* @brief Gets whether application is agreed to get engine service.
* @retval #STTP_ERROR_INVALID_STATE Not initialized
* @retval #STTP_ERROR_NOT_SUPPORTED_FEATURE Not supported feature
*/
-typedef int (* sttpe_check_app_agreed)(const char* appid, bool* value);
+typedef int (*sttpe_check_app_agreed)(const char* appid, bool* value);
/**
* @brief Retrieves result time info in recognition callback of daemon.
*
* @see sttpe_result_time_cb()
*/
-typedef int (* sttpe_foreach_result_time)(void* time_info, sttpe_result_time_cb callback, void* user_data);
+typedef int (*sttpe_foreach_result_time)(void* time_info, sttpe_result_time_cb callback, void* user_data);
/**
* @brief Start recognition.
* @see sttpe_stop()
* @see sttpe_cancel()
*/
-typedef int (* sttpe_start)(const char* language, const char* type, void *user_data);
+typedef int (*sttpe_start)(const char* language, const char* type, void *user_data);
/**
* @brief Sets recording data for speech recognition from recorder.
* @see sttpe_cancel()
* @see sttpe_stop()
*/
-typedef int (* sttpe_set_recording_data)(const void* data, unsigned int length);
+typedef int (*sttpe_set_recording_data)(const void* data, unsigned int length);
/**
* @brief Stops to set recording data.
* @see sttpe_result_cb()
* @see sttpe_cancel()
*/
-typedef int (* sttpe_stop)(void);
+typedef int (*sttpe_stop)(void);
/**
* @brief Cancels the recognition process.
* @see sttpe_start()
* @see sttpe_stop()
*/
-typedef int (* sttpe_cancel)(void);
+typedef int (*sttpe_cancel)(void);
/**
* @brief Start recognition of file.
*
* @see sttpe_cancel_file()
*/
-typedef int (* sttpe_start_file)(const char* language, const char* type, const char* filepath,
+typedef int (*sttpe_start_file)(const char* language, const char* type, const char* filepath,
sttp_audio_type_e audio_type, int sample_rate, void *user_data);
/**
*
* @see sttpe_start_file()
*/
-typedef int (* sttpe_cancel_file)(void);
+typedef int (*sttpe_cancel_file)(void);
/**
* @brief A structure of the engine functions.
ecore_timer_add(0, __stt_finalize, NULL);
}
-int main (int argc, char *argv[])
+int main(int argc, char *argv[])
{
if (2 > argc) {
SLOG(LOG_DEBUG, TAG_STT_TEST, "Please check parameter");