update the cmd of reverse video

update the cmd of reverse video
pull/112/head
xufulong 5 years ago
parent c5149d2969
commit b80c7bfb11
  1. 6
      app/src/main/java/com/frank/ffmpeg/util/FFmpegUtil.java
  2. 2
      app/src/main/res/layout/activity_video_handle.xml

@ -321,9 +321,9 @@ public class FFmpegUtil {
* @return 视频反序的命令行
*/
public static String[] reverseVideo(String inputFile, String targetFile) {
//FIXME 音频也反序
// String reverseVideo = "ffmpeg -i %s -filter_complex [0:v]reverse[v];[0:a]areverse[a] -map [v] -map [a] %s";
String reverseVideo = "ffmpeg -i %s -filter_complex [0:v]reverse[v] -map [v] %s";//单纯视频反序
//-vf reverse视频反序, -an去掉音频
//视频反序比较耗时, 建议用来处理1分钟以内的短视频
String reverseVideo = "ffmpeg -i %s -vf reverse -an %s";
reverseVideo = String.format(reverseVideo, inputFile, targetFile);
return reverseVideo.split(" ");
}

@ -93,7 +93,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:text="@string/video_reverse"
android:visibility="gone"/>
android:visibility="visible"/>
<Button
android:id="@+id/btn_denoise_video"

Loading…
Cancel
Save