Skip to content

Navigation Menu

Sign in
Sign up

FFmpegScte-35patch #133

superkabuki started this conversation in General
Discussion options

https://github.com/superkabuki/SuperKabuki_SCTE35patch

Super Kabuki SCTE-35 patch for FFmpeg.

...why?

If you work with SCTE-35 and you use ffmpeg,
having the SCTE-35 stream type 0x86 changed to bin data 0x06, makess life hard.

How does it work?

  • The patch is only nine lines of code, it allows you copy a SCTE-35 stream over as SCTE-35, when you're encoding with ffmpeg.
  • The patch also adds the SCTE-35 Descriptor (CUEI / 0x49455543) , just to be fancy.
  • Everything else works just like unpatched ffmpeg.

Install

  1. git clone https://github.com/superkabuki/FFmpeg_SCTE35.git

  2. cd FFmpeg_SCTE35

  3. ./configure --enable-shared --extra-version=-SuperKabuki-patch ( you can customize this as needed )

  4. make all

  5. sudo make install


How to use:

Use it just like unpatched FFmpeg.


Examples

  1. Re-encode video to h.265, audio to aac, copy over the SCTE-35, and keep the timestamps.
ffmpeg -copyts -i input.ts -map 0 -c:v h265 -c:a aac -c:d copy -muxpreload 0 -muxdelay 0 output.ts

  1. Copy all streams including SCTE-35, cut the first 200 seconds, and keep the timestamps.
ffmpeg -copyts -ss 200 -i input.ts -map 0 -c copy -muxpreload 0 -muxdelay 0 output.ts

Notice the start time and duration have both changed by ~200 seconds.

  • old
 Duration: 00:04:56.30, start: 72667.595200, bitrate: 962 kb/s
  • new
 Duration: 00:01:37.75, start: 72866.141867, bitrate: 962 kb/s

You must be logged in to vote

Replies: 0 comments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant

AltStyle によって変換されたページ (->オリジナル) /