Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Buildbot scte35 id3 markers #2748

Merged
merged 81 commits into from
May 27, 2024
Merged
Show file tree
Hide file tree
Changes from 17 commits
Commits
Show all changes
81 commits
Select commit Hold shift + click to select a range
b634dac
mpegts: add generic id3 tag encoded as KLV
rbouqueau Nov 17, 2023
bf6e591
metadata/id3: forward raw data as we don't do anything special with t…
rbouqueau Nov 17, 2023
96cb1c1
m2ts mux: make data to be discarded as it is reallocated
rbouqueau Nov 17, 2023
1df5296
remove old comment
rbouqueau Nov 19, 2023
826bcd5
m2ts scte35: fwd support
rbouqueau Nov 19, 2023
d4005bd
mpegts: id3 is PES while SCTE35 is section
rbouqueau Nov 23, 2023
dbb180f
m2ts: prepare to use 'TEMI custom descriptor to filter prop' mechanis…
rbouqueau Nov 24, 2023
045ed52
typo: unknow -> unknown
rbouqueau Nov 24, 2023
5dc0971
dmx_m2ts: forward id3 and scte35 as props
rbouqueau Nov 25, 2023
aaa6d02
dmx_m2ts: partial revert of dbb180f37f5eb9320ccb47edd14dad234baababf
rbouqueau Nov 25, 2023
941f07c
inspect: add scte35
rbouqueau Nov 28, 2023
6316cc5
mux_isom: push id3 in emsg
rbouqueau Nov 29, 2023
c1ef5c1
strdup can't be called with NULL as arg
rbouqueau Jan 9, 2024
12a672b
Merge branch 'master' into buildbot-scte35-id3-markers
rbouqueau Feb 13, 2024
b5081d0
scte35: enable ts remux
rbouqueau Feb 15, 2024
4fc2755
isom mux: customize id3 emsg syntax according to https://aomedia.org/…
rbouqueau Feb 16, 2024
835b7d0
dmx_m2ts: set pes framing for id3 streams
rbouqueau Feb 16, 2024
e78543b
EventMessage Track (23001-18): add boxes
rbouqueau Feb 23, 2024
ebe5a3f
mux_isom: create emsg box list before adding entry
rbouqueau Feb 23, 2024
fe4590a
isom_mux: add emsg attached to packets at each packet, not only at fr…
rbouqueau Feb 23, 2024
9634380
add scte35_dec (must be explicitely instantiated)
rbouqueau Feb 28, 2024
53a9e17
cosmetics
rbouqueau Feb 28, 2024
f053ca2
mux_isom: use strdup instead of malloc+strcpy
rbouqueau Feb 28, 2024
b63df1c
23001-18 event message track: first version with 'emeb' empty filling
rbouqueau Feb 28, 2024
92a0fb0
dec_scte35: use dts instead of cts (in case the video input stream co…
rbouqueau Mar 1, 2024
a2d9ab7
dmx_m2ts: attach scte35 to video only
rbouqueau Mar 1, 2024
e194a8e
scte35 dmx: declare static prop on pid where the dyn prop will be att…
rbouqueau Mar 2, 2024
9574251
evte: remove warnings
rbouqueau Mar 2, 2024
6c2f05b
23001-18 in dash
rbouqueau Mar 8, 2024
bf0b41c
scte35_dec: take segmentation into account
rbouqueau Mar 20, 2024
f58b71e
scte35_dec: cosmetics
rbouqueau Mar 20, 2024
bd71339
23001-18: inspect evte
rbouqueau Mar 22, 2024
afc88a7
inspect scte35: misc fixes
rbouqueau Mar 23, 2024
2deda55
dec_scte35: parse pts_delta and event duration+id
rbouqueau Mar 23, 2024
bd525d0
typo
rbouqueau Mar 24, 2024
6bcb03c
23001-18: segment emib box
rbouqueau Mar 25, 2024
94cb9f9
dec_scte35: don't dynamically allocate 'emeb' boxes
rbouqueau Mar 27, 2024
e2a8625
cosmetics
rbouqueau Mar 27, 2024
623574e
scte35: dump standardized xml when inspecting
rbouqueau Mar 27, 2024
da30804
dec_scte35: manage drift in non-segmented mode
rbouqueau Mar 27, 2024
0905b7b
dec_scte35: manage drift in segmented mode
rbouqueau Mar 27, 2024
85cb9b2
dec_scte35: no duration events are assigned the last pck duration
rbouqueau Apr 2, 2024
ead8914
inspect: adjust bs pos when parsing is incomplete
rbouqueau Apr 7, 2024
845b323
scte35dec: set default segmentation duration (1s)
rbouqueau Apr 7, 2024
a3054ab
remove duplicate prop set
rbouqueau Apr 11, 2024
fb56c2c
Handle ID3 tags as properties in TS stream.
May 2, 2024
a700056
Merge branch 'master' into buildbot-scte35-id3-markers
rbouqueau May 6, 2024
c47d2ad
fix build after merging master
rbouqueau May 7, 2024
18dfbdb
Support ID3 tags of any length.
May 6, 2024
f2cf031
cosmetics
rbouqueau May 12, 2024
058cebd
dec_scte35: add minimal test
rbouqueau May 12, 2024
1f9a5a8
add compile flag to unittest build (e.g. debug info)
rbouqueau May 13, 2024
8e651ee
fix gcc warning
rbouqueau May 13, 2024
5baae20
dec_scte35: add first UT
rbouqueau May 15, 2024
a86d1b2
fix memleak in xml_string unit test
rbouqueau May 15, 2024
48edd6b
misc cosmetics and checks on exported functions
rbouqueau May 15, 2024
d93c07c
scte35: clarify test structure
rbouqueau May 16, 2024
c6efacb
scte35: continue to clarify UT structure
rbouqueau May 16, 2024
bdb5b0c
scte35_dec: add UT
rbouqueau May 16, 2024
496ef79
scte35_dec: add first test with segmentation
rbouqueau May 17, 2024
1c323d2
scte35_dec: continue to add UTs
rbouqueau May 17, 2024
4a82726
scte35_dec: adding all UTs (still a few FIXMEs)
rbouqueau May 17, 2024
44cb9eb
scte35_dec: pass more tests
rbouqueau May 17, 2024
b03cfda
gf_isom_set_media_timescale returns GF_OK if there is nothing to do (…
rbouqueau May 17, 2024
603686d
scte35: fixes while processing streams from other sources
rbouqueau May 21, 2024
58b452d
scte35_dec: update payload and segment emeb as well
rbouqueau May 21, 2024
67f026c
scte35_dec: improve logs to display parsed content and timings
rbouqueau May 21, 2024
18b6c1f
scte35_dec: add m2ts section checks in all the pipeline
rbouqueau May 21, 2024
539f291
evte: plug with MP4Box -dxml
rbouqueau May 21, 2024
79a35d1
inspect: fix element close
rbouqueau May 21, 2024
4b26628
fix clang compilation
rbouqueau May 23, 2024
85261fe
Merge branch 'master' into buildbot-scte35-id3-markers
rbouqueau May 23, 2024
49e95c5
inspect: add xml namespace
rbouqueau May 23, 2024
99436b3
fix for non-Makefile builds
rbouqueau May 23, 2024
ca2389d
add dec_scte35 to vcxproj
rbouqueau May 24, 2024
6192235
scte35_dec: minor refinements
rbouqueau May 24, 2024
0a350d6
Merge branch 'master' into buildbot-scte35-id3-markers
rbouqueau May 24, 2024
07af7a0
build tweaks
rbouqueau May 24, 2024
4c6bcb3
adding dec_scte35 using xcode, thank you @aureliendavid
rbouqueau May 24, 2024
b478be2
scte35 dump: fix splice time inside time signal
rbouqueau May 24, 2024
20626ef
update changelog
rbouqueau May 26, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 3 additions & 0 deletions include/gpac/constants.h
Original file line number Diff line number Diff line change
Expand Up @@ -528,6 +528,9 @@ typedef enum

GF_CODECID_DVB_SUBS = GF_4CC( 'd', 'v', 'b', 's' ),
GF_CODECID_DVB_TELETEXT = GF_4CC( 'd', 'v', 'b', 't' ),

GF_CODECID_SCTE35 = GF_4CC( 's', 'c', '3', '5' ),

/*!
\brief OGG DecoderConfig

Expand Down
2 changes: 1 addition & 1 deletion include/gpac/media_tools.h
Original file line number Diff line number Diff line change
Expand Up @@ -738,7 +738,7 @@ typedef enum
/*! out of band parameter sets except PPS and APS, used for VVC */
GF_DASH_BSMODE_INBAND_PPS,
/*! both inband and out of band parameter sets */
GF_DASH_BSMODE_BOTH, //Romain
GF_DASH_BSMODE_BOTH,
/*! attempts to merge parameter sets in a single sample entry */
GF_DASH_BSMODE_MERGED,
/*! parameter sets are in different sample entries */
Expand Down
76 changes: 44 additions & 32 deletions include/gpac/mpegts.h
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ extern "C" {
/*! metadata types for GF_M2TS_METADATA_POINTER_DESCRIPTOR*/
enum {
GF_M2TS_META_ID3 = GF_4CC('I','D','3',' '),
GF_M2TS_META_KLVA = GF_4CC('K','L','V','A'),
};


Expand Down Expand Up @@ -213,6 +214,7 @@ enum {
GF_M2TS_TABLE_ID_DIT = 0x7E,
GF_M2TS_TABLE_ID_SIT = 0x7F, /* max size for section 4096 */
/* 0x80 - 0xfe reserved */
GF_M2TS_TABLE_ID_SCTE35_SPLICE_INFO = 0xFC,
/* 0xff reserved */
};

Expand Down Expand Up @@ -279,40 +281,43 @@ typedef enum

/*the rest is internal use*/

GF_M2TS_VIDEO_VC1 = 0xEA,
GF_M2TS_VIDEO_DCII = 0x80,
GF_M2TS_AUDIO_AC3 = 0x81,
GF_M2TS_AUDIO_DTS = 0x82,
GF_M2TS_AUDIO_TRUEHD = 0x83,
GF_M2TS_AUDIO_EC3 = 0x84,
GF_M2TS_MPE_SECTIONS = 0x90,
GF_M2TS_SUBTITLE_DVB = 0x100,
GF_M2TS_AUDIO_OPUS = 0x101,
GF_M2TS_VIDEO_AV1 = 0x102,

GF_M2TS_DVB_TELETEXT = 0x152,
GF_M2TS_DVB_VBI = 0x153,
GF_M2TS_DVB_SUBTITLE = 0x154,
GF_M2TS_METADATA_ID3_HLS = 0x155,
GF_M2TS_VIDEO_VC1 = 0xEA,
GF_M2TS_VIDEO_DCII = 0x80,
GF_M2TS_AUDIO_AC3 = 0x81,
GF_M2TS_AUDIO_DTS = 0x82,
GF_M2TS_AUDIO_TRUEHD = 0x83,
GF_M2TS_AUDIO_EC3 = 0x84,
GF_M2TS_SCTE35_SPLICE_INFO_SECTIONS = 0x86,
GF_M2TS_MPE_SECTIONS = 0x90,
GF_M2TS_SUBTITLE_DVB = 0x100,
GF_M2TS_AUDIO_OPUS = 0x101,
GF_M2TS_VIDEO_AV1 = 0x102,

GF_M2TS_DVB_TELETEXT = 0x152,
GF_M2TS_DVB_VBI = 0x153,
GF_M2TS_DVB_SUBTITLE = 0x154,
GF_M2TS_METADATA_ID3_HLS = 0x155,
GF_M2TS_METADATA_ID3_KLVA = 0x156,

} GF_M2TSStreamType;


/*! MPEG-2 TS Registration codes types*/
enum
{
GF_M2TS_RA_STREAM_AC3 = GF_4CC('A','C','-','3'),
GF_M2TS_RA_STREAM_EAC3 = GF_4CC('E','A','C','3'),
GF_M2TS_RA_STREAM_VC1 = GF_4CC('V','C','-','1'),
GF_M2TS_RA_STREAM_HEVC = GF_4CC('H','E','V','C'),
GF_M2TS_RA_STREAM_DTS1 = GF_4CC('D','T','S','1'),
GF_M2TS_RA_STREAM_DTS2 = GF_4CC('D','T','S','2'),
GF_M2TS_RA_STREAM_DTS3 = GF_4CC('D','T','S','3'),
GF_M2TS_RA_STREAM_OPUS = GF_4CC('O','p','u','s'),
GF_M2TS_RA_STREAM_DOVI = GF_4CC('D','O','V','I'),
GF_M2TS_RA_STREAM_AV1 = GF_4CC('A','V','0','1'),

GF_M2TS_RA_STREAM_GPAC = GF_4CC('G','P','A','C')
GF_M2TS_RA_STREAM_AC3 = GF_4CC('A','C','-','3'),
GF_M2TS_RA_STREAM_EAC3 = GF_4CC('E','A','C','3'),
GF_M2TS_RA_STREAM_VC1 = GF_4CC('V','C','-','1'),
GF_M2TS_RA_STREAM_HEVC = GF_4CC('H','E','V','C'),
GF_M2TS_RA_STREAM_DTS1 = GF_4CC('D','T','S','1'),
GF_M2TS_RA_STREAM_DTS2 = GF_4CC('D','T','S','2'),
GF_M2TS_RA_STREAM_DTS3 = GF_4CC('D','T','S','3'),
GF_M2TS_RA_STREAM_OPUS = GF_4CC('O','p','u','s'),
GF_M2TS_RA_STREAM_DOVI = GF_4CC('D','O','V','I'),
GF_M2TS_RA_STREAM_AV1 = GF_4CC('A','V','0','1'),
GF_M2TS_RA_STREAM_SCTE35 = GF_4CC('C','U','E','I'),

GF_M2TS_RA_STREAM_GPAC = GF_4CC('G','P','A','C')
};


Expand Down Expand Up @@ -495,6 +500,13 @@ enum
GF_M2TS_EVT_TEMI_LOCATION,
/*! a TEMI timecode has been found*/
GF_M2TS_EVT_TEMI_TIMECODE,

/*! a SCTE35 splice info has been found*/
GF_M2TS_EVT_SCTE35_SPLICE_INFO,

/*! a generic ID3 tag has been found*/
GF_M2TS_EVT_ID3,

/*! a stream is about to be removed - - associated parameter: pointer to GF_M2TS_ES being removed*/
GF_M2TS_EVT_STREAM_REMOVED
};
Expand Down Expand Up @@ -599,7 +611,7 @@ enum metadata_carriage {
METADATA_CARRIAGE_OTHER = 3
};

/*! MPEG-2 TS demuxer metadat pointer*/
/*! MPEG-2 TS demuxer metadata pointer*/
typedef struct tag_m2ts_metadata_pointer_descriptor {
u16 application_format;
u32 application_format_identifier;
Expand Down Expand Up @@ -867,8 +879,7 @@ typedef struct tag_m2ts_pes
u32 last_pat_packet_number, before_last_pat_pn, before_last_pes_start_pn;

/*! PES reframer callback. If NULL, pes processing is skipped

returns the number of bytes NOT consumed from the input data buffer - these bytes are kept when reassembling the next PES packet*/
returns the number of bytes NOT consumed from the input data buffer - these bytes are kept when reassembling the next PES packet*/
u32 (*reframe)(struct tag_m2ts_demux *ts, struct tag_m2ts_pes *pes, Bool same_pts, u8 *data, u32 data_len, GF_M2TS_PESHeader *hdr);

/*! DVB subtitling info*/
Expand All @@ -882,14 +893,15 @@ typedef struct tag_m2ts_pes
u32 temi_tc_desc_len;
/*! allocated size of TEMI reception buffer*/
u32 temi_tc_desc_alloc_size;

/*! last decoded temi (may be one ahead of time as the last received TEMI)*/
GF_M2TS_TemiTimecodeDescriptor temi_tc;
/*! flag set to indicate a TEMI descriptor should be flushed with next packet*/
Bool temi_pending;

/*! flag set to indicate the last PES packet was not flushed (HLS) to avoid warning on same PTS/DTS used*/
Bool is_resume;
/*! DolbiVison info, last byte set to 1 if non-compatible signaling*/

/*! DolbyVison info, last byte set to 1 if non-compatible signaling*/
u8 dv_info[25];

u64 map_utc, map_utc_pcr, map_pcr;
Expand Down
1 change: 0 additions & 1 deletion src/filter_core/filter_session.h
Original file line number Diff line number Diff line change
Expand Up @@ -1098,7 +1098,6 @@ struct __gf_filter_pid
volatile u32 num_pidinst_del_pending;

u32 link_flags;

};


Expand Down