ARHandlerProtocol
@objc
public protocol ARHandlerProtocol
The ARHandlerProtocol
provides a mechanism for your application
to handle features of ARViewController(Objc)
.
-
Takes screenshot of AR view, ignoring any overlapping UI elements.
Declaration
Swift
var takeScreenshot: UIImage? { get }
-
Current AR view state.
Declaration
Swift
var viewState: ARViewState { get }
-
Starts scanning.
Declaration
Swift
func startScanning()
-
Stops scanning.
Warning
Will be stopped automatically whenrecognitionTimeout
will be reached.Declaration
Swift
func stopScanning()
-
Destroys all loaded data.
Declaration
Swift
func cleanView()
-
Resumes camera.
Warning
This function will be executed automatically on UIApplicationDidBecomeActive if camera was active when application went to background.Declaration
Swift
func resumeCamera(animated: Bool)
Parameters
animated
Animates camera blur effect
-
Pauses camera.
Warning
This function will be executed automatically on UIApplicationWillResignActive if camera was active when application went to background.Declaration
Swift
func pauseCamera(animated: Bool)
Parameters
animated
Animates camera blur effect
-
Enables flash if available.
Note
Returns false if flash is unavailableDeclaration
Swift
@discardableResult func enableFlash() -> Bool
-
Disables flash.
Declaration
Swift
func disableFlash()
-
Current flash status.
Declaration
Swift
var isFlashEnabled: Bool { get }
-
Shows ARScene without tracking.
Note
You can get thisid
infunc recognizedMarker(withId: Int, assetIds: [Int])
Declaration
Swift
func showARSceneWithoutTracking(withMarkerId id: Int)
Parameters
id
marker id