Analyzing Audio to sync with talking animation

Get help using Construct 2

Post » Sat Feb 20, 2016 5:26 pm

Is there a way to analyze the loaded audio, whether through Construct itself or plug-ins? Basically, I need to play an audio file and have the speech in that audio file control whether a character opens or closes their mouth. To do that, I decided that the game should analyze the audio file every frame and check its current amplitude (NOTE: This has nothing to do with the controllable volume level in the game itself). If the amplitude's higher or equal to a certain number, then the character would have opened their mouth. If the amplitude is below that number, then the character would have closed their mouth. So, is there a way to do it? If it can't be done through Construct itself, is there a plug-in, that could have the needed features?
B
4
S
1
Posts: 13
Reputation: 376

Post » Sat Feb 20, 2016 5:54 pm

I highly doubt this is possible with C2, but I could be wrong.
Mistakes were made.
B
51
S
25
G
107
Posts: 1,581
Reputation: 60,458

Post » Sat Feb 20, 2016 7:30 pm

Well, as I mentioned earlier, if it's not possible with Construct itself, isn't there a plug-in or something with such features?
B
4
S
1
Posts: 13
Reputation: 376

Post » Sat Feb 20, 2016 10:56 pm

You could take a look at this article https://www.scirra.com/tutorials/47/xaudio2-peak-and-rms
There is also an audio analyzer example in the default construct 2 examples. I think what you want to do would be possible, would just be a bit of work.
B
64
S
25
G
4
Posts: 204
Reputation: 6,993

Post » Sun Feb 21, 2016 8:53 pm

Yes, this is exactly what I needed! And the technique works! (Well, it's not perfect, because analyzing the Amplitude itself does not differentiate between "S" sounds and vowels, but that's because of the audio data itself) Thanks a lot! :)
B
4
S
1
Posts: 13
Reputation: 376


Return to How do I....?

Who is online

Users browsing this forum: guannstar, nahima and 22 guests