Chuanzhi Wang | 1b3a5de | 2020-09-04 17:02:00 +0800 | [diff] [blame^] | 1 | /*************************************************************************** |
| 2 | * Copyright (c) 2014 Amlogic, Inc. All rights reserved. |
| 3 | * |
| 4 | * This source code is subject to the terms and conditions defined in the |
| 5 | * file 'LICENSE' which is part of this source code package. |
| 6 | * |
| 7 | * Description: |
| 8 | * |
| 9 | * @brief linux dvb demux wrapper |
| 10 | * @file dvb_dmx_wrapper.h |
| 11 | * |
| 12 | * \author chuanzhi wang <chaunzhi.wang@amlogic.com> |
| 13 | * \date 2020-07-16: create the document |
| 14 | ***************************************************************************/ |
| 15 | |
| 16 | #ifndef _AM_DMX_H |
| 17 | #define _AM_DMX_H |
| 18 | #include "techtype.h" |
| 19 | |
| 20 | #ifdef __cplusplus |
| 21 | extern "C" |
| 22 | { |
| 23 | #endif |
| 24 | |
| 25 | /**\brief Input source of the demux*/ |
| 26 | typedef enum |
| 27 | { |
| 28 | AML_DMX_SRC_TS0, /**< TS input port 0*/ |
| 29 | AML_DMX_SRC_TS1, /**< TS input port 1*/ |
| 30 | AML_DMX_SRC_TS2, /**< TS input port 2*/ |
| 31 | AML_DMX_SRC_TS3, /**< TS input port 3*/ |
| 32 | AML_DMX_SRC_HIU, /**< HIU input (memory)*/ |
| 33 | AML_DMX_SRC_HIU1 |
| 34 | } AML_DMX_Source_t; |
| 35 | |
| 36 | typedef void (*AML_DMX_DataCb) (int dev_no, int fd, const uint8_t *data, int len, void *user_data); |
| 37 | |
| 38 | BOOLEAN AML_DMX_Open(int dev_no); |
| 39 | BOOLEAN AML_DMX_Close(int dev_no); |
| 40 | BOOLEAN AML_DMX_AllocateFilter(int dev_no, int *fhandle); |
| 41 | BOOLEAN AML_DMX_SetSecFilter(int dev_no, int fhandle, const struct dmx_sct_filter_params *params); |
| 42 | BOOLEAN AML_DMX_SetPesFilter(int dev_no, int fhandle, const struct dmx_pes_filter_params *params); |
| 43 | BOOLEAN AML_DMX_SetBufferSize(int dev_no, int fhandle, int size); |
| 44 | BOOLEAN AML_DMX_FreeFilter(int dev_no, int fhandle); |
| 45 | BOOLEAN AML_DMX_StartFilter(int dev_no, int fhandle); |
| 46 | BOOLEAN AML_DMX_StopFilter(int dev_no, int fhandle); |
| 47 | BOOLEAN AML_DMX_SetCallback(int dev_no, int fhandle, AML_DMX_DataCb cb, void *user_data); |
| 48 | BOOLEAN AML_DMX_SetSource(int dev_no, AML_DMX_Source_t src); |
| 49 | BOOLEAN AML_DMX_FileEcho(const char *name, const char *cmd); |
| 50 | |
| 51 | |
| 52 | #ifdef __cplusplus |
| 53 | } |
| 54 | #endif |
| 55 | #endif |