这个类提供了对于音频文件的描述 An audio stream is a continuous series of data that represents a sound, such as a song. A channel is a discrete track of monophonic audio. A monophonic stream has one channel; a stereo stream has two channels. A sample is single numer…
前言: 上次我们介绍了实时采集音频数据以及播放,今天我们来认识一下直接录制文件的方式. 直接上代码:录制管理类 public class MediaRecorderManager { public static final String TAG = "Recorder"; private MediaRecorder mRecorder; private static MediaRecorderManager mInstance; public MediaRecorderManager(…
前言: 其实在Android中录音可以用MediaRecord录音,操作比较简单.但是不能对音频进行处理.考虑到项目中做的是实时语音只能选择AudioRecord进行录音.然后实时播放也只能采用AudioTrack进行播放. 下文为具体实现: public class AudioTrackManager { public static final String TAG = "AudioTrackManager"; private AudioTrack audioTrack; priva…