Vuforia sample code with SceneKit using Swift.
VuforiaSampleSwift/VuforiaSampleSwift/vuforia-sdk-ios-6-0-112
VuforiaSampleSwift/VuforiaSampleSwift/VuforiaAssets/ImageTargets
Header Search Paths
and Libarary Search Paths
in Build Settings.lincenseKey
and dataSetFile
in ViewController.swift.See ViewController.swift.
vuforiaManager = VuforiaManager(licenseKey: "your license key", dataSetFile: "your target xml file")
if let manager = vuforiaManager {
manager.delegate = self
manager.eaglView.sceneSource = self
manager.eaglView.delegate = self
manager.eaglView.setupRenderer()
self.view = manager.eaglView
}
vuforiaManager?.prepareWithOrientation(.Portrait)
...
do {
try vuforiaManager?.start()
}catch let error {
print("\(error)")
}
I am referring to the following page.