• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /**
2  * Copyright 2021, The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *     http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package android.media.tv.tuner;
18 
19 import android.media.tv.tuner.ITunerDvr;
20 import android.media.tv.tuner.ITunerDvrCallback;
21 import android.media.tv.tuner.ITunerFilter;
22 import android.media.tv.tuner.ITunerFilterCallback;
23 import android.media.tv.tuner.ITunerFrontend;
24 import android.media.tv.tuner.ITunerTimeFilter;
25 
26 /**
27  * Tuner Demux interface handles tuner related operations.
28  *
29  * {@hide}
30  */
31 interface ITunerDemux {
32 
33     /**
34      * Set a frontend resource as data input of the demux
35      */
setFrontendDataSource(in ITunerFrontend frontend)36     void setFrontendDataSource(in ITunerFrontend frontend);
37 
38     /**
39      * Open a new filter in the demux
40      */
openFilter( in int mainType, in int subtype, in int bufferSize, in ITunerFilterCallback cb)41     ITunerFilter openFilter(
42         in int mainType, in int subtype, in int bufferSize, in ITunerFilterCallback cb);
43 
44     /**
45      * Open time filter of the demux.
46      */
openTimeFilter()47     ITunerTimeFilter openTimeFilter();
48 
49     /**
50      * Get hardware sync ID for audio and video.
51      */
getAvSyncHwId(ITunerFilter tunerFilter)52     int getAvSyncHwId(ITunerFilter tunerFilter);
53 
54     /**
55      * Get current time stamp to use for A/V sync.
56      */
getAvSyncTime(in int avSyncHwId)57     long getAvSyncTime(in int avSyncHwId);
58 
59     /**
60      * Open a DVR (Digital Video Record) instance in the demux.
61      */
openDvr(in int dvbType, in int bufferSize, in ITunerDvrCallback cb)62     ITunerDvr openDvr(in int dvbType, in int bufferSize, in ITunerDvrCallback cb);
63 
64     /**
65      * Connect Conditional Access Modules (CAM) through Common Interface (CI).
66      */
connectCiCam(in int ciCamId)67     void connectCiCam(in int ciCamId);
68 
69     /**
70      * Disconnect Conditional Access Modules (CAM).
71      */
disconnectCiCam()72     void disconnectCiCam();
73 
74     /**
75      * Releases the ITunerDemux instance.
76      */
close()77     void close();
78 }
79