0 Replies
      Latest reply on Dec 1, 2019 6:28 AM by DelhiTechnologyClub
      DelhiTechnologyClub Level 1 Level 1 (0 points)

        hi,

         

        Following Function is getting called when an objected detected by Arkit:

        func renderer(_ renderer: SCNSceneRenderer, didAdd node: SCNNode, for anchor: ARAnchor)

         

            {

                if let objectAnchor = anchor as? ARObjectAnchor {

                    print("added");

                }

            }

         

        I want a trigger which tells me that object is removed from the screen. I tried following function

        func renderer(_ renderer: SCNSceneRenderer, didRemove node: SCNNode, for anchor: ARAnchor)

         

            {

                if let objectAnchor = anchor as? ARObjectAnchor {

                    print("removed");

                }

            }

         

        Is there any other way to do that?