private static void InitialiseTestPattern() { _testPattern = new Bitmap(TEST_PATTERN_IMAGE_PATH); FFmpegInit.Initialise(FfmpegLogLevelEnum.AV_LOG_DEBUG); //_ffmpegEncoder = new VideoEncoder(AVCodecID.AV_CODEC_ID_VP8, _testPattern.Width, _testPattern.Height, FRAMES_PER_SECOND); _ffmpegEncoder = new VideoEncoder(AVCodecID.AV_CODEC_ID_H264, _testPattern.Width, _testPattern.Height, FRAMES_PER_SECOND); Console.WriteLine($"Codec name {_ffmpegEncoder.GetCodecName()}."); _videoFrameConverter = new VideoFrameConverter( new Size(_testPattern.Width, _testPattern.Height), AVPixelFormat.AV_PIX_FMT_BGRA, new Size(_testPattern.Width, _testPattern.Height), AVPixelFormat.AV_PIX_FMT_YUV420P); }