Stream Audio Via TCP

Hello all,

I am trying to build a Virtual Assistant in UE4. I need to somehow send my response from DialogFlow to UE4 for use in the Oculus Lipsync Plugin.

Basically, I have 3 media options for the response:
-16-Bit Linear PCM
-mp3
-Ogg Opus

I have a TCP Server and Client connection set up between a Python Script and UE4, so I can send data to and from easily.
I have my sequencing correct so one script waits for the full Byte Array to be sent via the socket etc.]

Basically, I want to send the responses to each Query the user sends to DialogFlow INTO UE4 Via my TCP Socket, and be able to play and access that Audio within UE4.
I need to somehow stream the response from DialogFlow into UE4 as it gives me the responses.

Is what I’m trying to do even possible? I’m just trying to stream in Audio for use within UE4 and I am really struggling to get it working. Very annoying as this is the last piece of the puzzle I need to finish…

Please let me know if you have any advice or help you can offer!

This is unfortunately not possible without adding functionality to USoundWaveProcedural and UOVRLipSyncActorComponent.

Both classes are used in different threads, so you would have to ensure that accessing USoundWaveProcedural::AudioBuffer would not cause any race-conditions.

You could for example make a copy of USoundWaveProcedural::AudioBuffer which could be accessed from the game-thread

yo bro now i’m tryna doing the exactly same thing did ya get the answer?