Interface DeepARCallbacks

Callbacks from DeepAR notifying events. Register callbacks with callbacks.

Hierarchy

  • DeepARCallbacks

Properties

onFaceVisibilityChanged?: ((visible) => void)

Type declaration

    • (visible): void
    • Called whenever the face enters or exits the camera field of view.
      NOTE: This callback is only called when the SDK does face tracking. For example, you laded some effect that uses face tracking (most of them do). But if no effect is loaded this callback will not get called because the SDK is not performing face tracking.

      Parameters

      • visible: boolean

        True if the face is visible on the camera, false otherwise.

      Returns void

onFaceTracked?: ((faceDataArray) => void)

Type declaration

    • (faceDataArray): void
    • Passes the information about the detected faces. If this callback is set, it will get called every frame. NOTE: This callback is only called when the SDK does face tracking. For example, you laded some effect that uses face tracking (most of them do). But if no effect is loaded this callback will not get called because the SDK is not performing face tracking.

      Parameters

      • faceDataArray: FaceData[]

        Information about all the tracked faces.

      Returns void

onFeetTracked?: ((leftFootData, rightFootData) => void)

Type declaration

    • (leftFootData, rightFootData): void
    • Passes the information about the detected feet. If this callback is set, it will get called every frame. NOTE: This callback is only called when the SDK does foot tracking. For example, you laded some effect that uses foot tracking (shoe-try-on effects). But if no effect is loaded this callback will not get called because the SDK is not performing foot tracking.

      Parameters

      • leftFootData: FootData

        Information about the left foot.

      • rightFootData: FootData

        Information about the right foot.

      Returns void

onWristTracked?: ((wristData) => void)

Type declaration

    • (wristData): void
    • Passes the information about the detected wrist. If this callback is set, it will get called every frame. NOTE: This callback is only called when the SDK does wrist tracking. For example, you laded some effect that uses wrist tracking (watch-try-on effects). But if no effect is loaded this callback will not get called because the SDK is not performing wrist tracking.

      Parameters

      • wristData: WristData

        Information about the wrist.

      Returns void

onFootTrackingInitialized?: (() => void)

Type declaration

    • (): void
    • Called when foot tracking is fully initialized. Be sure to check isFootTrackingInitialized before setting this callback. Because this callback is called only once. So if you set this callback after the foot tracking is initialized, it will not be called again.

      Returns void

onSegmentationInitialized?: (() => void)

Type declaration

    • (): void
    • Called when segmentation is fully initialized. Be sure to check isSegmentationInitialized before setting this callback. Because this callback is called only once. So if you set this callback after the segmentation is initialized, it will not be called again.

      Returns void

onWristTrackingInitialized?: (() => void)

Type declaration

    • (): void
    • Called when wrist tracking is fully initialized. Be sure to check isWristTrackingInitialized before setting this callback. Because this callback is called only once. So if you set this callback after the wrist tracking is initialized, it will not be called again.

      Returns void

onAnimationTransitionedToState?: ((newState) => void)

Type declaration

    • (newState): void
    • Called when the animation player transitions to a new state.

      Parameters

      • newState: string

        Name of the new state that is being transitioned to.

      Returns void

__deeparRendered2?: ((canvas) => void)

Type declaration

    • (canvas): void
    • Parameters

      • canvas: HTMLCanvasElement

      Returns void

Generated using TypeDoc