sudo yum update -y
sudo yum install git -y
git version
func setMaxFps(device: AVCaptureDevice) { | |
var minFPS = 0.0 | |
var maxFPS = 0.0 | |
var maxWidth:Int32 = 0 | |
var selectedFormat:AVCaptureDevice.Format? = nil | |
for format in device.formats { | |
for range in format.videoSupportedFrameRateRanges { | |
let desc = format.formatDescription | |
let dimentions = CMVideoFormatDescriptionGetDimensions(desc) |
def count_numbers(sorted_list, less_than): | |
count = 0 | |
length = len(sorted_list) | |
if not length: | |
return 0 | |
if length == 1: | |
return count + 1 if sorted_list[0] < less_than else count | |
elif sorted_list[-1] < less_than: | |
return count + length |