diff --git a/MainWindow.xaml b/MainWindow.xaml
index f2e5ee2..aa78413 100644
--- a/MainWindow.xaml
+++ b/MainWindow.xaml
@@ -21,18 +21,27 @@
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
+ 循环
+ 无边框
+ 禁用视频
+ 禁用音频
+ 1280x720
+
+
+
+
diff --git a/MainWindow.xaml.cs b/MainWindow.xaml.cs
index 6c5af0b..be21a55 100644
--- a/MainWindow.xaml.cs
+++ b/MainWindow.xaml.cs
@@ -2,6 +2,7 @@
using io = System.IO;
using System.Windows;
using System.Text.RegularExpressions;
+using System.Collections;
namespace WpfApp1
{
@@ -188,23 +189,26 @@ private void Button_Click_3(object sender, RoutedEventArgs e)
private void Button_Click_5(object sender, RoutedEventArgs e)
{
if (checkNotInputFile()) return;
- string command = $"\"{input}\"";
- System.Diagnostics.Process.Start(ffplayExe, command);
- }
+ ArrayList options = new ArrayList();
+ if (isLoopPlay.IsChecked == true) options.Add("-loop 0");
+ if (t_vn.IsChecked == true) options.Add("-vn");
+ if (t_an.IsChecked == true) options.Add("-an");
+ if (t_noborder.IsChecked == true) options.Add("-noborder");
+
+ string[] size = t_size.Text.Split('x');
+ if (size.Length == 2)
+ {
+ if (size[0].Length != 0) options.Add($"-x {size[0]}");
+ if (size[1].Length != 0) options.Add($"-y {size[1]}");
+ }
+
+ options.Add($"\"{input}\"");
+
+ string command = string.Join(" ", (string[])options.ToArray(Type.GetType("System.String")));
- ///
- /// 循环播放输入文件
- ///
- ///
- ///
- private void Button_Click_16(object sender, RoutedEventArgs e)
- {
- if (checkNotInputFile()) return;
- string command = $"-loop 0 \"{input}\"";
System.Diagnostics.Process.Start(ffplayExe, command);
}
-
///
/// 音频填充视频
///
@@ -613,5 +617,22 @@ private void Button_Click_28(object sender, RoutedEventArgs e)
string command = $"-i \"{input}\" -b:v {toBitrate.Text} -c:a copy \"{oout}\"";
execute(command);
}
+
+ ///
+ /// 播放时控制器详情
+ ///
+ ///
+ ///
+ private void Button_Click_16(object sender, RoutedEventArgs e)
+ {
+ MessageBox.Show(
+ "f 切换全屏\n"+
+ "p 却换暂停\n"+
+ "m 切换静音\n"+
+ "9,0 减少和增加音量\n"+
+ "left/right 向后/向前搜索10秒\n" +
+ "down/up 向后/向前搜索1分钟\n"
+ );
+ }
}
}
diff --git a/README.md b/README.md
index 4bc9413..9420af6 100644
--- a/README.md
+++ b/README.md
@@ -4,4 +4,4 @@
- [下载ffmpeg.exe](https://github.com/BtbN/FFmpeg-Builds/releases)(lgpl.zip),然后将bin目录添加到PATH环境变量,或者将bin下面的exe拷贝到本软件的exe同级目录下
- 没有找到ffmpeg.exe将无法运行
-![](./images/2020-10-01-15-12-12.png)
\ No newline at end of file
+![](./images/2020-10-06-22-14-28.png)
\ No newline at end of file
diff --git a/images/2020-10-06-22-14-28.png b/images/2020-10-06-22-14-28.png
new file mode 100644
index 0000000..71e19ea
Binary files /dev/null and b/images/2020-10-06-22-14-28.png differ