Create README.md
Browse files
README.md
ADDED
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
using System;
|
2 |
+
using System.Drawing;
|
3 |
+
using AForge.Video.FFMPEG;
|
4 |
+
|
5 |
+
class Program
|
6 |
+
{
|
7 |
+
static void Main()
|
8 |
+
{
|
9 |
+
var videoWriter = new VideoFileWriter();
|
10 |
+
videoWriter.Open("output.mp4", 640, 480, 25, VideoCodec.MPEG4);
|
11 |
+
|
12 |
+
for (int i = 0; i < 10; i++)
|
13 |
+
{
|
14 |
+
Bitmap image = (Bitmap)Image.FromFile($"image{i}.jpg");
|
15 |
+
videoWriter.WriteVideoFrame(image);
|
16 |
+
image.Dispose();
|
17 |
+
}
|
18 |
+
|
19 |
+
videoWriter.Close();
|
20 |
+
}
|
21 |
+
}
|