开发者

How do I stream alaw audio?

开发者 https://www.devze.com 2023-01-12 05:58 出处:网络
I have a source that streams wav a开发者_JAVA百科udio in alaw format which I would like to receive in Android, but Android only supports linear PCM: Android Supported Media Formats

I have a source that streams wav a开发者_JAVA百科udio in alaw format which I would like to receive in Android, but Android only supports linear PCM: Android Supported Media Formats

There are a few apps on the market that stream alaw, but I'm not sure how the developers made it happen. What is the correct approach to adding this functionality?


Probably a little late, but doing 16-bit Linear PCM to 8-bit alaw or ulaw is pretty straightforward: http://en.wikipedia.org/wiki/G.711. You could either use a 256-value lookup table (probably the easiest), or implement the "algorithm" directly.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号