How to load DAE files in runtime from http or https and show it in ARKit

I want to downlaod the dae or 3D Models assets in runtime and show them in ARKit. I tried doing it by following this link by couldnot succeed and the blog was written 3 years ago. Any other method or example to do it. I cannot find any proper documentation on Apple website for doing this

Replies

There is no DAE support on iOS at this time. As a result, consider the following alternatives:


(1) pre-convert the DAE to .scn, which is SceneKit's preferred input format. This can be done using the graphical SceneKit editor in Xcode, or using the `scntool` command line converter. Be aware that you may use scntool, but there currently is no documentation on it.


(2) output from your 3D modeling tool, a format that is supported on iOS; Pixar .usd is one, and it supports most of the features of DAE, though you should be aware that not all of the USD configurations are supported by SceneKit at this time


(3) write your own DAE import code that decodes the file and passes it to SceneKit via the custom SCNGeometry initializers (among other configuration, such as SCNLight, and SCNAnimation)


As you can see, though it requires a non-ideal preprocessing phase, #1 is probably the best option in all cases.

Using XCode 10, Any converted DAE file to SCN file I get


Command CodeSign failed with a nonzero exit code


Please Help

This is because you've failed to pass the SCN file correctly in a past build. Since Xcode saves derived data from past builds to quickly build new releases: you have to delete the derived data before you start by cleaning your build.


pod install --repo-update
, then in your xCode clean build folder and delete derived data, try build again after that.


Also, your dae may have had a path to a texture that it no longer has in scenekit.


also, look at your optional swift codes. If you have anything acting on the DAE file that's optional then it will return a NULL which in Swift an optional that returns a NULL generates the error that you're seeing.


Hope all that helped.