Perform the text to speech synthesis operation for the SSML text from the specified URL.
Function
- LV_TTS_RETURN_CODE LV_TTS_SynthesizeURL(HTTSCLIENT client_handle, const char * universal_resource_locator, unsigned int flags);
Parameters
client_handle
Handle to the active TTS client object.
universal_resource_locator
URL containing a simple sequence of words/sentences or an SSML document.
Ideally, the referenced document should be encoded in UTF-8 format
This URL can be a file system reference, or remote HTTP reference, and as of LumenVox version 11.2.100, users may also specify resources located on secure HTTPS servers
flags
Used to control certain facets of the operation. Mostly unused in the current implementation besides LV_TTS_BLOCK. Setting the LV_TTS_BLOCK bit in flags causes the call to wait for a response back from the TTS server before returning. If the LV_TTS_BLOCK flag is not specified, the synthesis will be performed in non-blocking mode, and calls to LV_TTS_WaitForSynthesis can be used to determine when the synthesis operation has completed.
Return Values
LV_SUCCESS
No errors; synthesis succeeded.
LV_INVALID_TTS_HANDLE
The input TTS client handle is not a valid one.
LV_NO_COMPATIBLE_TTS_SERVERS
Either none of the connected TTS servers carry a voice corresponding to the requested features, or no TTS servers are available at the time.
LV_ACQUIRING_LICENSE_FAILED
Either failed to switch license type based on the currently set voice properties or failed to acquire any additionally needed licenses.
LV_EXPIRED_LICENSE
The acquired license(s) do not permit using the current version of the TTS server.
LV_INVALID_LICENSE_MAINT_DATE
The maintenance date of the available license(s) is/are invalid.
LV_INVALID_CLIENT_OBJECT
The internal representation of the client_handle is corrupted.
LV_NO_TTS_SERVERS
Not connected to any TTS server yet.
LV_EXCEPTION
An exception occurred while processing the request.
-- -- The following values may be returned only when blocking synthesis is performed. -- --
LV_SSML_ERROR
The specified SSML had syntax error(s).
LV_RESOURCE_ERROR
The TTS server is out of resources, or no voices have been loaded.
LV_FAILED_NO_VOICE_SPECIFIED
There was an error in the request, no voices were specified.
LV_FAILED_VOICE_LOAD
The TTS server failed to load one or more of the required voices.
LV_FAILED_SYNTHESIS
The input was neither plain text nor SSML; or the conversion of input SSML to UTF-8 format failed.
LV_FAILED_STREAMER
An exception occurred on the TTS server while processing the specified SSML.
LV_FAILED_AUDIO_CONVERSION
Conversion of the synthesized audio to the requested sound format and/or sampling rate has failed.
LV_TIME_OUT
The synthesis request timed out.