Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 364d2515 authored by Jean-Michel Trivi's avatar Jean-Michel Trivi Committed by Android (Google) Code Review
Browse files

Merge "AudioTrack: offload is not tied to USAGE_MEDIA" into qt-dev

parents b5b73121 4ad4600d
Loading
Loading
Loading
Loading
+1 −5
Original line number Diff line number Diff line
@@ -975,13 +975,9 @@ public class AudioTrack extends PlayerBase
                    throw new UnsupportedOperationException(
                            "Offload and low latency modes are incompatible");
                }
                if (mAttributes.getUsage() != AudioAttributes.USAGE_MEDIA) {
                    throw new UnsupportedOperationException(
                            "Cannot create AudioTrack, offload requires USAGE_MEDIA");
                }
                if (!AudioSystem.isOffloadSupported(mFormat, mAttributes)) {
                    throw new UnsupportedOperationException(
                            "Cannot create AudioTrack, offload format not supported");
                            "Cannot create AudioTrack, offload format / attributes not supported");
                }
            }