Hi there Theera.
Take a look at this page:
https://ccrma.stanford.edu/courses/422/projects/WaveFormat/.
A WAV file consists of 44 bytes of 'header' data that describe the audio data, then bytes 45 onwards are the actual audio data.
So in theory you could use InputStreams and OutputStreams to combine all audio data from more than 1 WAV file into a single new file.
BUT the new file would just be a large collection of bytes, without a WAV header (the 44 bytes mentioned above) the new file would not actually be a WAV file.
If your plan is to play the combined audio data using AudioTrack then that is not a problem - you'd pass all the combined audio data bytes to AudioTrack and it would play, there'd be no need to create a true WAV file with the WAV header information.
If however you plan to save the combined audio data as a WAV (for example you'd need a WAV file to encode it to MP3) then you need some way to create a WAV file with the correct header data...
libwave could probably do that for you.
It's a java/android library which i have already partly converted to a B4A library when i created the B4A liblame library.
It wouldn't take me much time to finish off the B4A libwave library but i won't do so unless it is required - i have other things to spend my time on that have higher priority.
In fact rather than using the existing B4A liblame library and then requiring the libwave library, it might be better for your project to take the liblame libary and create new methods to do exactly as you require.
Imagine a single new liblame method that accepts an array of input filenames (the MP3s to decode and join) and an output filename.
The new method would decode each MP3 adding the decoded audio bytes of each decoded MP3 to a
ByteArrayOutputStream.
Once all MP3s have been decoded the new method would have all the combined audio data available in the ByteArrayOutputStream.
So the method could return a Byte array, create a WAV file (with correct header) from the decoded bytes or even encode the combined decoded bytes back to an MP3.
The big advantage of creating a new method to do exactly as your app requires is that it will much better handle large amounts of audio data and make 'out of memory' problems less likely to occur.
Have a read of what i have written and if you can give me a better idea of what you require i'll see what i can do.
One thing though is to make sure that the MP3s that you are using can actually be decoded by the liblame decoder, if you read the liblame thread you'll see that it doesn't always successfully decode all MP3s.
It all depends on how the MP3 has been encoded - bitrate, sample rate and number of channels.
So if you have time to grab the liblame demo project and try to decode some of your Mp3s then post with your results then we'll know whether liblame is of any use here.
Martin.