Android Framwrork bluetooth A2DP + HDMI

610 views Asked by At

We are developing the Android Framework, and the default of the audio output is HDMI. When the bluetooth is connected with the Android, the audio output will be redirected to the bluetooth via A2DP protocol. How can we route the audio to the bluetooth speaker and the HDMI output at the same time? We have looked framework/base/media/java/android/media/AudioService.java and the frameworks/av/services/audioflinger/AudioFlinger.cpp, but I have no idea now. Does someone has the experience? Thanks!

1

There are 1 answers

1
Jon Carlstedt On BEST ANSWER

I am quite certain that this is not possible to do. I am completely convinced that this is something that you shouldn't do. When you send audio over A2DP it is re-encoded, it is not the same audio stream that the one you send over HDMI. They will also be out of sync, since you have completely different delays between A2DP and HDMI.