There seem to be a lot of questions regarding the inverse wav to mp3 conversion, but none to go the other way. My situation is that I can use steganography to embed data in wav files. I can convert these to ogg and back (the steganography is format independent, and can survive format conversion). What I want to do now is build in AudioBoo integration. Uploading to AudioBoo is not a problem, retrieving the files in mp3 format is not a problem, but converting those mp3 files back to wav to perform the steg. extraction is. Does anyone know where I should start?
Check out JLayer. It should run on Android. Beware, some of the calls are synchronized. If this doesn't work, tweak the source code or extract the converter modules from the entire source, since all you need is the mp3 to wav converter, not the mp3 player.
Related
I've been struggling to find the information on how to record an audio through a mic, save it as a mp3 or wav file (if possible) and then store it in an array using Kotlin. Does anybody know how to do that?
We're trying to upload playable audio files from PowerApps mic to SharePoint Online list.
I have used the following line:
Patch(sharepointlistname, ForAll(Gallery1.AllItems,{Title:Title, VoiceMessage:Audio});
The above returns the following results:
(from Android and iPhone, .aac and .caf links (respectively) to SharePoint List):
data/bb788abd-7848-449f-810b-2bd6368dcb19.aac
or
temp/recording_8BA1187E-158A-469E-9994-F644C6F619D8-1610-000001A0FBF5F1F0.caf
It seems impossible to convert these .aac and .caf to .wav or any playable file.
Can someone guide me on this, or maybe let me know where the actual audio files are being saved to from powerapps? The .aac or .caf links are most likely references to a specific location on a local database that is created by PowerApps. Unfortunately, I have not found any information.
aac files and caf files are audio files. They are not just your regular and familiar wav or mp3 files.
Both formats can be played by Quicktime.
You can find a list of all the programs that can play those formats here:
http://extension.nirsoft.net/caf
http://extension.nirsoft.net/aac
I have a bytearray that holds an wav audio stream.
Is there a way on android system to convert the wav file to a flac file?
I found some example code from FlacEncoder library but this library assumes as far as I see the use of some audio classes from javax.
These are not available on android.
Is there some other library or some example code for android?
Thanks!
I would like to take the music files from my phone (mp3 mostly) and convert them to raw data that FFT can be done on. Is there anyway to do this by using the android/java framework or do I need to integrate something like LAME to decode the mp3?
Your going to need LAME to decode this to a file, you could have the Android system decode it for you but it would just go to the speakers unless you used kernel hacks to allow sending it direct to file.
I'm trying to use the AudioRecord class to record a WAV file. The problem is that it only supplies the raw PCM data, and if I write it to a file, there is no header information, so it will not play in any media player. How can I create a WAV file from this raw data?
Or alternatively, is there any other way to record sound in Android to a WAV file (or, alternatively MP3)?
Oh, and I know that MediaRecorder can'y be used because it doesn't support either WAV or MP3 formats.
OK, I've got this figured out. This post was crucial in helping me:
http://computermusicblog.com/blog/2008/08/29/reading-and-writing-wav-files-in-java
Basically, I used ByteArrayOutputStream to write the raw PCM data from AudioRecord, which then lets me get the byte array and its size when the process is done. I can then use that data in conjunction with the SampleRate, BitRate, and Stereo/Mono settings to create the WAV header as per the link above. The resulting file works perfectly!
Check the MediaRecorder.setOutputFormat(), you can set different container formats for your recording; there is MediaRecorder.OutputFormat.MPEG_4 and MediaRecorder.OutputFormat.THREE_GPP; the only allowed format along RAW is setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB);
Sorry but MP3 is not avail. You really need mp3 for recording?
WAV on the opposite of MP3 is a container, not a format; WAV can be any kind of encoding format.
You are always free to prepend some WAV RIFF header in front of your raw pcm data (as long as you exactly know the format). Check here for how it has to look like:
http://www-mmsp.ece.mcgill.ca/Documents/AudioFormats/WAVE/WAVE.html
You may want to use mediarecord class