From 7398fdf5927b4aa2314f5d21040205ae016086ab Mon Sep 17 00:00:00 2001 From: Svjatoslav Agejenko Date: Sun, 28 Dec 2014 13:11:51 +0200 Subject: [PATCH] ffmpeg is deprecated --- .../meviz/encoder/FormatsRegistry.java | 2 - .../meviz/encoder/converters/Ffmpeg.java | 43 ------------------- .../eu/svjatoslav/meviz/grabmemcard/Main.java | 4 +- 3 files changed, 2 insertions(+), 47 deletions(-) delete mode 100644 src/main/java/eu/svjatoslav/meviz/encoder/converters/Ffmpeg.java diff --git a/src/main/java/eu/svjatoslav/meviz/encoder/FormatsRegistry.java b/src/main/java/eu/svjatoslav/meviz/encoder/FormatsRegistry.java index 2d6a788..182d952 100755 --- a/src/main/java/eu/svjatoslav/meviz/encoder/FormatsRegistry.java +++ b/src/main/java/eu/svjatoslav/meviz/encoder/FormatsRegistry.java @@ -16,7 +16,6 @@ import eu.svjatoslav.meviz.encoder.converters.AbstractConverter; import eu.svjatoslav.meviz.encoder.converters.AvconvAudio; import eu.svjatoslav.meviz.encoder.converters.AvconvVideo; import eu.svjatoslav.meviz.encoder.converters.Convert; -import eu.svjatoslav.meviz.encoder.converters.Ffmpeg; import eu.svjatoslav.meviz.encoder.converters.Ffmpeg2theora; import eu.svjatoslav.meviz.encoder.converters.Flac; import eu.svjatoslav.meviz.encoder.converters.Ogg2Wav; @@ -28,7 +27,6 @@ public class FormatsRegistry { public FormatsRegistry() { // video conversion registerEncoder(new Ffmpeg2theora()); - registerEncoder(new Ffmpeg()); registerEncoder(new AvconvVideo()); // image conversion diff --git a/src/main/java/eu/svjatoslav/meviz/encoder/converters/Ffmpeg.java b/src/main/java/eu/svjatoslav/meviz/encoder/converters/Ffmpeg.java deleted file mode 100644 index d9efe3b..0000000 --- a/src/main/java/eu/svjatoslav/meviz/encoder/converters/Ffmpeg.java +++ /dev/null @@ -1,43 +0,0 @@ -/* - * Meviz - Various tools collection to work with multimedia. - * Copyright (C) 2012, Svjatoslav Agejenko, svjatoslav@svjatoslav.eu - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of version 2 of the GNU General Public License - * as published by the Free Software Foundation. - */ - -package eu.svjatoslav.meviz.encoder.converters; - -import java.io.File; -import java.util.List; - -import eu.svjatoslav.meviz.encoder.EncodingOptions; - -public class Ffmpeg extends AbstractConverter { - - @Override - public String getCommand(final File inputFile, final File targetFile, - final EncodingOptions options) { - - return "ffmpeg -i \"" + inputFile.getAbsolutePath() - + "\" -vcodec copy -acodec copy \"" - + targetFile.getAbsolutePath() + "\""; - } - - @Override - public List getSourceFileExtensions() { - return toList("mts"); - } - - @Override - public List getTargetFileExtensions() { - return toList("mkv"); - } - - @Override - public boolean isTerminalMandatory() { - return true; - } - -} diff --git a/src/main/java/eu/svjatoslav/meviz/grabmemcard/Main.java b/src/main/java/eu/svjatoslav/meviz/grabmemcard/Main.java index 99dfe0f..d6d194c 100755 --- a/src/main/java/eu/svjatoslav/meviz/grabmemcard/Main.java +++ b/src/main/java/eu/svjatoslav/meviz/grabmemcard/Main.java @@ -22,7 +22,7 @@ import eu.svjatoslav.meviz.encoder.EncodingOptions; import eu.svjatoslav.meviz.encoder.EncodingPlan; import eu.svjatoslav.meviz.encoder.EncodingTask; import eu.svjatoslav.meviz.encoder.converters.AbstractConverter; -import eu.svjatoslav.meviz.encoder.converters.Ffmpeg; +import eu.svjatoslav.meviz.encoder.converters.AvconvVideo; public class Main implements Module { @@ -86,7 +86,7 @@ public class Main implements Module { final File targetDirectory = getTargetDirectory(); targetDirectory.mkdirs(); - final AbstractConverter converter = new Ffmpeg(); + final AbstractConverter converter = new AvconvVideo(); final EncodingPlan encodingPlan = new EncodingPlan(); final String userName = System.getProperty("user.name"); -- 2.20.1