Commit db34eae7 authored by Laurent Aimar's avatar Laurent Aimar

* configure.ac.in: added mpeg4audio packetizer and allowed conpilation of TS

muxer with libdvbpsi.
 * mpeg/* : added preliminary support of mpeg4 video and audio in TS stream.
(only in ts_dvbpsi demuxer).
parent 02c9c1cb
......@@ -915,7 +915,8 @@ then
PLUGINS="${PLUGINS} access_output_dummy access_output_udp access_output_file"
PLUGINS="${PLUGINS} mux_ts mux_ps mux_dummy"
PLUGINS="${PLUGINS} packetizer_mpegaudio packetizer_mpegvideo packetizer_a52"
PLUGINS="${PLUGINS} packetizer_mpeg4video packetizer_copy"
PLUGINS="${PLUGINS} packetizer_mpeg4video packetizer_mpeg4audio"
PLUGINS="${PLUGINS} packetizer_copy"
fi
......@@ -1121,10 +1122,10 @@ then
fi
dnl
dnl libdvbpsi ts demux
dnl libdvbpsi ts demux/mux
dnl
AC_ARG_ENABLE(dvbpsi,
[ --enable-dvbpsi dvbpsi ts demux module (default enabled)])
[ --enable-dvbpsi dvbpsi ts mux and demux module (default enabled)])
if test "x${enable_dvbpsi}" != "xno"
then
AC_ARG_WITH(dvbpsi,
......@@ -1137,7 +1138,9 @@ then
then
AC_CHECK_HEADERS(dvbpsi/dr.h,
[ PLUGINS="${PLUGINS} ts_dvbpsi"
LDFLAGS_ts_dvbpsi="${LDFLAGS_ts_dvbpsi} -ldvbpsi" ],
LDFLAGS_ts_dvbpsi="${LDFLAGS_ts_dvbpsi} -ldvbpsi"
PLUGINS="${PLUGINS} mux_ts_dvbpsi"
LDFLAGS_mux_ts_dvbpsi="${LDFLAGS_mux_ts_dvbpsi} -ldvbpsi" ],
[ AC_MSG_WARN([cannot find libdvbpsi headers]) ],
[#include <stdint.h>
#include <dvbpsi/dvbpsi.h>
......@@ -1160,6 +1163,11 @@ then
BUILTINS="${BUILTINS} ts_dvbpsi"
LDFLAGS_ts_dvbpsi="${LDFLAGS_ts_dvbpsi} ${real_dvbpsi_tree}/src/.libs/libdvbpsi.a"
CPPFLAGS_ts_dvbpsi="${CPPFLAGS_ts_dvbpsi} -I${real_dvbpsi_tree}/src"
BUILTINS="${BUILTINS} mux_ts_dvbpsi"
LDFLAGS_mux_ts_dvbpsi="${LDFLAGS_mux_ts_dvbpsi} ${real_dvbpsi_tree}/src/.libs/libdvbpsi.a"
CPPFLAGS_mux_ts_dvbpsi="${CPPFLAGS_mux_ts_dvbpsi} -I${real_dvbpsi_tree}/src"
else
dnl The given libdvbpsi wasn't built
AC_MSG_RESULT(no)
......@@ -1185,6 +1193,10 @@ then
PLUGINS="${PLUGINS} ts_dvbpsi"
LDFLAGS_ts_dvbpsi="${LDFLAGS_ts_dvbpsi} ${LDFLAGS_test} -ldvbpsi"
CPPFLAGS_ts_dvbpsi="${CPPFLAGS_ts_dvbpsi} ${CPPFLAGS_test}"
PLUGINS="${PLUGINS} mux_ts_dvbpsi"
LDFLAGS_mux_ts_dvbpsi="${LDFLAGS_mux_ts_dvbpsi} ${LDFLAGS_test} -ldvbpsi"
CPPFLAGS_mux_ts_dvbpsi="${CPPFLAGS_mux_ts_dvbpsi} ${CPPFLAGS_test}"
],[
if test "x${enable_dvbpsi}" != "x"
then
......
......@@ -2,7 +2,7 @@
* system.h: MPEG demultiplexing.
*****************************************************************************
* Copyright (C) 1999-2002 VideoLAN
* $Id: system.h,v 1.3 2002/10/20 12:23:48 massiot Exp $
* $Id: system.h,v 1.4 2003/01/08 16:40:29 fenrir Exp $
*
* Authors: Christophe Massiot <massiot@via.ecp.fr>
*
......@@ -47,6 +47,10 @@
#define MPEG1_AUDIO_ES 0x03
#define MPEG2_AUDIO_ES 0x04
#define A52DVB_AUDIO_ES 0x06
#define MPEG4_VIDEO_ES 0x10
#define MPEG4_AUDIO_ES 0x11
#define A52_AUDIO_ES 0x81
/* These ones might violate the usage : */
#define DVD_SPU_ES 0x82
......@@ -124,6 +128,97 @@ typedef struct psi_section_t
} psi_section_t;
/*****************************************************************************
* decoder_descriptor_t
*****************************************************************************/
typedef struct decoder_config_descriptor_s
{
uint8_t i_objectTypeIndication;
uint8_t i_streamType;
vlc_bool_t b_upStream;
uint32_t i_bufferSizeDB;
uint32_t i_maxBitrate;
uint32_t i_avgBitrate;
int i_decoder_specific_info_len;
uint8_t *p_decoder_specific_info;
} decoder_config_descriptor_t;
/*****************************************************************************
* sl_descriptor_t:
*****************************************************************************/
typedef struct sl_config_descriptor_s
{
vlc_bool_t b_useAccessUnitStartFlag;
vlc_bool_t b_useAccessUnitEndFlag;
vlc_bool_t b_useRandomAccessPointFlag;
vlc_bool_t b_useRandomAccessUnitsOnlyFlag;
vlc_bool_t b_usePaddingFlag;
vlc_bool_t b_useTimeStampsFlags;
vlc_bool_t b_useIdleFlag;
vlc_bool_t b_durationFlag;
uint32_t i_timeStampResolution;
uint32_t i_OCRResolution;
uint8_t i_timeStampLength;
uint8_t i_OCRLength;
uint8_t i_AU_Length;
uint8_t i_instantBitrateLength;
uint8_t i_degradationPriorityLength;
uint8_t i_AU_seqNumLength;
uint8_t i_packetSeqNumLength;
uint32_t i_timeScale;
uint16_t i_accessUnitDuration;
uint16_t i_compositionUnitDuration;
uint64_t i_startDecodingTimeStamp;
uint64_t i_startCompositionTimeStamp;
} sl_config_descriptor_t;
/*****************************************************************************
* es_mpeg4_descriptor_t: XXX it's not complete but should be enough
*****************************************************************************/
typedef struct es_mpeg4_descriptor_s
{
vlc_bool_t b_ok;
uint16_t i_es_id;
vlc_bool_t b_streamDependenceFlag;
vlc_bool_t b_OCRStreamFlag;
uint8_t i_streamPriority;
char *psz_url;
uint16_t i_dependOn_es_id;
uint16_t i_OCR_es_id;
decoder_config_descriptor_t dec_descr;
sl_config_descriptor_t sl_descr;
} es_mpeg4_descriptor_t;
/*****************************************************************************
* iod_descriptor_t: XXX it's not complete but should be enough
*****************************************************************************/
typedef struct iod_descriptor_s
{
uint8_t i_iod_label;
/* IOD */
uint16_t i_od_id;
char *psz_url;
uint8_t i_ODProfileLevelIndication;
uint8_t i_sceneProfileLevelIndication;
uint8_t i_audioProfileLevelIndication;
uint8_t i_visualProfileLevelIndication;
uint8_t i_graphicsProfileLevelIndication;
es_mpeg4_descriptor_t es_descr[255];
} iod_descriptor_t;
/*****************************************************************************
* es_ts_data_t: extension of es_descriptor_t
*****************************************************************************/
......@@ -133,11 +228,18 @@ typedef struct es_ts_data_t
* the PSI decoder ? */
int i_psi_type; /* There are different types of PSI */
psi_section_t * p_psi_section; /* PSI packets */
/* Markers */
int i_continuity_counter;
/* mpeg4 in TS data specific */
int b_mpeg4;
uint16_t i_es_id;
es_mpeg4_descriptor_t *p_es_descr; /* es_descr of IOD */
} es_ts_data_t;
/*****************************************************************************
......@@ -149,6 +251,11 @@ typedef struct pgrm_ts_data_t
int i_pmt_version;
/* libdvbpsi pmt decoder handle */
void * p_pmt_handle;
/* mpeg4 in TS data specific */
vlc_bool_t b_mpeg4;
iod_descriptor_t iod;
} pgrm_ts_data_t;
/*****************************************************************************
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment