-
Notifications
You must be signed in to change notification settings - Fork 0
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
added reframer_ts_vtt filter. #7
base: integration
Are you sure you want to change the base?
Conversation
src/filters/dmx_m2ts.c
Outdated
@@ -479,6 +486,7 @@ static void m2tsdmx_declare_pid(GF_M2TSDmxCtx *ctx, GF_M2TS_PES *stream, GF_ESD | |||
if (esd->decoderConfig && (esd->decoderConfig->streamType==GF_STREAM_OD)) | |||
stream->flags |= GF_M2TS_ES_IS_MPEG4_OD; | |||
} else { | |||
// TODO: Adarve this is the path for WVTT |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need it?
src/filters/dmx_m2ts.c
Outdated
@@ -745,7 +752,13 @@ static void m2tsdmx_send_packet(GF_M2TSDmxCtx *ctx, GF_M2TS_PES_PCK *pck) | |||
|
|||
/*pcr not initialized, don't send any data*/ | |||
// if (! pck->stream->program->first_dts) return; | |||
if (!pck->stream->user) return; | |||
|
|||
// if (pck->stream->pid == 65) GF_LOG(GF_LOG_ERROR, GF_LOG_CONDITION, ("m2tsdmx_send_packet: PID 65")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need it?
@@ -795,6 +808,8 @@ static void m2tsdmx_send_packet(GF_M2TSDmxCtx *ctx, GF_M2TS_PES_PCK *pck) | |||
} | |||
|
|||
|
|||
// if (pck->stream->pid == 65) GF_LOG(GF_LOG_ERROR, GF_LOG_CONDITION, ("m2tsdmx_send_packet: creating packet %llu\n", len)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need it?
Given a Transport Stream file containing Metadata as PES packets with metadata format as "WVTT", the new
rftsvtt
filter reads the content of each PES packet and creates a WebVTT cue output that can be used by thedasher
to create a subtitles track for both DASH and HLS.Running GPAC as:
/home/juan/workspace/git/gpac/bin/gcc/gpac \ -i /home/juan/workspace/notebooks/GStreamer/out_subtitle.ts \ rftsvtt \ -o "/home/juan/workspace/notebooks/GStreamer/gpac/hls/playlist.m3u8:gpac:buf=-150:seg_sync=no:segdur=1.0:cdur=1.0:hlsc=true:cmaf=cmf2:dmode=static:template=segment:rawsub=true" \ -graph
creates a filter graph as follows:
Notice that, as this is HLS, the
rawsub=true
flag is used. The output playlist defines the subtitles track:and
playlist_1.m3u8
where each
.vtt
file contains 1 second of data.