Interface ARSKViewDelegate

    • Method Detail

      • viewDidAddNodeForAnchor

        default void viewDidAddNodeForAnchor​(@NotNull
                                             @NotNull ARSKView view,
                                             @NotNull
                                             @NotNull SKNode node,
                                             @NotNull
                                             @NotNull ARAnchor anchor)
        Called when a new node has been mapped to the given anchor.
        Parameters:
        view - The view that will render the scene.
        node - The node that maps to the anchor.
        anchor - The added anchor.
      • viewDidRemoveNodeForAnchor

        default void viewDidRemoveNodeForAnchor​(@NotNull
                                                @NotNull ARSKView view,
                                                @NotNull
                                                @NotNull SKNode node,
                                                @NotNull
                                                @NotNull ARAnchor anchor)
        Called when a mapped node has been removed from the scene graph for the given anchor.
        Parameters:
        view - The view that will render the scene.
        node - The node that was removed.
        anchor - The anchor that was removed.
      • viewDidUpdateNodeForAnchor

        default void viewDidUpdateNodeForAnchor​(@NotNull
                                                @NotNull ARSKView view,
                                                @NotNull
                                                @NotNull SKNode node,
                                                @NotNull
                                                @NotNull ARAnchor anchor)
        Called when a node has been updated with data from the given anchor.
        Parameters:
        view - The view that will render the scene.
        node - The node that was updated.
        anchor - The anchor that was updated.
      • viewNodeForAnchor

        @Nullable
        default @Nullable SKNode viewNodeForAnchor​(@NotNull
                                                   @NotNull ARSKView view,
                                                   @NotNull
                                                   @NotNull ARAnchor anchor)
        Implement this to provide a custom node for the given anchor. This node will automatically be added to the scene graph. If this method is not implemented, a node will be automatically created. If nil is returned the anchor will be ignored.
        Parameters:
        view - The view that will render the scene.
        anchor - The added anchor.
        Returns:
        Node that will be mapped to the anchor or nil.
      • viewWillUpdateNodeForAnchor

        default void viewWillUpdateNodeForAnchor​(@NotNull
                                                 @NotNull ARSKView view,
                                                 @NotNull
                                                 @NotNull SKNode node,
                                                 @NotNull
                                                 @NotNull ARAnchor anchor)
        Called when a node will be updated with data from the given anchor.
        Parameters:
        view - The view that will render the scene.
        node - The node that will be updated.
        anchor - The anchor that was updated.