arkit

Projecting the ARKit face tracking 3D mesh to 2D image coordinates

时光怂恿深爱的人放手 提交于 2020-07-15 08:42:26
问题 I am collecting face mesh 3D vertices using ARKit. I have read: Mapping image onto 3D face mesh and Tracking and Visualizing Faces. I have the following struct: struct CaptureData { var vertices: [SIMD3<Float>] var verticesformatted: String { let verticesDescribed = vertices.map({ "\($0.x):\($0.y):\($0.z)" }).joined(separator: "~") return "<\(verticesDescribed)>" } } I have a Strat button to capture vertices: @IBAction private func startPressed() { captureData = [] // Clear data

Projecting the ARKit face tracking 3D mesh to 2D image coordinates

我与影子孤独终老i 提交于 2020-07-15 08:42:26
问题 I am collecting face mesh 3D vertices using ARKit. I have read: Mapping image onto 3D face mesh and Tracking and Visualizing Faces. I have the following struct: struct CaptureData { var vertices: [SIMD3<Float>] var verticesformatted: String { let verticesDescribed = vertices.map({ "\($0.x):\($0.y):\($0.z)" }).joined(separator: "~") return "<\(verticesDescribed)>" } } I have a Strat button to capture vertices: @IBAction private func startPressed() { captureData = [] // Clear data

MTLTexture.getbytes() returning EXC_BAD_ACCESS - Possible reasons?

安稳与你 提交于 2020-07-10 06:48:07
问题 I am using ARKit3 body tracking capabilities to overlay a 3D model on top of the camera feed and allow the user to capture the feed as an MP4 with audio. I have been able to draw to the camera preview to the MTLView successfully. However, am receiving a EXC_BAD_ACCESS error which I cannot seem to debug when trying to write to my asset writer. My App has render class which is responsible for rendering the Metal textures from the feed, and a MetalVideoRecorder class which is used to write the

MTLTexture.getbytes() returning EXC_BAD_ACCESS - Possible reasons?

风格不统一 提交于 2020-07-10 06:46:06
问题 I am using ARKit3 body tracking capabilities to overlay a 3D model on top of the camera feed and allow the user to capture the feed as an MP4 with audio. I have been able to draw to the camera preview to the MTLView successfully. However, am receiving a EXC_BAD_ACCESS error which I cannot seem to debug when trying to write to my asset writer. My App has render class which is responsible for rendering the Metal textures from the feed, and a MetalVideoRecorder class which is used to write the

SCNNode is not appearing in correct position

别来无恙 提交于 2020-07-10 05:59:08
问题 I downloaded the wall2.obj file from Google Blocks and then I used Blender to change the extension to .dae the wall node is not appearing where it should be. Where the wall node placed vs. where it should be placed: 回答1: It's a model's pivot point issue In Blender change a pivot point 's position to the desired one – move pivot point to the center of your model, and then at its bottom. If your model consists of several independent parts, group all parts and use just one composite pivot point.

SCNNode is not appearing in correct position

我是研究僧i 提交于 2020-07-10 05:58:21
问题 I downloaded the wall2.obj file from Google Blocks and then I used Blender to change the extension to .dae the wall node is not appearing where it should be. Where the wall node placed vs. where it should be placed: 回答1: It's a model's pivot point issue In Blender change a pivot point 's position to the desired one – move pivot point to the center of your model, and then at its bottom. If your model consists of several independent parts, group all parts and use just one composite pivot point.

Extract Reality Composer scene for ARQuickLook

↘锁芯ラ 提交于 2020-07-08 20:43:26
问题 I have a Reality Composer scene and I want to extract it as usdz file or any files that can be used in ARQuickLook ? is it possible? 回答1: From Apple's Creating 3D Content with Reality Composer document: You can also save your composition to a .reality file for use as a lightweight AR Quick Look experience in your app or on the web. This allows users to place and preview content in the real world to get a quick sense of what it’s like. To create a Reality file, choose File > Export > Export

HitTest prints AR Entity name even when I am not tapping on it

一笑奈何 提交于 2020-07-06 20:21:45
问题 My Experience.rcproject has animations that can be triggered by tap action. Two cylinders are named “Button 1” and “Button 2” and have Collide turned on. I am using Async method to load Experience.Map scene and addAnchor method to add mapAnchor to ARView in a ViewController. I tried to run HitTest on the scene to see if the app reacts properly. Nonetheless, the HitTest result prints the entity name of a button even when I am not tapping on it but area near it. class augmentedReality:

HitTest prints AR Entity name even when I am not tapping on it

我与影子孤独终老i 提交于 2020-07-06 20:21:24
问题 My Experience.rcproject has animations that can be triggered by tap action. Two cylinders are named “Button 1” and “Button 2” and have Collide turned on. I am using Async method to load Experience.Map scene and addAnchor method to add mapAnchor to ARView in a ViewController. I tried to run HitTest on the scene to see if the app reacts properly. Nonetheless, the HitTest result prints the entity name of a button even when I am not tapping on it but area near it. class augmentedReality:

Is there any way to load FBX file using ARKit?

孤街浪徒 提交于 2020-07-05 10:47:11
问题 In my project I am projecting 3d files using ARKit. I am able to project Dae and Obj format models. Is there anyway I could load fbx files? 回答1: ARKit itself isn't loading models in 3D scene. It's a work for a SceneKit framework. SceneKit doesn't directly support .fbx now. You could implement a reading of .fbx file format via ModelIO but it's non-trivial thing. The best way to prepare your model for working in ARKit, SceneKit and RealityKit is to convert it into usdz file format via new