Browse Source

fix(ffmpeg): don't use deprecated features

reviewable/pr4746/r1
sudden6 8 years ago
parent
commit
2f13796acc
No known key found for this signature in database
GPG Key ID: 279509B499E032B9
  1. 4
      src/video/camerasource.cpp

4
src/video/camerasource.cpp

@ -332,6 +332,8 @@ void CameraSource::openDevice() @@ -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);
@ -342,8 +344,6 @@ void CameraSource::openDevice() @@ -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";

Loading…
Cancel
Save