diff --git a/examples/basics/remux.py b/examples/basics/remux.py index 5abb199b8..64ac00c99 100644 --- a/examples/basics/remux.py +++ b/examples/basics/remux.py @@ -9,7 +9,7 @@ # Make an output stream using the input as a template. This copies the stream # setup from one to the other. in_stream = input_.streams.video[0] -out_stream = output.add_stream(template=in_stream) +out_stream = output.add_stream_from_template(in_stream) for packet in input_.demux(in_stream): print(packet) diff --git a/examples/subtitles/remux.py b/examples/subtitles/remux.py index 5b3031788..32ee7d6d3 100644 --- a/examples/subtitles/remux.py +++ b/examples/subtitles/remux.py @@ -6,7 +6,7 @@ output = av.open("remuxed.vtt", "w") in_stream = input_.streams.subtitles[0] -out_stream = output.add_stream(template=in_stream) +out_stream = output.add_stream_from_template(in_stream) for packet in input_.demux(in_stream): if packet.dts is None: