SCCameraKitExplicitViewportProvider
@interface SCCameraKitExplicitViewportProvider : NSObject
Enables the configuration of a custom viewport for SCCameraKitPreviewView.
-
Initializes the ExplicitViewportProvider with the specified viewportSize, outputResolution, and safeArea.
Note
The delegate will be set automatically when this class is used to configure SCCameraKitPreviewView so that any change toviewportSize,outputResolution, andsafeAreais propagated.Declaration
Objective-C
- (nonnull instancetype)initWithViewportSize:(CGSize)viewportSize outputResolution:(CGSize)outputResolution safeArea:(CGRect)safeArea;Parameters
viewportSizeOutput viewport frame size.
outputResolutionOutput resolution size in pixels, not points (i.e. 1125x2436 not 375x812).
safeAreaA CGRect describing an area that the host app will not draw on top of.
-
Sets the output viewport size and propagates the change to SCCameraKitPreviewView.
Declaration
Objective-C
- (void)setViewportSize:(CGSize)viewportSize;Parameters
viewportSizeOutput viewport frame size.
-
Sets the output resolution and propagates the change to SCCameraKitPreviewView.
Declaration
Objective-C
- (void)setOutputResolution:(CGSize)outputResolution;Parameters
outputResolutionOutput resolution size in pixels, not points (i.e. 1125x2436 not 375x812).
-
Sets the safe area and propagates the change to SCCameraKitPreviewView.
Declaration
Objective-C
- (void)setSafeArea:(CGRect)safeArea;Parameters
safeAreaA CGRect describing an area that the host app will not draw on top of.
-
Unavailable
Use the designated initializer to pass in the required properties.
Declaration
Objective-C
- (nonnull instancetype)init; -
Unavailable
Undocumented
Declaration
Objective-C
+ (instancetype)new NS_UNAVAILABLE;