Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Question AR Face Detection

Discussion in 'AR' started by marsinator, Dec 11, 2022.

  1. marsinator

    marsinator

    Joined:
    Apr 15, 2022
    Posts:
    15
    Hello,
    I am trying to implement an Android Application which allows me to to detect a Face, its landmarks and after i want to manipulate a certain area specified with some of the landmark points.

    I bought DlibFaceLandmarkDetector and OpenCVforUnity in order to do this.

    I am able to detect a Face through the Unity ARFaceManager, when the face is visible i want to use the DlibFaceLandmarkDetector Detect() function to get a list of Rects in which faces are detected but this list is always empty.

    Maybe I am doing something wrong with the SetImage() function because i want to provide the latest phone camera image but do not exactly know how.

    Maybe someone can help me?
    Added is the picture of the codepart where i try to call the described functions.

    this is where i initialize the facelandmarkdetector in the void Start():

    upload_2022-12-11_20-31-15.png
    and this is where i try to detect the rects:
    upload_2022-12-11_20-32-46.png
     

    Attached Files: