MCPcopy Create free account
hub / github.com/RGAA-Software/GoDesk / InitLog

Method InitLog

src/render/plugins/ffmpeg_encoder/ffmpeg_encoder.cpp:297–312  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

295 }
296
297 void FFmpegEncoder::InitLog() {
298 std::call_once(init_log_flag_, []() {
299 av_log_set_level(AV_LOG_WARNING);
300 av_log_set_callback([](void* ptr, int level, const char* fmt, va_list vl)
301 {
302 static int print_prefix = 1;
303 std::string line;
304 line.resize(4096);
305 av_log_format_line(ptr, level, fmt, vl, line.data(), line.size(), &print_prefix);
306 line = StringUtil::Trim(line);
307 if (level <= AV_LOG_WARNING)
308 LOGI("ffmpeg_wlog:{}", line.c_str());
309 }
310 );
311 });
312 }
313
314 std::string FFmpegEncoder::GetDisplayEncoderName() {
315 return display_encoder_name_;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected