google / ExoPlayer

This project is deprecated and stale. The latest ExoPlayer code is available in https://github.com/androidx/media
https://developer.android.com/media/media3/exoplayer
Apache License 2.0
21.7k stars 6.02k forks source link

Support wma format #2155

Open Mihuilk opened 7 years ago

Mihuilk commented 7 years ago

Hi. I'm working on audio streaming project and I find that there is no built in support for Windows Media Audio (wma) audio coding formats developed by Microsoft. I tried to use ffmpeg extension decoders for handling WMA but there is no built in Extractor for it. (this format supported by Google Play Music app). What are the best practice for this case?

ojw28 commented 7 years ago

I think it would be necessary to implement a WMA extractor to support this case.

I'm not convinced this is supported by Google Play Music on all devices though, since WMA isn't mentioned on Android's supported formats page, and as far as I know Google Play Music simply calls through to the underlying platform functionality. I tried playing a WMA file in Google Play Music on Pixel, and playback fails. Are you sure this support isn't on a subset of devices only (i.e. where the device manufacturer has opted to add WMA support as an additional feature)?

Mihuilk commented 7 years ago

Thank you for fast replay. You're right. It works for me on Samsung Galaxy Note 4 but WMA isn't mentioned on Android's supported formats page. The problem that implement WMA extractor by myself no so easy. Still waiting for ExoPlayer built in implementation.

ojw28 commented 7 years ago

The good news, I guess, is that if we did implement a WMA extractor then it would provide support across all devices. It's low priority for us, however.

yotonishi commented 7 years ago

Hi. Google play music supports wma. https://support.google.com/googleplay/answer/1100462

I challenged fmmpeg to play wma but it was useless. I hope to be able to play wma in Exoplayer. Thank you.

ojw28 commented 7 years ago

@otnvshi - That page doesn't say that Google Play Music supports playback of WMA on Android devices. It's saying is that you can upload WMA, which is different. The file is almost certainly transcoded to MP3 at time of upload, and subsequent streaming playbacks will be of the MP3 rather than the original WMA file. Direct playback of WMA files is not supported on Android, as outlined above.