Info

この質問は閉じられています。 編集または回答するには再度開いてください。

Is it possible to save audio sample values from alteration while using wavwrite function?

1 回表示 (過去 30 日間)
manisha sharma
manisha sharma 2015 年 4 月 22 日
閉鎖済み: MATLAB Answer Bot 2021 年 8 月 20 日
Hello, I am manipulating values of audio samples for audio steganography.When i have my manipulated audio sample object, i want to write it as a new audio file using wavwrite. But when i create object of this newly created audio file, i find sample values different from the previous values of samples which i had manipulated.
Is there any method to control wavwrite function in order to keep my sample values as same as these were before wavwrite?
My original audio object is:
>> y=wavread('C:\Users\HIM\Desktop\audio stegno\strings.wav');
>> y(1:7)
ans =
1.0e-003 *
0
0
-0.2136
0.0916
0.3052
0.3052
0.2136
New audio object created:
>> y2=y;
>> y2(1:7)=0.0005;
>> y2(1:7)
ans =
1.0e-003 *
0.5000
0.5000
0.5000
0.5000
0.5000
0.5000
0.5000
>> wavwrite(y2,44100,'k.wav') >> s=wavread('k.wav'); >> s(1:7)
ans =
1.0e-003 *
0.4883
0.4883
0.4883
0.4883
0.4883
0.4883
0.4883
Values of samples changed in object 's'.
I want that values of samples in 's' should remain same like in 'y2'.

回答 (1 件)

Walter Roberson
Walter Roberson 2016 年 1 月 15 日

この質問は閉じられています。

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by