fix: changed some config behaviour.
This commit is contained in:
parent
ea076dcf72
commit
fe55238b10
6 changed files with 39 additions and 52 deletions
|
@ -17,10 +17,9 @@ impl TranscodeJob {
|
|||
}
|
||||
|
||||
pub fn build_command(&self, ffmpeg_config: &ConfigFFmpeg) -> Command {
|
||||
let options = ffmpeg_config.build_command_options(&self.input, &self.output);
|
||||
let mut command = Command::new("ffmpeg");
|
||||
command.args(options.to_args());
|
||||
command
|
||||
ffmpeg_config
|
||||
.build_command_options(&self.input, &self.output)
|
||||
.to_command(&ffmpeg_config.path)
|
||||
}
|
||||
|
||||
pub fn check_if_exists(&self) -> bool {
|
||||
|
@ -28,6 +27,7 @@ impl TranscodeJob {
|
|||
}
|
||||
|
||||
pub fn run(&self, ffmpeg_config: &ConfigFFmpeg) -> Result<Child, error::Error> {
|
||||
debug!("Running job: {:#?}", &self.input);
|
||||
let mut command = self.build_command(ffmpeg_config);
|
||||
match command.spawn() {
|
||||
Ok(child) => Ok(child),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue