#Hallo, we are trying to add the elevenlabs tts streaming service to an unreal engine project. How
1 messages · Page 1 of 1 (latest)
To integrate ElevenLabs TTS streaming service into an Unreal Engine project, you can use the ElevenLabs API. Here are the general steps you can follow:
-
Get Your API Key: First, ensure you have your API key from ElevenLabs. You can find it in the 'Profile' tab on the ElevenLabs website.
-
Set Up HTTP Requests: Unreal Engine supports HTTP requests, which you can use to interact with the ElevenLabs API. You will need to set up an HTTP request to the ElevenLabs streaming endpoint.
-
Configure the Request: Configure your HTTP request with the necessary headers and parameters. Here is an example in Python to give you an idea of what needs to be done:
from elevenlabs import VoiceSettings from elevenlabs.client import ElevenLabs client = ElevenLabs( api_key="YOUR_API_KEY", ) client.text_to_speech.convert( voice_id="pMsXgVXv3BLzUgSXRplE", optimize_streaming_latency="0", output_format="mp3_22050_32", text="Your text here", voice_settings=VoiceSettings( stability=0.1, similarity_boost=0.3, style=0.2, ), ) -
Implement in Unreal Engine: Translate the above logic into Unreal Engine's Blueprints or C++ code. You will need to use Unreal's HTTP module to make the request and handle the response.
-
Stream the Audio: Once you receive the audio stream, you can play it within Unreal Engine using its audio playback capabilities.
For detailed integration, you might need to refer to Unreal Engine's documentation on HTTP requests and audio playback. Additionally, joining the ElevenLabs Discord community can be helpful for getting support from other developers who might have done similar integrations.
and what about if I'm streaming from a websocket service cloud