TVIVideoCaptureConsumer Protocol Reference

Conforms to NSObject
Declared in TVIVideoCapturer.h

Overview

TVIVideoCaptureConsumer consumes frames and status events from a TVICameraCapturer.

– consumeCapturedFrame: required method

Provides a frame to the consumer.

- (void)consumeCapturedFrame:(nonnull TVIVideoFrame *)frame

Parameters

frame

A TVIVideoFrame containing image data, and metadata.

Discussion

Before this method returns the consumer will retain the frame’s underlying imageBuffer. The CVImageBuffer will be asynchronously delivered to the video pipeline, and released once it has been rendered and/or encoded. Zero-copy rendering is possible if the CVImageBuffer properties contain kCVPixelBufferIOSurfacePropertiesKey, kCVPixelBufferMetalCompatibilityKey, or kCVPixelBufferOpenGLESCompatibilityKey. At the moment your renderers will receive an I420 buffer converted from imageBuffer which resides in main system memory.

Declared In

TVIVideoCapturer.h

– captureDidStart: required method

Signals to the consumer that capture has started, or failed to start.

- (void)captureDidStart:(BOOL)success

Parameters

success

YES if capture started, or NO if capture failed to start.

Discussion

It is safe to call this method inside of startCapture:consumer:.

Declared In

TVIVideoCapturer.h