Expand Minimize Picture-in-picture Power Device Status Voice Recognition Skip Back Skip Forward Minus Plus Play Search
Internet Explorer alert
This browser is not recommended for use with smartdevicelink.com, and may not function properly. Upgrade to a different browser to guarantee support of all features.
close alert
To Top Created with Sketch. To Top
To Bottom Created with Sketch. To Bottom
iOS Documentation
SDLVideoStreamingRange

SDLVideoStreamingRange Class Reference

Section Contents

Overview

A range of supported video streaming sizes from minimum to maximum

minimumAspectRatio

The minimum supported normalized aspect ratio, min value is 1.0, defaults to 1.0

Objective-C

@property (nonatomic) float minimumAspectRatio;

Swift

var minimumAspectRatio: Float { get set }

maximumAspectRatio

The maximum supported normalized aspect ratio, min value is 1.0, defaults to 9999.0

Objective-C

@property (nonatomic) float maximumAspectRatio;

Swift

var maximumAspectRatio: Float { get set }

minimumDiagonal

The minimum supported diagonal screen size in inches, defaults to 0.0 (matches any size)

Objective-C

@property (nonatomic) float minimumDiagonal;

Swift

var minimumDiagonal: Float { get set }

minimumResolution

The minimum resolution to support, it overrides .minimumAspectRatio

Objective-C

@property (nonatomic, strong, nullable) SDLImageResolution *minimumResolution;

Swift

var minimumResolution: SDLImageResolution? { get set }

maximumResolution

The maximum resolution to support, it overrides .maximumAspectRatio

Objective-C

@property (nonatomic, strong, nullable) SDLImageResolution *maximumResolution;

Swift

var maximumResolution: SDLImageResolution? { get set }

-init

Creates a disabled range without any min/max aspect ratio or min diagonal information.

Objective-C

- (nonnull instancetype)init;

Swift

init()

-initWithMinimumResolution:maximumResolution:

Create a video streaming range based on a minimum and maximum resolution

Objective-C

- (nonnull instancetype)
    initWithMinimumResolution:(nullable SDLImageResolution *)minResolution
            maximumResolution:(nullable SDLImageResolution *)maxResolution;

Swift

init(minimumResolution minResolution: SDLImageResolution?, maximumResolution maxResolution: SDLImageResolution?)

Parameters

minResolution

The minimum supported height / width resolution

maxResolution

The maximum supported height / width resolution

-initWithMinimumResolution:maximumResolution:minimumAspectRatio:maximumAspectRatio:minimumDiagonal:

Create a video streaming range with all supported options

Objective-C

- (nonnull instancetype)
    initWithMinimumResolution:(nullable SDLImageResolution *)minResolution
            maximumResolution:(nullable SDLImageResolution *)maxResolution
           minimumAspectRatio:(float)minimumAspectRatio
           maximumAspectRatio:(float)maximumAspectRatio
              minimumDiagonal:(float)minimumDiagonal;

Swift

init(minimumResolution minResolution: SDLImageResolution?, maximumResolution maxResolution: SDLImageResolution?, minimumAspectRatio: Float, maximumAspectRatio: Float, minimumDiagonal: Float)

Parameters

minResolution

The minimum supported height / width resolution

maxResolution

The maximum supported height / width resolution

minimumAspectRatio

The minimum supported normalized aspect ratio, min value is 1.0, defaults to 1.0

maximumAspectRatio

The maximum supported normalized aspect ratio, min value is 1.0, defaults to 9999.0

minimumDiagonal

The minimum supported diagonal screen size in inches, defaults to 0 (0 matches any size)

+disabled

A convenience method to create a disabled range with the min and max resolutions equal to zero

Objective-C

+ (nonnull instancetype)disabled;

Swift

class func disabled() -> Self

-isImageResolutionInRange:

Check if the argument is within the [.minimumResolution, .maximumResolution] range

Objective-C

- (BOOL)isImageResolutionInRange:(nonnull SDLImageResolution *)imageResolution;

Swift

func isImageResolution(inRange imageResolution: SDLImageResolution) -> Bool

-isAspectRatioInRange:

Check if the argument is within the [.minimumAspectRatio, .maximumAspectRatio] range

Objective-C

- (BOOL)isAspectRatioInRange:(float)aspectRatio;

Swift

func isAspectRatio(inRange aspectRatio: Float) -> Bool
View on GitHub.com
Previous Section Next Section