| 36 | |
| 37 | namespace { |
| 38 | static VideoFrame decode_one_frame(const std::string &path) { |
| 39 | JsonParam option; |
| 40 | option.parse(fmt::format("{{\"input_path\": \"{}\"}}", path)); |
| 41 | auto decoder = make_sync_func<std::tuple<>, std::tuple<VideoFrame>>( |
| 42 | ModuleInfo("c_ffmpeg_decoder"), option); |
| 43 | |
| 44 | VideoFrame vf; |
| 45 | std::tie(vf) = decoder(); |
| 46 | return vf; |
| 47 | } |
| 48 | |
| 49 | Domain<std::tuple<int, int, int, int>> AnyCrop() { // min size 4x4 in 1080p image |
| 50 | static const int width = 1920, height = 1080; |
no test coverage detected