I'm trying to bind the position of a node - in this case, my pointOfView node - to a text field on macOS (but I guess it would be the same on iOS)
I can bind (via .bind
or Storyboard) e.g. scnView.pointOfView.camera.fieldOfView
. But I can't bind scnView.pointOfView.position.x
I can, however, bind scnView.pointOfView.position
. But that doesn't seem useful for the text field.
Details
Here's what I get with
field.bind(.value, to: self, withKeyPath: "scnView.pointOfView.position.x", options: nil)
2019-01-11 11:54:13.987696+0100 Scenekit Test Template[45791:1781975] Failed to set (contentViewController) user defined inspected property on (NSWindow): [ valueForUndefinedKey:]: this class is not key value coding-compliant for the key x.
And here's binding just the .position