How do I retrieve the units (e.g., centimeters, meters) for a USDZ or DAE model file in SceneKit?
I've tried to use SCNSceneSourceAssetUnitKey as follows, but I never get any values returned.
RealityConverter seems to show the units for USDZ files before export and when I look at a DAE file XML it seems to have the correct metadata, but I've not found any way to retrieve it. Is it broken or is there another method (e.g., Model I/O)?
if let modelSource = SCNSceneSource(url: url, options: options) {
NSLog(" units = \(String(describing: modelSource.property(forKey: SCNSceneSourceAssetUnitKey)))")
0
0
1.1k