Flatbuffer/Protobuf now able to receive rgba data (#1399)

* Flatbuffer/Protobuf now able to receive rgba data

* Proto/Flat schema comment added

* Prevent diveded by zero

* Address LGTM findings

* Fix EncoderThread & cleanup

Co-authored-by: LordGrey <lordgrey.emmel@gmail.com>
This commit is contained in:
Markus
2022-01-09 17:23:50 +01:00
committed by GitHub
parent 2f573a117f
commit 98654e48f6
11 changed files with 97 additions and 34 deletions

View File

@@ -529,7 +529,11 @@ void MFGrabber::process_image(const void *frameImageBuffer, int size)
return;
// We do want a new frame...
#ifdef HAVE_TURBO_JPEG
if (size < _frameByteSize && _pixelFormat != PixelFormat::MJPEG)
#else
if (size < _frameByteSize)
#endif
Error(_log, "Frame too small: %d != %d", size, _frameByteSize);
else if (_threadManager != nullptr)
{