Skip to content
This repository has been archived by the owner on Jun 10, 2024. It is now read-only.

Commit

Permalink
add av_register_all() function call back into FFmpegDemuxer.cpp to av…
Browse files Browse the repository at this point in the history
…oid error about 'no AVFormatContext provided' (#289)
  • Loading branch information
TracelessLe authored Dec 13, 2021
1 parent 165d4e7 commit e7c311f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions PyNvCodec/TC/src/FFmpegDemuxer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,7 @@ FFmpegDemuxer::CreateFormatContext(const char *szFilePath,
}

AVFormatContext *ctx = nullptr;
av_register_all();
auto err = avformat_open_input(&ctx, szFilePath, nullptr, &options);
if (err < 0 || nullptr == ctx) {
cerr << "Can't open " << szFilePath << ": " << AvErrorToString(err) << "\n";
Expand Down

0 comments on commit e7c311f

Please sign in to comment.