Loading services/tuner/TunerDemux.cpp +13 −0 Original line number Diff line number Diff line Loading @@ -56,6 +56,19 @@ Status TunerDemux::setFrontendDataSource(const std::shared_ptr<ITunerFrontend>& return Status::ok(); } Status TunerDemux::setFrontendDataSourceById(int frontendId) { if (mDemux == nullptr) { ALOGE("IDemux is not initialized"); return Status::fromServiceSpecificError(static_cast<int32_t>(Result::UNAVAILABLE)); } Result res = mDemux->setFrontendDataSource(frontendId); if (res != Result::SUCCESS) { return ::ndk::ScopedAStatus::fromServiceSpecificError(static_cast<int32_t>(res)); } return Status::ok(); } Status TunerDemux::openFilter( int type, int subType, int bufferSize, const std::shared_ptr<ITunerFilterCallback>& cb, std::shared_ptr<ITunerFilter>* _aidl_return) { Loading services/tuner/TunerDemux.h +1 −0 Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ public: TunerDemux(sp<IDemux> demux, int demuxId); virtual ~TunerDemux(); Status setFrontendDataSource(const shared_ptr<ITunerFrontend>& frontend) override; Status setFrontendDataSourceById(int frontendId) override; Status openFilter( int mainType, int subtype, int bufferSize, const shared_ptr<ITunerFilterCallback>& cb, shared_ptr<ITunerFilter>* _aidl_return) override; Loading services/tuner/aidl/android/media/tv/tuner/ITunerDemux.aidl +5 −0 Original line number Diff line number Diff line Loading @@ -35,6 +35,11 @@ interface ITunerDemux { */ void setFrontendDataSource(in ITunerFrontend frontend); /** * Set a frontend resource by ID as data input of the demux */ void setFrontendDataSourceById(in int frontendId); /** * Open a new filter in the demux */ Loading services/tuner/aidl/android/media/tv/tuner/ITunerService.aidl +2 −2 Original line number Diff line number Diff line Loading @@ -43,10 +43,10 @@ interface ITunerService { /** * Retrieve the frontend's information. * * @param frontendHandle the handle of the frontend granted by TRM. * @param frontendId the ID of the frontend. * @return the information of the frontend. */ TunerFrontendInfo getFrontendInfo(in int frontendHandle); TunerFrontendInfo getFrontendInfo(in int frontendId); /** * Get Dtmb Frontend Capabilities. Loading Loading
services/tuner/TunerDemux.cpp +13 −0 Original line number Diff line number Diff line Loading @@ -56,6 +56,19 @@ Status TunerDemux::setFrontendDataSource(const std::shared_ptr<ITunerFrontend>& return Status::ok(); } Status TunerDemux::setFrontendDataSourceById(int frontendId) { if (mDemux == nullptr) { ALOGE("IDemux is not initialized"); return Status::fromServiceSpecificError(static_cast<int32_t>(Result::UNAVAILABLE)); } Result res = mDemux->setFrontendDataSource(frontendId); if (res != Result::SUCCESS) { return ::ndk::ScopedAStatus::fromServiceSpecificError(static_cast<int32_t>(res)); } return Status::ok(); } Status TunerDemux::openFilter( int type, int subType, int bufferSize, const std::shared_ptr<ITunerFilterCallback>& cb, std::shared_ptr<ITunerFilter>* _aidl_return) { Loading
services/tuner/TunerDemux.h +1 −0 Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ public: TunerDemux(sp<IDemux> demux, int demuxId); virtual ~TunerDemux(); Status setFrontendDataSource(const shared_ptr<ITunerFrontend>& frontend) override; Status setFrontendDataSourceById(int frontendId) override; Status openFilter( int mainType, int subtype, int bufferSize, const shared_ptr<ITunerFilterCallback>& cb, shared_ptr<ITunerFilter>* _aidl_return) override; Loading
services/tuner/aidl/android/media/tv/tuner/ITunerDemux.aidl +5 −0 Original line number Diff line number Diff line Loading @@ -35,6 +35,11 @@ interface ITunerDemux { */ void setFrontendDataSource(in ITunerFrontend frontend); /** * Set a frontend resource by ID as data input of the demux */ void setFrontendDataSourceById(in int frontendId); /** * Open a new filter in the demux */ Loading
services/tuner/aidl/android/media/tv/tuner/ITunerService.aidl +2 −2 Original line number Diff line number Diff line Loading @@ -43,10 +43,10 @@ interface ITunerService { /** * Retrieve the frontend's information. * * @param frontendHandle the handle of the frontend granted by TRM. * @param frontendId the ID of the frontend. * @return the information of the frontend. */ TunerFrontendInfo getFrontendInfo(in int frontendHandle); TunerFrontendInfo getFrontendInfo(in int frontendId); /** * Get Dtmb Frontend Capabilities. Loading