VideoDevice
@objcMembers
@objc(SBCVideoDevice)
public class VideoDevice : NSObject
A device for capture video.
func flipCamera(call: DirectCall) {
let current = call.currentVideoDevice
let devices = call.availableVideoDevices
guard let device = devices.first(where: { $0.position != current?.position }) else { return }
call.selectVideoDevice(device) { error in
// do something when error has occurred.
}
}
Since
1.0.0- Tag: VideoDevice
-
An ID unique to the model of device corresponding to the receiver.
Since
1.0.0Declaration
Swift
public let uniqueId: String
-
A localized human-readable name for the receiver.
Since
1.0.0Declaration
Swift
public let localizedName: String
-
Indicates the physical position of an VideoDevice’s hardware.
Since
1.0.0Declaration
Swift
public let position: Position
-
Declaration
Swift
@objc(SBCVideoDevicePosition) public enum Position : Int, RawRepresentable