RETV_IF(TTS_ERROR_NONE != __tts_get_feature_enabled(), TTS_ERROR_NOT_SUPPORTED);
RETVM_IF(NULL == parameter, TTS_ERROR_INVALID_PARAMETER, "[ERROR] Input handle is null");
- RETVM_IF(0.0 > volume || 1.0 < volume, TTS_ERROR_INVALID_PARAMETER, "[ERROR] volume value(%f) is invalid.", volume);
+ RETVM_IF(0.0 > volume || 100.0 < volume, TTS_ERROR_INVALID_PARAMETER, "[ERROR] volume value(%f) is invalid.", volume);
parameter->volume = volume;
RETVM_IF(!info->connected, TTS_ERROR_IO_ERROR, "[ERROR] Not Connected");
const char *not_null_credential = NULL == credential ? "NULL" : credential;
- int ret = rpc_port_proxy_tts_invoke_add_text_with_synthesis_parameter(info->rpc_h, uid, text, parameter->language, parameter->ptts_id, parameter->voice_type, parameter->speed, parameter->pitch, parameter->volume, parameter->background_volume_ratio, uttid, not_null_credential);
+
+ char *language = (parameter->language) ? (parameter->language) : "default";
+ char *ptts_id = (parameter->ptts_id) ? (parameter->ptts_id) : "#NULL";
+
+
+ SLOG(LOG_DEBUG, TAG_TTSC, "info->rpc_h (%p)", info->rpc_h);
+ SLOG(LOG_DEBUG, TAG_TTSC, "uid (%d)", uid);
+ SLOG(LOG_DEBUG, TAG_TTSC, "text(%s)", text);
+ SLOG(LOG_DEBUG, TAG_TTSC, "parameter->language(%s), input language(%s)", (parameter->language) ? (parameter->language) : "null", language);
+ SLOG(LOG_DEBUG, TAG_TTSC, "parameter->ptts_id(%s), input ptts_id(%s)", (parameter->ptts_id) ? (parameter->ptts_id) : "null", ptts_id);
+ SLOG(LOG_DEBUG, TAG_TTSC, "parameter->voice_type (%d)", parameter->voice_type);
+ SLOG(LOG_DEBUG, TAG_TTSC, "parameter->speed (%d)", parameter->speed);
+ SLOG(LOG_DEBUG, TAG_TTSC, "parameter->pitch (%d)", parameter->pitch);
+ SLOG(LOG_DEBUG, TAG_TTSC, "parameter->volume (%f)", parameter->volume);
+ SLOG(LOG_DEBUG, TAG_TTSC, "parameter->background_volume_ratio (%f)", parameter->background_volume_ratio);
+
+ int ret = rpc_port_proxy_tts_invoke_add_text_with_synthesis_parameter(info->rpc_h, uid, text, language, ptts_id, parameter->voice_type, parameter->speed, parameter->pitch, parameter->volume, parameter->background_volume_ratio, uttid, not_null_credential);
int exception = get_last_result();
if (RPC_PORT_ERROR_NONE != exception) {
ret = __convert_and_handle_tidl_error(exception, info);
speak_data->synth_parameter.speed = speed;
speak_data->synth_parameter.pitch = pitch;
- speak_data->synth_parameter.volume = -1.0;
- speak_data->synth_parameter.background_volume_ratio = -1.0;
+ speak_data->synth_parameter.volume = volume;
+ speak_data->synth_parameter.background_volume_ratio = background_volume_ratio;
speak_data->utt_id = utt_id;
speak_data->is_silent = is_silent;
engine_info->callbacks->private_data_set = NULL;
engine_info->callbacks->private_data_requested = NULL;
engine_info->callbacks->activated_mode_changed = NULL;
+ engine_info->callbacks->set_personal_tts_id = NULL;
SLOG(LOG_DEBUG, tts_tag(), "--- Valid Engine ---");
SLOG(LOG_DEBUG, tts_tag(), "Engine uuid : %s", engine_info->engine_uuid);
ttse_foreach_supported_voices_cb foreach_voices;
ttse_is_valid_voice_cb is_valid_voice;
ttse_set_pitch_cb set_pitch;
- ttse_set_personal_tts_id_cb set_personal_tts_id;
ttse_load_voice_cb load_voice;
ttse_unload_voice_cb unload_voice;
ttse_private_data_set_cb private_data_set;
ttse_private_data_requested_cb private_data_requested;
ttse_activated_mode_changed_cb activated_mode_changed;
+ ttse_set_personal_tts_id_cb set_personal_tts_id;
} tts_engine_callback_s;
int finalize(in int uid);
int add_text(int uid, string text, string lang, int vctype, int speed, int uttid, string credential);
int add_silent_utterance(int uid, int duration_in_msec, int uttid, string credential);
- int add_text_with_synthesis_parameter(int uid, string text, in string langauge, in string ptts_id, in int voice_type, in int speed, in int pitch, in double volume, in double background_volume, int uttid, string credential);
+ int add_text_with_synthesis_parameter(int uid, string text, string langauge, string ptts_id, int voice_type, int speed, int pitch, double volume, double background_volume, int uttid, string credential);
int stop(in int uid);
int pause(in int uid);
int play_pcm(in int uid);