mirror of
https://github.com/Evolution-X/hardware_interfaces
synced 2026-02-02 06:22:53 +00:00
audio VTS: CompressedOffloadOutputStream to check the vendor API level am: 3f2e330990 am: b9b5652fcc am: 56c53559a8
Original change: https://googleplex-android-review.googlesource.com/c/platform/hardware/interfaces/+/19340462 Change-Id: I043be6351fa907db1126e1a445f9066e3f2874b4 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
#include <numeric>
|
||||
|
||||
#include <android-base/chrono_utils.h>
|
||||
#include <cutils/properties.h>
|
||||
|
||||
#include "Generators.h"
|
||||
|
||||
@@ -900,10 +901,16 @@ class CompressedOffloadOutputStreamTest : public PcmOnlyConfigOutputStreamTest {
|
||||
TEST_P(CompressedOffloadOutputStreamTest, Mp3FormatGaplessOffload) {
|
||||
doc::test("Check that compressed offload mix ports for MP3 implement gapless offload");
|
||||
const auto& flags = getOutputFlags();
|
||||
const bool isNewDeviceLaunchingOnTPlus = property_get_int32("ro.vendor.api_level", 0) >= 33;
|
||||
if (std::find_if(flags.begin(), flags.end(), [](const auto& flag) {
|
||||
return flag == toString(xsd::AudioInOutFlag::AUDIO_OUTPUT_FLAG_GAPLESS_OFFLOAD);
|
||||
}) == flags.end()) {
|
||||
GTEST_SKIP() << "Compressed offload mix port does not support gapless offload";
|
||||
if (isNewDeviceLaunchingOnTPlus) {
|
||||
FAIL() << "New devices launching on Android T+ must support gapless offload, "
|
||||
<< "see VSR-4.3-001";
|
||||
} else {
|
||||
GTEST_SKIP() << "Compressed offload mix port does not support gapless offload";
|
||||
}
|
||||
}
|
||||
// FIXME: The presentation position is not updated if there is no zero padding in data.
|
||||
std::vector<uint8_t> offloadData(stream->getBufferSize());
|
||||
|
||||
@@ -34,6 +34,7 @@ cc_defaults {
|
||||
],
|
||||
shared_libs: [
|
||||
"libbinder",
|
||||
"libcutils",
|
||||
"libfmq",
|
||||
"libxml2",
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user