
to change the amplitude of a .wav file
12 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Femi Okome
il 14 Dic 2022
Commentato: Image Analyst
il 15 Dic 2022
I am new to Matlab and im trying to change the amplitude of a .wav file. i have exported the data and Fs. i just dont know how to now increase/decreas the aplitude of the wav.
the code below shows what i have done,
thanks for any advice given.
plot(data);
soundsc(data,fs);
0 Commenti
Risposta accettata
Image Analyst
il 14 Dic 2022
Try multiplying by a scaling factor:
amplificationFactor = 1.1; % Ten percent gain.
data = data * amplificationFactor;
plot(data);
sound(data, fs);
You might be interested in my File Exchange entry that allows you to plot the waveforms of all the files in a folder:
https://www.mathworks.com/matlabcentral/fileexchange/72431-plot-audio-file-waveforms?s_tid=srchtitle

2 Commenti
Image Analyst
il 15 Dic 2022
You probably need to square the signal to get power then use the formula here:
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Audio I/O and Waveform Generation in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!