├── ARKitMeshTest ├── Assets.xcassets │ ├── Contents.json │ └── AppIcon.appiconset │ │ └── Contents.json ├── art.scnassets │ ├── scene.scn │ ├── texture.png │ └── uvtexturechecker.png ├── simd+Convenience.swift ├── ShaderModifiers.swift ├── Base.lproj │ ├── LaunchScreen.storyboard │ └── Main.storyboard ├── Info.plist ├── AppDelegate.swift ├── SCNGeometry+FromAnchor.swift └── ViewController.swift ├── ARKitMeshTest.xcodeproj ├── project.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ └── IDEWorkspaceChecks.plist └── project.pbxproj ├── README.md └── .gitignore /ARKitMeshTest/Assets.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "author" : "xcode", 4 | "version" : 1 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /ARKitMeshTest/art.scnassets/scene.scn: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/apparata/ARKitMeshTest/HEAD/ARKitMeshTest/art.scnassets/scene.scn -------------------------------------------------------------------------------- /ARKitMeshTest/art.scnassets/texture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/apparata/ARKitMeshTest/HEAD/ARKitMeshTest/art.scnassets/texture.png -------------------------------------------------------------------------------- /ARKitMeshTest/art.scnassets/uvtexturechecker.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/apparata/ARKitMeshTest/HEAD/ARKitMeshTest/art.scnassets/uvtexturechecker.png -------------------------------------------------------------------------------- /ARKitMeshTest/simd+Convenience.swift: -------------------------------------------------------------------------------- 1 | 2 | import simd 3 | 4 | extension simd_float4x4 { 5 | var position: simd_float3 { 6 | return simd_float3(columns.3.x, columns.3.y, columns.3.z) 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /ARKitMeshTest.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # ARKitMeshTest 2 | 3 | Simple test app for iPad Pro with LiDAR. Renders the LiDAR mesh in SceneKit. 4 | 5 | The triplanar shader modifier calculation is not entirely correct, but it's a step in the right direction for texture coordinates in world space. 6 | -------------------------------------------------------------------------------- /ARKitMeshTest.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /ARKitMeshTest/ShaderModifiers.swift: -------------------------------------------------------------------------------- 1 | 2 | import Foundation 3 | 4 | // Warning: This triplanar calculation is not entirely correct. 🙂 5 | 6 | let geometryShaderModifierMTL = """ 7 | #pragma body 8 | float4 worldPosition = scn_node.modelTransform * _geometry.position; 9 | float3 worldNormal; 10 | worldNormal = _geometry.normal.xxx * scn_node.modelTransform[0].xyz; 11 | worldNormal += _geometry.normal.yyy * scn_node.modelTransform[1].xyz; 12 | worldNormal += _geometry.normal.zzz * scn_node.modelTransform[2].xyz; 13 | worldNormal = normalize(worldNormal.xyz); 14 | 15 | float2 uv; 16 | if (abs(worldNormal.x) > 0.5) { 17 | uv = float2((worldPosition.x), (worldPosition.z)); 18 | } else if (abs(worldNormal.z) > 0.5) { 19 | uv = float2((worldPosition.y), (worldPosition.z)); 20 | } else { 21 | uv = float2((worldPosition.x), (worldPosition.y)); 22 | } 23 | 24 | _geometry.texcoords[0] = uv; 25 | """ 26 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Xcode 2 | # 3 | # gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore 4 | 5 | ## Build generated 6 | build/ 7 | DerivedData 8 | 9 | ## Various settings 10 | *.pbxuser 11 | !default.pbxuser 12 | *.mode1v3 13 | !default.mode1v3 14 | *.mode2v3 15 | !default.mode2v3 16 | *.perspectivev3 17 | !default.perspectivev3 18 | xcuserdata 19 | 20 | ## Other 21 | *.xccheckout 22 | *.moved-aside 23 | *.xcuserstate 24 | *.xcscmblueprint 25 | 26 | ## Obj-C/Swift specific 27 | *.hmap 28 | *.ipa 29 | 30 | # Swift Package Manager 31 | # 32 | # Add this line if you want to avoid checking in source code from Swift Package Manager dependencies. 33 | Packages/ 34 | .build/ 35 | .swiftpm 36 | 37 | # CocoaPods 38 | # 39 | # We recommend against adding the Pods directory to your .gitignore. However 40 | # you should judge for yourself, the pros and cons are mentioned at: 41 | # https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control 42 | # 43 | # Pods/ 44 | 45 | # Carthage 46 | # 47 | # Add this line if you want to avoid checking in source code from Carthage dependencies. 48 | Carthage/Carthage/Checkouts 49 | Carthage/Carthage/Build 50 | 51 | # fastlane 52 | # 53 | # It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the 54 | # screenshots whenever they are needed. 55 | # For more information about the recommended setup visit: 56 | # https://github.com/fastlane/fastlane/blob/master/docs/Gitignore.md 57 | 58 | fastlane/report.xml 59 | fastlane/screenshots 60 | -------------------------------------------------------------------------------- /ARKitMeshTest/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /ARKitMeshTest/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | $(PRODUCT_BUNDLE_PACKAGE_TYPE) 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleVersion 20 | 1 21 | LSRequiresIPhoneOS 22 | 23 | NSCameraUsageDescription 24 | 25 | UILaunchStoryboardName 26 | LaunchScreen 27 | UIMainStoryboardFile 28 | Main 29 | UIRequiredDeviceCapabilities 30 | 31 | armv7 32 | arkit 33 | 34 | UIStatusBarHidden 35 | 36 | UISupportedInterfaceOrientations 37 | 38 | UIInterfaceOrientationPortrait 39 | UIInterfaceOrientationLandscapeLeft 40 | UIInterfaceOrientationLandscapeRight 41 | 42 | UISupportedInterfaceOrientations~ipad 43 | 44 | UIInterfaceOrientationPortrait 45 | UIInterfaceOrientationPortraitUpsideDown 46 | UIInterfaceOrientationLandscapeLeft 47 | UIInterfaceOrientationLandscapeRight 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /ARKitMeshTest/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | 2 | import UIKit 3 | 4 | @UIApplicationMain 5 | class AppDelegate: UIResponder, UIApplicationDelegate { 6 | 7 | var window: UIWindow? 8 | 9 | 10 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { 11 | // Override point for customization after application launch. 12 | return true 13 | } 14 | 15 | func applicationWillResignActive(_ application: UIApplication) { 16 | // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. 17 | // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. 18 | } 19 | 20 | func applicationDidEnterBackground(_ application: UIApplication) { 21 | // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 22 | } 23 | 24 | func applicationWillEnterForeground(_ application: UIApplication) { 25 | // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. 26 | } 27 | 28 | func applicationDidBecomeActive(_ application: UIApplication) { 29 | // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. 30 | } 31 | 32 | 33 | } 34 | 35 | -------------------------------------------------------------------------------- /ARKitMeshTest/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "scale" : "2x", 6 | "size" : "20x20" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "scale" : "3x", 11 | "size" : "20x20" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "scale" : "2x", 16 | "size" : "29x29" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "scale" : "3x", 21 | "size" : "29x29" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "scale" : "2x", 26 | "size" : "40x40" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "scale" : "3x", 31 | "size" : "40x40" 32 | }, 33 | { 34 | "idiom" : "iphone", 35 | "scale" : "2x", 36 | "size" : "60x60" 37 | }, 38 | { 39 | "idiom" : "iphone", 40 | "scale" : "3x", 41 | "size" : "60x60" 42 | }, 43 | { 44 | "idiom" : "ipad", 45 | "scale" : "1x", 46 | "size" : "20x20" 47 | }, 48 | { 49 | "idiom" : "ipad", 50 | "scale" : "2x", 51 | "size" : "20x20" 52 | }, 53 | { 54 | "idiom" : "ipad", 55 | "scale" : "1x", 56 | "size" : "29x29" 57 | }, 58 | { 59 | "idiom" : "ipad", 60 | "scale" : "2x", 61 | "size" : "29x29" 62 | }, 63 | { 64 | "idiom" : "ipad", 65 | "scale" : "1x", 66 | "size" : "40x40" 67 | }, 68 | { 69 | "idiom" : "ipad", 70 | "scale" : "2x", 71 | "size" : "40x40" 72 | }, 73 | { 74 | "idiom" : "ipad", 75 | "scale" : "1x", 76 | "size" : "76x76" 77 | }, 78 | { 79 | "idiom" : "ipad", 80 | "scale" : "2x", 81 | "size" : "76x76" 82 | }, 83 | { 84 | "idiom" : "ipad", 85 | "scale" : "2x", 86 | "size" : "83.5x83.5" 87 | }, 88 | { 89 | "idiom" : "ios-marketing", 90 | "scale" : "1x", 91 | "size" : "1024x1024" 92 | } 93 | ], 94 | "info" : { 95 | "author" : "xcode", 96 | "version" : 1 97 | } 98 | } 99 | -------------------------------------------------------------------------------- /ARKitMeshTest/SCNGeometry+FromAnchor.swift: -------------------------------------------------------------------------------- 1 | 2 | import SceneKit 3 | import ARKit 4 | 5 | extension SCNGeometry { 6 | 7 | public static func makeFromMeshAnchor(_ meshAnchor: ARMeshAnchor, materials: [SCNMaterial]) -> SCNGeometry { 8 | let vertices = meshAnchor.geometry.vertices 9 | let normals = meshAnchor.geometry.normals 10 | let faces = meshAnchor.geometry.faces 11 | 12 | let vertexSource = SCNGeometrySource(buffer: vertices.buffer, 13 | vertexFormat: vertices.format, 14 | semantic: .vertex, 15 | vertexCount: vertices.count, 16 | dataOffset: vertices.offset, 17 | dataStride: vertices.stride) 18 | 19 | let normalSource = SCNGeometrySource(buffer: normals.buffer, 20 | vertexFormat: normals.format, 21 | semantic: .normal, 22 | vertexCount: normals.count, 23 | dataOffset: normals.offset, 24 | dataStride: normals.stride) 25 | 26 | let uvSource = SCNGeometrySource(buffer: vertices.buffer, 27 | vertexFormat: MTLVertexFormat.float2, 28 | semantic: .texcoord, 29 | vertexCount: vertices.count, 30 | dataOffset: vertices.offset, 31 | dataStride: vertices.stride) 32 | 33 | let triangleData = Data(bytesNoCopy: faces.buffer.contents(), 34 | count: faces.buffer.length, 35 | deallocator: .none) 36 | 37 | let geometryElement = SCNGeometryElement(data: triangleData, 38 | primitiveType: .triangles, 39 | primitiveCount: faces.count, 40 | bytesPerIndex: faces.bytesPerIndex) 41 | 42 | let sources = [vertexSource, normalSource, uvSource] 43 | let geometry = SCNGeometry(sources: sources, elements: [geometryElement]) 44 | 45 | geometry.materials = materials 46 | 47 | return geometry; 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /ARKitMeshTest/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /ARKitMeshTest/ViewController.swift: -------------------------------------------------------------------------------- 1 | 2 | import UIKit 3 | import SceneKit 4 | import ARKit 5 | 6 | class ViewController: UIViewController, ARSCNViewDelegate { 7 | 8 | @IBOutlet var sceneView: ARSCNView! 9 | 10 | private var knownAnchors = Dictionary() 11 | 12 | private let meshMaterial = SCNMaterial() 13 | 14 | override func viewDidLoad() { 15 | super.viewDidLoad() 16 | 17 | sceneView.delegate = self 18 | sceneView.showsStatistics = true 19 | 20 | let scene = SCNScene(named: "art.scnassets/scene.scn")! 21 | sceneView.scene = scene 22 | 23 | meshMaterial.shaderModifiers = [ 24 | .geometry: geometryShaderModifierMTL 25 | ] 26 | 27 | //meshMaterial.fillMode = .lines 28 | let image = UIImage(named: "art.scnassets/uvtexturechecker.png")! 29 | meshMaterial.diffuse.contents = image 30 | meshMaterial.diffuse.wrapS = .repeat 31 | meshMaterial.diffuse.wrapT = .repeat 32 | meshMaterial.emission.contents = UIColor.black 33 | meshMaterial.lightingModel = .constant 34 | meshMaterial.blendMode = .alpha 35 | } 36 | 37 | override func viewWillAppear(_ animated: Bool) { 38 | super.viewWillAppear(animated) 39 | 40 | let configuration = ARWorldTrackingConfiguration() 41 | configuration.sceneReconstruction = .mesh 42 | 43 | sceneView.session.run(configuration) 44 | 45 | sceneView.session.delegate = self 46 | } 47 | 48 | override func viewWillDisappear(_ animated: Bool) { 49 | super.viewWillDisappear(animated) 50 | 51 | sceneView.session.pause() 52 | } 53 | } 54 | 55 | // MARK: - ARSessionDelegate 56 | 57 | extension ViewController: ARSessionDelegate { 58 | 59 | func session(_ session: ARSession, didAdd anchors: [ARAnchor]) { 60 | for anchor in anchors { 61 | var sceneNode: SCNNode? 62 | 63 | if let meshAnchor = anchor as? ARMeshAnchor { 64 | let geometry = SCNGeometry.makeFromMeshAnchor(meshAnchor, materials: [meshMaterial]) 65 | sceneNode = SCNNode(geometry: geometry) 66 | } 67 | 68 | if let node = sceneNode { 69 | node.simdTransform = anchor.transform 70 | knownAnchors[anchor.identifier] = node 71 | sceneView.scene.rootNode.addChildNode(node) 72 | } 73 | } 74 | } 75 | 76 | func session(_ session: ARSession, didUpdate anchors: [ARAnchor]) { 77 | for anchor in anchors { 78 | if let node = knownAnchors[anchor.identifier] { 79 | if let meshAnchor = anchor as? ARMeshAnchor { 80 | node.geometry = SCNGeometry.makeFromMeshAnchor(meshAnchor, materials: [meshMaterial]) 81 | } 82 | node.simdTransform = anchor.transform 83 | } 84 | } 85 | } 86 | 87 | func session(_ session: ARSession, didRemove anchors: [ARAnchor]) { 88 | for anchor in anchors { 89 | if let meshAnchor = anchor as? ARMeshAnchor, 90 | let node = knownAnchors[meshAnchor.identifier] { 91 | node.removeFromParentNode() 92 | knownAnchors.removeValue(forKey: meshAnchor.identifier) 93 | } 94 | } 95 | } 96 | } 97 | -------------------------------------------------------------------------------- /ARKitMeshTest.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 50; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 5B58939E246488AE001925FD /* simd+Convenience.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B58939D246488AE001925FD /* simd+Convenience.swift */; }; 11 | 5B5893A024648D8B001925FD /* ShaderModifiers.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B58939F24648D8B001925FD /* ShaderModifiers.swift */; }; 12 | 5BA81904244E372700459FD3 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5BA81903244E372700459FD3 /* AppDelegate.swift */; }; 13 | 5BA81906244E372700459FD3 /* art.scnassets in Resources */ = {isa = PBXBuildFile; fileRef = 5BA81905244E372700459FD3 /* art.scnassets */; }; 14 | 5BA81908244E372700459FD3 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5BA81907244E372700459FD3 /* ViewController.swift */; }; 15 | 5BA8190B244E372700459FD3 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 5BA81909244E372700459FD3 /* Main.storyboard */; }; 16 | 5BA8190D244E372A00459FD3 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 5BA8190C244E372A00459FD3 /* Assets.xcassets */; }; 17 | 5BA81910244E372A00459FD3 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 5BA8190E244E372A00459FD3 /* LaunchScreen.storyboard */; }; 18 | 5BA81918244E445C00459FD3 /* SCNGeometry+FromAnchor.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5BA81917244E445C00459FD3 /* SCNGeometry+FromAnchor.swift */; }; 19 | /* End PBXBuildFile section */ 20 | 21 | /* Begin PBXFileReference section */ 22 | 5B58939D246488AE001925FD /* simd+Convenience.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "simd+Convenience.swift"; sourceTree = ""; }; 23 | 5B58939F24648D8B001925FD /* ShaderModifiers.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ShaderModifiers.swift; sourceTree = ""; }; 24 | 5BA81900244E372700459FD3 /* ARKitMeshTest.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ARKitMeshTest.app; sourceTree = BUILT_PRODUCTS_DIR; }; 25 | 5BA81903244E372700459FD3 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; 26 | 5BA81905244E372700459FD3 /* art.scnassets */ = {isa = PBXFileReference; lastKnownFileType = wrapper.scnassets; path = art.scnassets; sourceTree = ""; }; 27 | 5BA81907244E372700459FD3 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; 28 | 5BA8190A244E372700459FD3 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; 29 | 5BA8190C244E372A00459FD3 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; 30 | 5BA8190F244E372A00459FD3 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; 31 | 5BA81911244E372A00459FD3 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 32 | 5BA81917244E445C00459FD3 /* SCNGeometry+FromAnchor.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "SCNGeometry+FromAnchor.swift"; sourceTree = ""; }; 33 | /* End PBXFileReference section */ 34 | 35 | /* Begin PBXFrameworksBuildPhase section */ 36 | 5BA818FD244E372700459FD3 /* Frameworks */ = { 37 | isa = PBXFrameworksBuildPhase; 38 | buildActionMask = 2147483647; 39 | files = ( 40 | ); 41 | runOnlyForDeploymentPostprocessing = 0; 42 | }; 43 | /* End PBXFrameworksBuildPhase section */ 44 | 45 | /* Begin PBXGroup section */ 46 | 5BA818F7244E372700459FD3 = { 47 | isa = PBXGroup; 48 | children = ( 49 | 5BA81902244E372700459FD3 /* ARKitMeshTest */, 50 | 5BA81901244E372700459FD3 /* Products */, 51 | ); 52 | sourceTree = ""; 53 | }; 54 | 5BA81901244E372700459FD3 /* Products */ = { 55 | isa = PBXGroup; 56 | children = ( 57 | 5BA81900244E372700459FD3 /* ARKitMeshTest.app */, 58 | ); 59 | name = Products; 60 | sourceTree = ""; 61 | }; 62 | 5BA81902244E372700459FD3 /* ARKitMeshTest */ = { 63 | isa = PBXGroup; 64 | children = ( 65 | 5BA81903244E372700459FD3 /* AppDelegate.swift */, 66 | 5BA81905244E372700459FD3 /* art.scnassets */, 67 | 5BA81907244E372700459FD3 /* ViewController.swift */, 68 | 5B58939F24648D8B001925FD /* ShaderModifiers.swift */, 69 | 5B58939D246488AE001925FD /* simd+Convenience.swift */, 70 | 5BA81917244E445C00459FD3 /* SCNGeometry+FromAnchor.swift */, 71 | 5BA81909244E372700459FD3 /* Main.storyboard */, 72 | 5BA8190C244E372A00459FD3 /* Assets.xcassets */, 73 | 5BA8190E244E372A00459FD3 /* LaunchScreen.storyboard */, 74 | 5BA81911244E372A00459FD3 /* Info.plist */, 75 | ); 76 | path = ARKitMeshTest; 77 | sourceTree = ""; 78 | }; 79 | /* End PBXGroup section */ 80 | 81 | /* Begin PBXNativeTarget section */ 82 | 5BA818FF244E372700459FD3 /* ARKitMeshTest */ = { 83 | isa = PBXNativeTarget; 84 | buildConfigurationList = 5BA81914244E372A00459FD3 /* Build configuration list for PBXNativeTarget "ARKitMeshTest" */; 85 | buildPhases = ( 86 | 5BA818FC244E372700459FD3 /* Sources */, 87 | 5BA818FD244E372700459FD3 /* Frameworks */, 88 | 5BA818FE244E372700459FD3 /* Resources */, 89 | ); 90 | buildRules = ( 91 | ); 92 | dependencies = ( 93 | ); 94 | name = ARKitMeshTest; 95 | productName = ARKitMeshTest; 96 | productReference = 5BA81900244E372700459FD3 /* ARKitMeshTest.app */; 97 | productType = "com.apple.product-type.application"; 98 | }; 99 | /* End PBXNativeTarget section */ 100 | 101 | /* Begin PBXProject section */ 102 | 5BA818F8244E372700459FD3 /* Project object */ = { 103 | isa = PBXProject; 104 | attributes = { 105 | LastSwiftUpdateCheck = 1140; 106 | LastUpgradeCheck = 1140; 107 | ORGANIZATIONNAME = "Apparata AB"; 108 | TargetAttributes = { 109 | 5BA818FF244E372700459FD3 = { 110 | CreatedOnToolsVersion = 11.4.1; 111 | }; 112 | }; 113 | }; 114 | buildConfigurationList = 5BA818FB244E372700459FD3 /* Build configuration list for PBXProject "ARKitMeshTest" */; 115 | compatibilityVersion = "Xcode 9.3"; 116 | developmentRegion = en; 117 | hasScannedForEncodings = 0; 118 | knownRegions = ( 119 | en, 120 | Base, 121 | ); 122 | mainGroup = 5BA818F7244E372700459FD3; 123 | productRefGroup = 5BA81901244E372700459FD3 /* Products */; 124 | projectDirPath = ""; 125 | projectRoot = ""; 126 | targets = ( 127 | 5BA818FF244E372700459FD3 /* ARKitMeshTest */, 128 | ); 129 | }; 130 | /* End PBXProject section */ 131 | 132 | /* Begin PBXResourcesBuildPhase section */ 133 | 5BA818FE244E372700459FD3 /* Resources */ = { 134 | isa = PBXResourcesBuildPhase; 135 | buildActionMask = 2147483647; 136 | files = ( 137 | 5BA81906244E372700459FD3 /* art.scnassets in Resources */, 138 | 5BA81910244E372A00459FD3 /* LaunchScreen.storyboard in Resources */, 139 | 5BA8190D244E372A00459FD3 /* Assets.xcassets in Resources */, 140 | 5BA8190B244E372700459FD3 /* Main.storyboard in Resources */, 141 | ); 142 | runOnlyForDeploymentPostprocessing = 0; 143 | }; 144 | /* End PBXResourcesBuildPhase section */ 145 | 146 | /* Begin PBXSourcesBuildPhase section */ 147 | 5BA818FC244E372700459FD3 /* Sources */ = { 148 | isa = PBXSourcesBuildPhase; 149 | buildActionMask = 2147483647; 150 | files = ( 151 | 5BA81918244E445C00459FD3 /* SCNGeometry+FromAnchor.swift in Sources */, 152 | 5BA81908244E372700459FD3 /* ViewController.swift in Sources */, 153 | 5B5893A024648D8B001925FD /* ShaderModifiers.swift in Sources */, 154 | 5B58939E246488AE001925FD /* simd+Convenience.swift in Sources */, 155 | 5BA81904244E372700459FD3 /* AppDelegate.swift in Sources */, 156 | ); 157 | runOnlyForDeploymentPostprocessing = 0; 158 | }; 159 | /* End PBXSourcesBuildPhase section */ 160 | 161 | /* Begin PBXVariantGroup section */ 162 | 5BA81909244E372700459FD3 /* Main.storyboard */ = { 163 | isa = PBXVariantGroup; 164 | children = ( 165 | 5BA8190A244E372700459FD3 /* Base */, 166 | ); 167 | name = Main.storyboard; 168 | sourceTree = ""; 169 | }; 170 | 5BA8190E244E372A00459FD3 /* LaunchScreen.storyboard */ = { 171 | isa = PBXVariantGroup; 172 | children = ( 173 | 5BA8190F244E372A00459FD3 /* Base */, 174 | ); 175 | name = LaunchScreen.storyboard; 176 | sourceTree = ""; 177 | }; 178 | /* End PBXVariantGroup section */ 179 | 180 | /* Begin XCBuildConfiguration section */ 181 | 5BA81912244E372A00459FD3 /* Debug */ = { 182 | isa = XCBuildConfiguration; 183 | buildSettings = { 184 | ALWAYS_SEARCH_USER_PATHS = NO; 185 | CLANG_ANALYZER_NONNULL = YES; 186 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 187 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 188 | CLANG_CXX_LIBRARY = "libc++"; 189 | CLANG_ENABLE_MODULES = YES; 190 | CLANG_ENABLE_OBJC_ARC = YES; 191 | CLANG_ENABLE_OBJC_WEAK = YES; 192 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 193 | CLANG_WARN_BOOL_CONVERSION = YES; 194 | CLANG_WARN_COMMA = YES; 195 | CLANG_WARN_CONSTANT_CONVERSION = YES; 196 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 197 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 198 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 199 | CLANG_WARN_EMPTY_BODY = YES; 200 | CLANG_WARN_ENUM_CONVERSION = YES; 201 | CLANG_WARN_INFINITE_RECURSION = YES; 202 | CLANG_WARN_INT_CONVERSION = YES; 203 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 204 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 205 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 206 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 207 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 208 | CLANG_WARN_STRICT_PROTOTYPES = YES; 209 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 210 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 211 | CLANG_WARN_UNREACHABLE_CODE = YES; 212 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 213 | COPY_PHASE_STRIP = NO; 214 | DEBUG_INFORMATION_FORMAT = dwarf; 215 | ENABLE_STRICT_OBJC_MSGSEND = YES; 216 | ENABLE_TESTABILITY = YES; 217 | GCC_C_LANGUAGE_STANDARD = gnu11; 218 | GCC_DYNAMIC_NO_PIC = NO; 219 | GCC_NO_COMMON_BLOCKS = YES; 220 | GCC_OPTIMIZATION_LEVEL = 0; 221 | GCC_PREPROCESSOR_DEFINITIONS = ( 222 | "DEBUG=1", 223 | "$(inherited)", 224 | ); 225 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 226 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 227 | GCC_WARN_UNDECLARED_SELECTOR = YES; 228 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 229 | GCC_WARN_UNUSED_FUNCTION = YES; 230 | GCC_WARN_UNUSED_VARIABLE = YES; 231 | IPHONEOS_DEPLOYMENT_TARGET = 13.4; 232 | MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; 233 | MTL_FAST_MATH = YES; 234 | ONLY_ACTIVE_ARCH = YES; 235 | SDKROOT = iphoneos; 236 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; 237 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 238 | }; 239 | name = Debug; 240 | }; 241 | 5BA81913244E372A00459FD3 /* Release */ = { 242 | isa = XCBuildConfiguration; 243 | buildSettings = { 244 | ALWAYS_SEARCH_USER_PATHS = NO; 245 | CLANG_ANALYZER_NONNULL = YES; 246 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; 247 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; 248 | CLANG_CXX_LIBRARY = "libc++"; 249 | CLANG_ENABLE_MODULES = YES; 250 | CLANG_ENABLE_OBJC_ARC = YES; 251 | CLANG_ENABLE_OBJC_WEAK = YES; 252 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 253 | CLANG_WARN_BOOL_CONVERSION = YES; 254 | CLANG_WARN_COMMA = YES; 255 | CLANG_WARN_CONSTANT_CONVERSION = YES; 256 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 257 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 258 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES; 259 | CLANG_WARN_EMPTY_BODY = YES; 260 | CLANG_WARN_ENUM_CONVERSION = YES; 261 | CLANG_WARN_INFINITE_RECURSION = YES; 262 | CLANG_WARN_INT_CONVERSION = YES; 263 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 264 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 265 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 266 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 267 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 268 | CLANG_WARN_STRICT_PROTOTYPES = YES; 269 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 270 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; 271 | CLANG_WARN_UNREACHABLE_CODE = YES; 272 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 273 | COPY_PHASE_STRIP = NO; 274 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; 275 | ENABLE_NS_ASSERTIONS = NO; 276 | ENABLE_STRICT_OBJC_MSGSEND = YES; 277 | GCC_C_LANGUAGE_STANDARD = gnu11; 278 | GCC_NO_COMMON_BLOCKS = YES; 279 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 280 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 281 | GCC_WARN_UNDECLARED_SELECTOR = YES; 282 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 283 | GCC_WARN_UNUSED_FUNCTION = YES; 284 | GCC_WARN_UNUSED_VARIABLE = YES; 285 | IPHONEOS_DEPLOYMENT_TARGET = 13.4; 286 | MTL_ENABLE_DEBUG_INFO = NO; 287 | MTL_FAST_MATH = YES; 288 | SDKROOT = iphoneos; 289 | SWIFT_COMPILATION_MODE = wholemodule; 290 | SWIFT_OPTIMIZATION_LEVEL = "-O"; 291 | VALIDATE_PRODUCT = YES; 292 | }; 293 | name = Release; 294 | }; 295 | 5BA81915244E372A00459FD3 /* Debug */ = { 296 | isa = XCBuildConfiguration; 297 | buildSettings = { 298 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 299 | CODE_SIGN_IDENTITY = "Apple Development"; 300 | CODE_SIGN_STYLE = Automatic; 301 | DEVELOPMENT_TEAM = ""; 302 | INFOPLIST_FILE = ARKitMeshTest/Info.plist; 303 | LD_RUNPATH_SEARCH_PATHS = ( 304 | "$(inherited)", 305 | "@executable_path/Frameworks", 306 | ); 307 | PRODUCT_BUNDLE_IDENTIFIER = com.somekindofexample.ARKitMeshTest; 308 | PRODUCT_NAME = "$(TARGET_NAME)"; 309 | PROVISIONING_PROFILE_SPECIFIER = ""; 310 | SWIFT_VERSION = 5.0; 311 | TARGETED_DEVICE_FAMILY = 2; 312 | }; 313 | name = Debug; 314 | }; 315 | 5BA81916244E372A00459FD3 /* Release */ = { 316 | isa = XCBuildConfiguration; 317 | buildSettings = { 318 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 319 | CODE_SIGN_IDENTITY = "Apple Development"; 320 | CODE_SIGN_STYLE = Automatic; 321 | DEVELOPMENT_TEAM = ""; 322 | INFOPLIST_FILE = ARKitMeshTest/Info.plist; 323 | LD_RUNPATH_SEARCH_PATHS = ( 324 | "$(inherited)", 325 | "@executable_path/Frameworks", 326 | ); 327 | PRODUCT_BUNDLE_IDENTIFIER = com.somekindofexample.ARKitMeshTest; 328 | PRODUCT_NAME = "$(TARGET_NAME)"; 329 | PROVISIONING_PROFILE_SPECIFIER = ""; 330 | SWIFT_VERSION = 5.0; 331 | TARGETED_DEVICE_FAMILY = 2; 332 | }; 333 | name = Release; 334 | }; 335 | /* End XCBuildConfiguration section */ 336 | 337 | /* Begin XCConfigurationList section */ 338 | 5BA818FB244E372700459FD3 /* Build configuration list for PBXProject "ARKitMeshTest" */ = { 339 | isa = XCConfigurationList; 340 | buildConfigurations = ( 341 | 5BA81912244E372A00459FD3 /* Debug */, 342 | 5BA81913244E372A00459FD3 /* Release */, 343 | ); 344 | defaultConfigurationIsVisible = 0; 345 | defaultConfigurationName = Release; 346 | }; 347 | 5BA81914244E372A00459FD3 /* Build configuration list for PBXNativeTarget "ARKitMeshTest" */ = { 348 | isa = XCConfigurationList; 349 | buildConfigurations = ( 350 | 5BA81915244E372A00459FD3 /* Debug */, 351 | 5BA81916244E372A00459FD3 /* Release */, 352 | ); 353 | defaultConfigurationIsVisible = 0; 354 | defaultConfigurationName = Release; 355 | }; 356 | /* End XCConfigurationList section */ 357 | }; 358 | rootObject = 5BA818F8244E372700459FD3 /* Project object */; 359 | } 360 | --------------------------------------------------------------------------------