-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
29 lines (27 loc) · 827 Bytes
/
Copy pathmain.cpp
File metadata and controls
29 lines (27 loc) · 827 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#include "FrameWriter.h"
int main() {
// const int width = 1920;
// const int height = 1080;
// uint8_t img[width * height * 3];
//
// for (unsigned char &i : img)
// i = 0;
//
// FrameWriter fr("test.mp4", "libx264", 60, width, height, "-preset ultrafast", img);
//
// for (int y = 0; y < 10; y++) {
// for (int x = 0; x < 100; x++) {
// int index = y * width * 3 + x * 3;
// img[index] = 255;
// img[index+1] = 255;
// img[index+2] = 0;
// fr.write_frame();
// }
// }
//
// fr.close_video();
std::vector<const char *> codecname = getcodecname();
std::vector<const char *> codeclongname = getcodeclongname();
for(int i = 0; i < codecname.size(); i++)
printf("%s: %s\n", codecname[i], codeclongname[i]);
}