SCCameraKitInputDestination

Objective-C

@protocol SCCameraKitInputDestination

Swift

protocol InputDestination

The input destination is an intermediary for frame data.

  • Pass new video frame data into CameraKit. Call this every time your input generates new video frames.

    Declaration

    Objective-C

    - (void)input:(nonnull id<SCCameraKitInput>)input
        receivedVideoSampleBuffer:(nonnull CMSampleBufferRef)sampleBuffer;

    Swift

    func input(_ input: Input, receivedVideoSampleBuffer sampleBuffer: CMSampleBuffer)

    Parameters

    input

    the input providing data.

    sampleBuffer

    a sample buffer containing new video frame data.

  • Pass new audio frame data into CameraKit. Call this every time your input generates new audio frames.

    Declaration

    Objective-C

    - (void)input:(nonnull id<SCCameraKitInput>)input
        receivedAudioSampleBuffer:(nonnull CMSampleBufferRef)sampleBuffer;

    Swift

    func input(_ input: Input, receivedAudioSampleBuffer sampleBuffer: CMSampleBuffer)

    Parameters

    input

    the input providing data.

    sampleBuffer

    a sample buffer containing new audio frame data.

  • Indicates that the input has changed some attribute and that CameraKit should reconfigure itself accordingly.

    Declaration

    Objective-C

    - (void)inputChangedAttributes:(nonnull id<SCCameraKitInput>)input;

    Swift

    func inputChangedAttributes(_ input: Input)

    Parameters

    input

    the input that changed.