зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1619709 - Check native_capturer in onFrameCaptured; r=ng
Differential Revision: https://phabricator.services.mozilla.com/D68450 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
72efef08df
Коммит
89f2fa3974
|
@ -187,15 +187,16 @@ public class VideoCaptureAndroid implements CameraVideoCapturer.CameraEventsHand
|
||||||
|
|
||||||
// Delivers a captured frame.
|
// Delivers a captured frame.
|
||||||
public void onFrameCaptured(VideoFrame frame) {
|
public void onFrameCaptured(VideoFrame frame) {
|
||||||
I420Buffer i420Buffer = frame.getBuffer().toI420();
|
if (native_capturer != 0) {
|
||||||
|
I420Buffer i420Buffer = frame.getBuffer().toI420();
|
||||||
|
ProvideCameraFrame(i420Buffer.getWidth(), i420Buffer.getHeight(),
|
||||||
|
i420Buffer.getDataY(), i420Buffer.getStrideY(),
|
||||||
|
i420Buffer.getDataU(), i420Buffer.getStrideU(),
|
||||||
|
i420Buffer.getDataV(), i420Buffer.getStrideV(),
|
||||||
|
frame.getRotation(),
|
||||||
|
frame.getTimestampNs() / 1000000, native_capturer);
|
||||||
|
|
||||||
ProvideCameraFrame(i420Buffer.getWidth(), i420Buffer.getHeight(),
|
i420Buffer.release();
|
||||||
i420Buffer.getDataY(), i420Buffer.getStrideY(),
|
}
|
||||||
i420Buffer.getDataU(), i420Buffer.getStrideU(),
|
|
||||||
i420Buffer.getDataV(), i420Buffer.getStrideV(),
|
|
||||||
frame.getRotation(),
|
|
||||||
frame.getTimestampNs() / 1000000, native_capturer);
|
|
||||||
|
|
||||||
i420Buffer.release();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче