Loading tv/tuner/1.1/Android.bp +0 −1 Original line number Diff line number Diff line Loading @@ -4,7 +4,6 @@ hidl_interface { name: "android.hardware.tv.tuner@1.1", root: "android.hardware", srcs: [ "IDemux.hal", "IFilter.hal", "IFrontend.hal", "IFilterCallback.hal", Loading tv/tuner/1.1/IDemux.haldeleted 100644 → 0 +0 −41 Original line number Diff line number Diff line /* * Copyright 2020 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package android.hardware.tv.tuner@1.1; import @1.0::IDemux; import @1.0::IFilter; import @1.0::Result; /** * Demultiplexer(Demux) takes a single multiplexed input and splits it into * one or more output. */ interface IDemux extends @1.0::IDemux { /** * Get a 64-bit hardware sync ID for audio and video. * * It is used by the client to get the hardware sync ID for audio and video. * * @param filter the v1_1 filter instance. * @return result Result status of the operation. * SUCCESS if successful, * INVALID_ARGUMENT if failed for a wrong filter ID. * UNKNOWN_ERROR if failed for other reasons. * @return avSyncHwId the id of hardware A/V sync. */ getAvSyncHwId64Bit(IFilter filter) generates (Result result, uint64_t avSyncHwId); }; No newline at end of file tv/tuner/1.1/default/Demux.cpp +0 −43 Original line number Diff line number Diff line Loading @@ -34,49 +34,6 @@ Demux::Demux(uint32_t demuxId, sp<Tuner> tuner) { Demux::~Demux() {} Return<void> Demux::getAvSyncHwId64Bit(const sp<IFilter>& filter, getAvSyncHwId64Bit_cb _hidl_cb) { ALOGV("%s", __FUNCTION__); uint64_t avSyncHwId = -1; uint64_t id; Result status; sp<V1_1::IFilter> filter_v1_1 = V1_1::IFilter::castFrom(filter); if (filter_v1_1 != NULL) { filter_v1_1->getId64Bit([&](Result result, uint64_t filterId) { id = filterId; status = result; }); } else { filter->getId([&](Result result, uint32_t filterId) { id = filterId; status = result; }); } if (status != Result::SUCCESS) { ALOGE("[Demux] Can't get 64-bit filter Id."); _hidl_cb(Result::INVALID_STATE, avSyncHwId); return Void(); } if (!mFilters[id]->isMediaFilter()) { ALOGE("[Demux] Given filter is not a media filter."); _hidl_cb(Result::INVALID_ARGUMENT, avSyncHwId); return Void(); } if (!mPcrFilterIds.empty()) { // Return the lowest pcr filter id in the default implementation as the av sync id _hidl_cb(Result::SUCCESS, *mPcrFilterIds.begin()); return Void(); } ALOGE("[Demux] No PCR filter opened."); _hidl_cb(Result::INVALID_STATE, avSyncHwId); return Void(); } Return<Result> Demux::setFrontendDataSource(uint32_t frontendId) { ALOGV("%s", __FUNCTION__); Loading tv/tuner/1.1/default/Demux.h +1 −5 Original line number Diff line number Diff line Loading @@ -17,7 +17,6 @@ #ifndef ANDROID_HARDWARE_TV_TUNER_V1_1_DEMUX_H_ #define ANDROID_HARDWARE_TV_TUNER_V1_1_DEMUX_H_ #include <android/hardware/tv/tuner/1.1/IDemux.h> #include <fmq/MessageQueue.h> #include <math.h> #include <set> Loading Loading @@ -49,15 +48,12 @@ class Frontend; class TimeFilter; class Tuner; class Demux : public V1_1::IDemux { class Demux : public IDemux { public: Demux(uint32_t demuxId, sp<Tuner> tuner); ~Demux(); virtual Return<void> getAvSyncHwId64Bit(const sp<IFilter>& filter, getAvSyncHwId64Bit_cb _hidl_cb) override; virtual Return<Result> setFrontendDataSource(uint32_t frontendId) override; virtual Return<void> openFilter(const DemuxFilterType& type, uint32_t bufferSize, Loading tv/tuner/1.1/vts/functional/DemuxTests.cpp +0 −30 Original line number Diff line number Diff line Loading @@ -39,33 +39,3 @@ AssertionResult DemuxTests::closeDemux() { mDemux = nullptr; return AssertionResult(status.isOk()); } No newline at end of file AssertionResult DemuxTests::getAvSyncId_64bit(sp<IFilter> filter, uint64_t& avSyncHwId) { EXPECT_TRUE(mDemux) << "Demux is not opened yet."; Result status; sp<android::hardware::tv::tuner::V1_1::IDemux> demux_v1_1 = android::hardware::tv::tuner::V1_1::IDemux::castFrom(mDemux); if (demux_v1_1 != NULL) { demux_v1_1->getAvSyncHwId64Bit(filter, [&](Result result, uint64_t id) { status = result; avSyncHwId = id; }); } else { ALOGW("[vts] Can't cast IDemux into v1_1."); return failure(); } return AssertionResult(status == Result::SUCCESS); } AssertionResult DemuxTests::getAvSyncTime(uint32_t avSyncId) { EXPECT_TRUE(mDemux) << "Demux is not opened yet."; Result status; uint64_t syncTime; mDemux->getAvSyncTime(avSyncId, [&](Result result, uint64_t time) { status = result; syncTime = time; }); return AssertionResult(status == Result::SUCCESS); } No newline at end of file Loading
tv/tuner/1.1/Android.bp +0 −1 Original line number Diff line number Diff line Loading @@ -4,7 +4,6 @@ hidl_interface { name: "android.hardware.tv.tuner@1.1", root: "android.hardware", srcs: [ "IDemux.hal", "IFilter.hal", "IFrontend.hal", "IFilterCallback.hal", Loading
tv/tuner/1.1/IDemux.haldeleted 100644 → 0 +0 −41 Original line number Diff line number Diff line /* * Copyright 2020 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package android.hardware.tv.tuner@1.1; import @1.0::IDemux; import @1.0::IFilter; import @1.0::Result; /** * Demultiplexer(Demux) takes a single multiplexed input and splits it into * one or more output. */ interface IDemux extends @1.0::IDemux { /** * Get a 64-bit hardware sync ID for audio and video. * * It is used by the client to get the hardware sync ID for audio and video. * * @param filter the v1_1 filter instance. * @return result Result status of the operation. * SUCCESS if successful, * INVALID_ARGUMENT if failed for a wrong filter ID. * UNKNOWN_ERROR if failed for other reasons. * @return avSyncHwId the id of hardware A/V sync. */ getAvSyncHwId64Bit(IFilter filter) generates (Result result, uint64_t avSyncHwId); }; No newline at end of file
tv/tuner/1.1/default/Demux.cpp +0 −43 Original line number Diff line number Diff line Loading @@ -34,49 +34,6 @@ Demux::Demux(uint32_t demuxId, sp<Tuner> tuner) { Demux::~Demux() {} Return<void> Demux::getAvSyncHwId64Bit(const sp<IFilter>& filter, getAvSyncHwId64Bit_cb _hidl_cb) { ALOGV("%s", __FUNCTION__); uint64_t avSyncHwId = -1; uint64_t id; Result status; sp<V1_1::IFilter> filter_v1_1 = V1_1::IFilter::castFrom(filter); if (filter_v1_1 != NULL) { filter_v1_1->getId64Bit([&](Result result, uint64_t filterId) { id = filterId; status = result; }); } else { filter->getId([&](Result result, uint32_t filterId) { id = filterId; status = result; }); } if (status != Result::SUCCESS) { ALOGE("[Demux] Can't get 64-bit filter Id."); _hidl_cb(Result::INVALID_STATE, avSyncHwId); return Void(); } if (!mFilters[id]->isMediaFilter()) { ALOGE("[Demux] Given filter is not a media filter."); _hidl_cb(Result::INVALID_ARGUMENT, avSyncHwId); return Void(); } if (!mPcrFilterIds.empty()) { // Return the lowest pcr filter id in the default implementation as the av sync id _hidl_cb(Result::SUCCESS, *mPcrFilterIds.begin()); return Void(); } ALOGE("[Demux] No PCR filter opened."); _hidl_cb(Result::INVALID_STATE, avSyncHwId); return Void(); } Return<Result> Demux::setFrontendDataSource(uint32_t frontendId) { ALOGV("%s", __FUNCTION__); Loading
tv/tuner/1.1/default/Demux.h +1 −5 Original line number Diff line number Diff line Loading @@ -17,7 +17,6 @@ #ifndef ANDROID_HARDWARE_TV_TUNER_V1_1_DEMUX_H_ #define ANDROID_HARDWARE_TV_TUNER_V1_1_DEMUX_H_ #include <android/hardware/tv/tuner/1.1/IDemux.h> #include <fmq/MessageQueue.h> #include <math.h> #include <set> Loading Loading @@ -49,15 +48,12 @@ class Frontend; class TimeFilter; class Tuner; class Demux : public V1_1::IDemux { class Demux : public IDemux { public: Demux(uint32_t demuxId, sp<Tuner> tuner); ~Demux(); virtual Return<void> getAvSyncHwId64Bit(const sp<IFilter>& filter, getAvSyncHwId64Bit_cb _hidl_cb) override; virtual Return<Result> setFrontendDataSource(uint32_t frontendId) override; virtual Return<void> openFilter(const DemuxFilterType& type, uint32_t bufferSize, Loading
tv/tuner/1.1/vts/functional/DemuxTests.cpp +0 −30 Original line number Diff line number Diff line Loading @@ -39,33 +39,3 @@ AssertionResult DemuxTests::closeDemux() { mDemux = nullptr; return AssertionResult(status.isOk()); } No newline at end of file AssertionResult DemuxTests::getAvSyncId_64bit(sp<IFilter> filter, uint64_t& avSyncHwId) { EXPECT_TRUE(mDemux) << "Demux is not opened yet."; Result status; sp<android::hardware::tv::tuner::V1_1::IDemux> demux_v1_1 = android::hardware::tv::tuner::V1_1::IDemux::castFrom(mDemux); if (demux_v1_1 != NULL) { demux_v1_1->getAvSyncHwId64Bit(filter, [&](Result result, uint64_t id) { status = result; avSyncHwId = id; }); } else { ALOGW("[vts] Can't cast IDemux into v1_1."); return failure(); } return AssertionResult(status == Result::SUCCESS); } AssertionResult DemuxTests::getAvSyncTime(uint32_t avSyncId) { EXPECT_TRUE(mDemux) << "Demux is not opened yet."; Result status; uint64_t syncTime; mDemux->getAvSyncTime(avSyncId, [&](Result result, uint64_t time) { status = result; syncTime = time; }); return AssertionResult(status == Result::SUCCESS); } No newline at end of file