// Read media file and read the header information from container format
AVFormatContext* pFormatContext = avformat_alloc_context();
if (!pFormatContext) {
logging("ERROR could not allocate memory for format context");
return -1;
}
if (avformat_open_input(&pFormatContext, inputFilePath.string().c_str(), NULL, NULL) != 0) {
logging("ERROR could not open media file");
}
logging("format %s, duration %lld us