New Audio API [Beta]: Elevate Sound and Voice in Your Experiences

We need like a settable table value for players the Emitter will ignore so we don’t hear our own voice.

3 Likes

I’m turning on the Audio API stuff, and i’ll share my thoughts once i get a grip of how it works

2 Likes

How do i get the new AudioAPI system to work? I want an AudioPlayer to play a sound through an AudioDeviceOutput with Wire.

2 Likes

I also planned to use it to display how many devices/wires are connected to each channel of my intercom system.

4 Likes

I’ve been trying that and it does not seem to work at all. The audio is still being modified by only one audio effect instance rather than a batch of them. Changing the volume of the AudioFader seems to produce weird effects too. Changing volume to higher than 1 will simply negate the effects of any audio effects while going below 1 will shift the audio to only one ear and accentuate the actual singular sound effects. The volume being set at 0 will still have audio playing, just on one ear.

Another issue i’ve found is just being unable to play with all audio properties and have them influence the audio stream in real time.

3 Likes

Have there been any changes to the sound engine since this announcement? Changing TimePosition has significant delay, causing problems with the audio in all my games; both in the studio and live versions. This issue wasn’t occurring before January of this year if I recall correctly.

This has been brought up on the devforums before but hasn’t gotten any attention:
Sound play Delay after TimePosition change - Help and Feedback / Creations Feedback - Developer Forum | Roblox

3 Likes

This was a really needed update, I am excited for the outcome of games with communications

3 Likes

That looks like fun to mess around with. Nice update !

3 Likes
  1. asset id’s don’t autofill in the audioplayer (haven’t tested with other instances)
  2. setting up the provided tutorial in this thread for the PA system in a place, hitting run, and moving around the audiolistener causes slight lag
  3. how to customize rolloff?

how performant is this? i’d like to use this in 100 player experiences and seeing as i have to link everything up with instances as opposed to just sound:Play()

2 Likes

Yes thank you for this question!!! Just what we needed, more audio/vc moderation!!

3 Likes

Lots of really exciting new features to play with!

Are there any plans to integrate speech recognition and/or text-to-speech into Roblox in the future? I think they’d fit right in with the direction this new API is taking the platform, and there’d be a lot of really fun use cases.

4 Likes

I agree, these are cool feature ideas, but they are by no means simple to implement in a safe and performant way and will take some work. But we’re glad to hear you want them!

4 Likes

Will these include instances for further manipulation or even temporary caching of sounds? I don’t really know what further manipulation would entail, but being able to record and replay sounds at a later date would allow for experiences such as ones to create music using audio samples, etc.
There may need to be additional safeties, such as these sounds being temporary and having no way to save via datastore.

I am less interested in the Voice Chat features and more interested in the audio manipulation features and how they can be used to create music-making experiences.

2 Likes

Is Voice Chat supposed to be disabled in studio? Maybe it’s just on my end, but I’m not getting a microphone icon (the one above the head) when testing in studio although I get one in game. It’s impractical to run tests concerning these new changes without this capability.

Edit: Had to manually enable the Active property on AudioDeviceInput under the player, my microphone works as expected now while in studio. I’m assuming this is unintentional.

image

2 Likes

put this in a localscript in game.StarterPlayer.StarterPlayerScripts

--// Some variables

local player = game.Players.LocalPlayer

--// Turning off the ability to hear our own VC (other players can still hear you)

player.CharacterAdded:Connect(function(char)
	char:WaitForChild("AudioEmitter").AudioInteractionGroup = "MyVoicechat"
end)

--// Setting up the Audio to our camera, so that we can hear AudioAPI objects.

local Listener = Instance.new("AudioListener",workspace.CurrentCamera)
local Output = Instance.new("AudioDeviceOutput",Listener)
local wire = Instance.new("Wire",Listener)

Listener.Name = "CameraAudioListener"
Output.Name = "AudioOutput"
wire.Name = "AudioRoute"

wire.SourceInstance = Listener
wire.TargetInstance = Output
4 Likes

Should def add a Speech > Voice type thing so we can like detect bad words, or give an NPC a command. Even chat GPT games would be cool.

3 Likes
  1. asset id’s don’t autofill in the audioplayer (haven’t tested with other instances)

This was not intended; a fix should start rolling out in the coming weeks. Unfortunately it’ll take a while to fully release – accidentally made the type of AudioPlayer.AssetId a string when it should’ve been Content, and updating that impacts replication & serialization :skull:

  1. setting up the provided tutorial in this thread for the PA system in a place, hitting run, and moving around the audiolistener causes slight lag

That is surprising – in our testing, one AudioPlayer, one AudioEmitter, and one AudioListener performs comparably to one Sound. If you’ve got a microprofiler capture during the laggy frames that you can share, that may help diagnose

  1. how to customize rolloff?

I mentioned in a previous reply that this is at the top of our list for improvements – in fact we are actively workshopping an API update

4 Likes

Is there any ETA when AudioAnalyzer:GetSpectrum will get fixed? We would like to use it in Tower Defense Simulator, for one of our Towers, but I find it kinda odd it was disabled in its entirety.

5 Likes

Will this be needed to create any type of sound or does the old audio api stay?

@ReallyLongArms I appreciate this update and decided to put it in my game for the Freddy Fazbear reference, but I have found a bug, since you mentioned this in the original post:

but It does not get automatically filled in until I tamper with the AutoLoad property, Here is the video of the issue to help you understand what I mean:

Hopefully this bug gets fixed. Thanks for reading

The old audio api most likely will stay, There’s nothing to worry

1 Like