Skip to content
This repository has been archived by the owner on Sep 20, 2024. It is now read-only.

Commit

Permalink
burnins fix bit rate for dnxhd mxf
Browse files Browse the repository at this point in the history
passing metadata to burnins
  • Loading branch information
jakubjezek001 committed Jan 14, 2022
1 parent 1150de0 commit eed31e5
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions openpype/scripts/otio_burnin.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,16 @@ def _dnxhd_codec_args(stream_data, source_ffmpeg_cmd):
if pix_fmt:
output.extend(["-pix_fmt", pix_fmt])

# Use arguments from source if are available source arguments
if source_ffmpeg_cmd:
copy_args = (
"-b:v", "-vb",
)
args = source_ffmpeg_cmd.split(" ")
for idx, arg in enumerate(args):
if arg in copy_args:
output.extend([arg, args[idx + 1]])

output.extend(["-g", "1"])
return output

Expand Down Expand Up @@ -715,6 +725,15 @@ def burnins_from_data(
ffmpeg_args.extend(
get_codec_args(burnin.ffprobe_data, source_ffmpeg_cmd)
)
# Use arguments from source if are available source arguments
if source_ffmpeg_cmd:
copy_args = (
"-metadata",
)
args = source_ffmpeg_cmd.split(" ")
for idx, arg in enumerate(args):
if arg in copy_args:
ffmpeg_args.extend([arg, args[idx + 1]])

# Use group one (same as `-intra` argument, which is deprecated)
ffmpeg_args_str = " ".join(ffmpeg_args)
Expand Down

0 comments on commit eed31e5

Please sign in to comment.