Use the new DecodingEnabled function

This commit is contained in:
Isaac Connor 2020-12-10 14:05:57 -05:00
parent 7f72d5399f
commit 7b1ca0e66d
1 changed files with 1 additions and 10 deletions

View File

@ -976,16 +976,7 @@ int FfmpegCamera::CaptureAndRecord(
}
} // end if keyframe or have_video_keyframe
if (
( monitor->GetFunction() == Monitor::RECORD or monitor->GetFunction() == Monitor::NODECT )
and
( monitor->GetOptSaveJPEGs() == 0 )
and
( monitor->GetOptVideoWriter() == Monitor::H264PASSTHROUGH )
) {
// In this specific case we don't need to do the decode.
Debug(1, "Not decoding");
} else {
if ( monitor->DecodingEnabled() ) {
ret = zm_send_packet_receive_frame(mVideoCodecContext, mRawFrame, packet);
if ( ret < 0 ) {
if ( AVERROR(EAGAIN) != ret ) {