maxBufferedFrameCount
This represents the maximum count of buffered frames. By default the value is 0, which means late frames are immediately dropped to maintain minimal latency.
Declaration
var maxBufferedFrameCount: Int { get set }Discussion
When set to a value greater than 0, the buffer absorbs minor timing jitter in the capture pipeline, reducing the possibility of dropping frames during temporary processing variations. Frames accumulate in the buffer up to the specified limit. Once the buffer reaches maxBufferedFrameCount, the oldest frame is removed to make room for each new incoming frame, maintaining a rolling window of buffered content.
Calling resetFrameBuffer() clears all buffered frames and resets the buffer count back to 0, allowing the buffer to fill again from empty.
The maximum supported value can be retrieved using maxSupportedBufferedFrameCount. Setting a value higher than the maximum supported value will raise an NSInvalidArgumentException.