Framework for audio spectrogram visualizer

Finally got around to messing with the new AudioAnalyzer, AudioPlayer, And Wire’s and threw this together within 2 hours or so for anyone wondering you can make this by console only atm as its not possible to make within the explorer so you’d set it up in console like so:

local AudioPlayer = Instance.new("AudioPlayer")
local AudioAnalyzer = Instance.new("AudioAnalyzer")
local Wire = Instance.new("Wire")

Wire.SourceInstance = AudioPlayer
Wire.TargetInstance = AudioAnalyzer

AudioPlayer.Parent = workspace
AudioAnalyzer.Parent = AudioPlayer 
Wire.Parent = AudioPlayer

Then in a local script you would take any array of parts or frames and align them to the AudioAnalyzer’s spectrogram with :GetSpectrogram()

Here’s it in action:

And one more where you get to see it do alot more:

Hope to hear some thoughts on this!

9 Likes

I don’t think the videos you attached are working

You gotta click on them sadly cant embed them with the built in forum embed due to their size and they recommended i use another file host

i did, still didnt work ,.,.,.,.,.,.

What did you do to make the audio play through for you? I can’t seem to get it to play the audio. I checked through docs, but they do something else.

You need to link a AudioDeviceOutput. Funnily enough, you cant use a wire to split an audio stream, so really you should just play the audio in SoundService using a Sound instance.
If you insist on only using the new audio API though, you can wire the AudioPlayer into an AudioEmitter, create two AudioListener s that overlap the emitter, and separately wire them into the AudioAnalyzer, and AudioOutputDevice.

I was able to get it to link properly. Thanks though

1 Like

How would I do this with an audioDeviceInput. I’m new to the roblox audio API so I need some help. Can you tell me how to do it?