[xcode] Change the signature of transcode_setup/transcode_en/decode_setup()

Should make it easier to add/remove parameters without changing all calls to the
functions throughout the code.

Also adds an interface through which to call make_mp4_header().
This commit is contained in:
ejurgensen
2023-12-25 22:29:32 +01:00
parent 9dbec4b99e
commit 4a08644806
12 changed files with 165 additions and 91 deletions

View File

@@ -36,9 +36,11 @@
static int
setup(struct input_source *source)
{
struct transcode_decode_setup_args decode_args = { .profile = XCODE_PCM_NATIVE, .path = source->path, .len_ms = source->len_ms };
struct transcode_encode_setup_args encode_args = { .profile = XCODE_PCM_NATIVE, };
struct transcode_ctx *ctx;
ctx = transcode_setup(XCODE_PCM_NATIVE, NULL, source->data_kind, source->path, source->len_ms);
ctx = transcode_setup(decode_args, encode_args);
if (!ctx)
return -1;