diff options
author | dec05eba <dec05eba@protonmail.com> | 2025-03-04 23:28:19 +0100 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2025-03-04 23:28:19 +0100 |
commit | cf9955dbc35e8e3bb9ac8febbec76cfecd7e739b (patch) | |
tree | b2e0b2237c63f4aea27d2e23d61fbbbcd76d1b47 /src/FileAnalyzer.cpp | |
parent | 3003cf04c015a3a847a5d598e3a3b0521ff6bdf9 (diff) |
Convert to meson project
Diffstat (limited to 'src/FileAnalyzer.cpp')
-rw-r--r-- | src/FileAnalyzer.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/FileAnalyzer.cpp b/src/FileAnalyzer.cpp index 4deb8c3..1d24c5f 100644 --- a/src/FileAnalyzer.cpp +++ b/src/FileAnalyzer.cpp @@ -157,6 +157,7 @@ namespace QuickMedia { char size_arg_str[512]; snprintf(size_arg_str, sizeof(size_arg_str), "scale=%d:%d:force_original_aspect_ratio=decrease", width, height); + // TODO: Dont output as jpg, ffmpeg jpg is very slow const char *program_args[] = { "ffmpeg", "-y", "-v", "quiet", "-ss", seconds_str, "-i", file.get_filepath().c_str(), "-frames:v", "1", "-vf", size_arg_str, "--", destination_path_tmp.data.c_str(), nullptr }; if(exec_program(program_args, nullptr, nullptr, allowed_exit_status, 2) != 0) { fprintf(stderr, "Failed to execute ffmpeg, maybe its not installed?\n"); @@ -168,6 +169,7 @@ namespace QuickMedia { if(fallback_first_frame && get_file_type(destination_path_tmp) == FileType::FILE_NOT_FOUND) return video_get_frame(file, destination_path, width, height, 0, false); } else { + // TODO: Dont output as jpg, ffmpeg jpg is very slow const char *program_args[] = { "ffmpeg", "-y", "-v", "quiet", "-ss", seconds_str, "-i", file.get_filepath().c_str(), "-frames:v", "1", "--", destination_path_tmp.data.c_str(), nullptr }; if(exec_program(program_args, nullptr, nullptr, allowed_exit_status, 2) != 0) { fprintf(stderr, "Failed to execute ffmpeg, maybe its not installed?\n"); |