00001 /* 00002 Copyright (C) 2006 Adam Charrett 00003 00004 This program is free software; you can redistribute it and/or 00005 modify it under the terms of the GNU General Public License 00006 as published by the Free Software Foundation; either version 2 00007 of the License, or (at your option) any later version. 00008 00009 This program is distributed in the hope that it will be useful, 00010 but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00012 GNU General Public License for more details. 00013 00014 You should have received a copy of the GNU General Public License 00015 along with this program; if not, write to the Free Software 00016 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA 00017 00018 pids.h 00019 00020 Manage PIDs. 00021 00022 */ 00023 #ifndef _PIDS_H 00024 #define _PIDS_H 00025 00026 #include <stdint.h> 00027 00028 #ifndef _DVBPSI_DESCRIPTOR_H_ 00029 #include <dvbpsi/descriptor.h> 00030 #endif 00031 00032 #include "types.h" 00033 #include "multiplexes.h" 00034 #include "services.h" 00035 00039 typedef struct PID_t 00040 { 00041 int pid; 00042 int type; 00043 int subType; 00044 int pmtVersion; 00045 dvbpsi_descriptor_t *descriptors; 00046 } 00047 PID_t; 00048 00052 typedef struct PIDList_t 00053 { 00054 int count; 00055 PID_t pids[0]; 00056 } 00057 PIDList_t; 00058 00064 PIDList_t *PIDListNew(int count); 00065 00070 void PIDListFree(PIDList_t *pids); 00071 00077 PIDList_t *PIDListClone(PIDList_t *pids); 00078 00086 int PIDListSet(Service_t *service, PIDList_t *pids); 00087 00093 PIDList_t *PIDListGet(Service_t *service); 00094 00100 int PIDListCount(Service_t *service); 00101 00107 int PIDListRemove(Service_t *service); 00108 00109 #endif