* Update podfile * Update useCameraFormat.ts * Update API * Delete FormatFilter.md * Format CameraViewManager.m ObjC style * Make `getAvailableCameraDevices` synchronous/blocking * Create some docs * fix: Fix HardwareLevel types * fix: Use new device/format API * Use 60 FPS format as an example * Replace `Camera.getAvailableCameraDevices` with new `CameraDevices` API/Module * Fix Lint * KTLint options * Use continuation indent of 8 * Use 2 spaces for indent * Update .editorconfig * Format code * Update .editorconfig * Format more * Update VideoStabilizationMode.kt * fix: Expose `CameraDevicesManager` to ObjC * Update CameraPage.tsx * fix: `requiresMainQueueSetup() -> false` * Always prefer higher resolution * Update CameraDevicesManager.swift * Update CameraPage.tsx * Also filter pixelFormat * fix: Add AVFoundation import
		
			
				
	
	
		
			26 lines
		
	
	
		
			503 B
		
	
	
	
		
			Swift
		
	
	
	
	
	
			
		
		
	
	
			26 lines
		
	
	
		
			503 B
		
	
	
	
		
			Swift
		
	
	
	
	
	
| //
 | |
| //  AVCaptureDevice.Position+descriptor.swift
 | |
| //  mrousavy
 | |
| //
 | |
| //  Created by Marc Rousavy on 15.12.20.
 | |
| //  Copyright © 2020 mrousavy. All rights reserved.
 | |
| //
 | |
| 
 | |
| import AVFoundation
 | |
| import Foundation
 | |
| 
 | |
| extension AVCaptureDevice.Position {
 | |
|   var descriptor: String {
 | |
|     switch self {
 | |
|     case .back:
 | |
|       return "back"
 | |
|     case .front:
 | |
|       return "front"
 | |
|     case .unspecified:
 | |
|       return "external"
 | |
|     @unknown default:
 | |
|       fatalError("AVCaptureDevice.Position has unknown state.")
 | |
|     }
 | |
|   }
 | |
| }
 |