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

Commit 2192648b authored by Jean-Michel Trivi's avatar Jean-Michel Trivi Committed by android-build-merger
Browse files

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

am: 364d2515

Change-Id: I4950fe018d72ab32a04eafd397ae3ed276f44184
parents 388485d0 364d2515
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");
                }
            }