diff --git a/Tech/Tech.csproj b/Tech/Tech.csproj index c35f179..4043c17 100644 --- a/Tech/Tech.csproj +++ b/Tech/Tech.csproj @@ -42,6 +42,12 @@ ..\packages\LibVLCSharp.WinForms.3.6.7\lib\net40\LibVLCSharp.WinForms.dll + + ..\packages\WindowsAPICodePack-Core.1.1.1\lib\Microsoft.WindowsAPICodePack.dll + + + ..\packages\WindowsAPICodePack-Shell.1.1.1\lib\Microsoft.WindowsAPICodePack.Shell.dll + @@ -86,12 +92,6 @@ Form1.cs - - UserControl - - - MultiPlayerView.cs - UserControl @@ -106,12 +106,10 @@ UCOverview.cs + Form1.cs - - MultiPlayerView.cs - PlayerView.cs diff --git a/Tech/packages.config b/Tech/packages.config index a8a95d2..4fc1aa7 100644 --- a/Tech/packages.config +++ b/Tech/packages.config @@ -10,4 +10,6 @@ + + \ No newline at end of file diff --git a/Tech/util/Thumbnail.cs b/Tech/util/Thumbnail.cs new file mode 100644 index 0000000..0a11ce5 --- /dev/null +++ b/Tech/util/Thumbnail.cs @@ -0,0 +1,18 @@ +using System.Drawing; +using Microsoft.WindowsAPICodePack.Shell; + +namespace Tech_Demo.util +{ + public class Thumbnail + { + /** + * 視頻縮略圖工具欄 + */ + public static Bitmap GetThumbnailByPath(string filePath) + { + ShellFile shellFile = ShellFile.FromFilePath(filePath); + Bitmap thumbnail = shellFile.Thumbnail.ExtraLargeBitmap; + return thumbnail; + } + } +} \ No newline at end of file