libdvbv5  1.11.0
Library to work with Digital TV devices on Linux
dvb-demux.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2011-2014 - Mauro Carvalho Chehab
3  *
4  * This program is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU Lesser General Public License as published by
6  * the Free Software Foundation version 2.1 of the License.
7  *
8  * This program is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU Lesser General Public License for more details.
12  *
13  * These routines were originally written as part of the dvb-apps, as:
14  * util functions for various ?zap implementations
15  *
16  * Copyright (C) 2001 Johannes Stezenbach (js@convergence.de)
17  * for convergence integrated media
18  *
19  * Originally licensed as GPLv2 or upper
20  */
21 
33 #ifndef _DVB_DEMUX_H
34 #define _DVB_DEMUX_H
35 
36 #include <linux/dvb/dmx.h>
37 
38 #ifdef __cplusplus
39 extern "C" {
40 #endif
41 
56 int dvb_dmx_open(int adapter, int demux);
57 
68 void dvb_dmx_close(int dmx_fd);
69 
82 void dvb_dmx_stop(int dmx_fd);
83 
105 int dvb_set_pesfilter(int dmxfd, int pid, dmx_pes_type_t type,
106  dmx_output_t output, int buffersize);
107 
130 int dvb_set_section_filter(int dmxfd, int pid, unsigned filtsize,
131  unsigned char *filter,
132  unsigned char *mask,
133  unsigned char *mode,
134  unsigned int flags);
135 
151 int dvb_get_pmt_pid(int dmxfd, int sid);
152 
153 #ifdef __cplusplus
154 }
155 #endif
156 
157 #endif
void dvb_dmx_close(int dmx_fd)
Stops the DMX filter for the file descriptor and closes.
int dvb_dmx_open(int adapter, int demux)
Opens a DVB demux in read/write mode.
int dvb_set_section_filter(int dmxfd, int pid, unsigned filtsize, unsigned char *filter, unsigned char *mask, unsigned char *mode, unsigned int flags)
Sets a MPEG-TS section filter.
int dvb_set_pesfilter(int dmxfd, int pid, dmx_pes_type_t type, dmx_output_t output, int buffersize)
Start a filter for a MPEG-TS Packetized Elementary Stream (PES)
void dvb_dmx_stop(int dmx_fd)
Stops the DMX filter for a given file descriptor.
int dvb_get_pmt_pid(int dmxfd, int sid)
read the contents of the MPEG-TS PAT table, seeking for an specific service ID