mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
fix(ffmpeg): don't use deprecated features
This commit is contained in:
parent
6479b2c0e8
commit
2f13796acc
|
@ -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()
|
|||
}
|
||||
#endif
|
||||
|
||||
cctx->refcounted_frames = 1;
|
||||
|
||||
// Open codec
|
||||
if (avcodec_open2(cctx, codec, nullptr) < 0) {
|
||||
qWarning() << "Can't open codec";
|
||||
|
|
Loading…
Reference in New Issue
Block a user