Is it possible to get the volume of audio?

Hey,

I am looking to get the volume of my audio track. Not the set volume, but the ‘loudness’ - if that makes sense? So if I were to move something based on the loudness of the track it would move up and down, depending on the sound.

I can get the overall volume, but how do you get the perceived volume? Or is this not possible?

Thanks

Loudness is an subjective measurement of sound, Meaning that one person can perceive it different from another, depending on hearing loss etc. So I would say it is going to be very difficuilt and the closest you will get to that is to look at allt the audiosources playing at one time, do a calculation on the output of those. But even that wont give you an accurate measurement on the sound you are testing, since the actual amplitude of the individual wav sources might be different.

analyzing sound: