| 12 | namespace fl { |
| 13 | |
| 14 | Frame::Frame(int pixels_count) : mPixelsCount(pixels_count), mRgb(), mIsFromCodec(false) { |
| 15 | mRgb.resize(pixels_count); |
| 16 | if (pixels_count > 0) { |
| 17 | fl::memset((u8*)mRgb.data(), 0, pixels_count * sizeof(CRGB)); |
| 18 | } |
| 19 | } |
| 20 | |
| 21 | Frame::Frame(fl::u8* pixels, fl::u16 width, fl::u16 height, PixelFormat format, fl::u32 timestamp) |
| 22 | : mPixelsCount(static_cast<size_t>(width) * height), mRgb(), |