Closed SalahuddinAsh closed 7 months ago
It is a big mistake to multiply unencoded MP3 data with a values! You can only adjust the volume on PCM data with the help of multiply as described in the Wiki.
I would recommend to use a VolumeStream e.g. with the newly supported pipelines
You could also change the input chain so that you copy the decoded data: MemoryStream -> EncodedAudioStream - copy -> I2SStream
Thanks for your quick response. I have no idea about the audio concept and I only use an example code from your great library.
Therefore I would be grateful if you give me a link for an example or document to explain what you mean with VolumeStream and the newly supported pipelines.
Also, does changing the input change will allow me to change the volume?
Thanks
I'll try going through your blog to learn more about the library.
Problem Description
I'm trying to control the volume of an mp3 music saved as a memorystream.
Setting volume to 1.0 works and the audio get played. but setting it to other values between 0 and 1 makes the audio not get played. I'm not sure how to control volume here.
I checked the wiki page for set-volume but it doesn't explain how to use it for memorystream: https://github.com/pschatzmann/arduino-audio-tools
I checked this issue # 17 but don't understand how to use it in my case. https://github.com/pschatzmann/arduino-audio-tools/issues/17
Device Description
esp32-s3
Sketch
Other Steps to Reproduce
No response
What is your development environment
No response
I have checked existing issues, discussions and online documentation