Skip to content
This repository has been archived by the owner on Feb 12, 2023. It is now read-only.

Commit

Permalink
fix(ffmpeg): don't use deprecated features
Browse files Browse the repository at this point in the history
  • Loading branch information
sudden6 committed Oct 18, 2017
1 parent 6479b2c commit 2f13796
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/video/camerasource.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,8 @@ void CameraSource::openDevice()
emit openFailed();
return;
}

cctx->refcounted_frames = 1;
#else
// Create a context for our codec, using the existing parameters
cctx = avcodec_alloc_context3(codec);
Expand All @@ -342,8 +344,6 @@ void CameraSource::openDevice()
}
#endif

cctx->refcounted_frames = 1;

// Open codec
if (avcodec_open2(cctx, codec, nullptr) < 0) {
qWarning() << "Can't open codec";
Expand Down

0 comments on commit 2f13796

Please sign in to comment.