Master Badfar's Recent Forum Activity

  • Thank you totoe for your reply.

    I am trying to make it better and more efficient.

    Good news coming up!

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Hi there!

    You might have wondered yourself that is it possible to detect a face in Construct? You may need this stuff for the registering process of your users or any other thing. You can use Face Detection in the registering process of your users in order to detect FAKE Avatars. The PHP Class that I will introduce is based on one of the simplest algorithms in face detection called "HOG". Remember that you can just detect a face in a picture in which the face has been captured in a straight angle. Also, you can only detect a single face in a picture. You can run this code on the localhost without any problem. This code has a suitable execution time that eliminates your worries. Passing the intro, let's get down to the business.

    First of all, download this zip file which contains the PHP Class and related stuff. Then, add the zip file contents to a specific directory in your host or server. Now you can send a simple request from Construct to the facedetection.php file which is located on your host or server. Send a GET request to the facedetection.php according to the format described below:

    http://yourserver.com/facedetection.php?image=x.jpg

    You should enter the name of the photo that is uploaded on your server in the same directory in which the zip file contents are available. Remember that the photo format should be necessarily jpg. After executing the program, PHP gives you back the photo and the face is defined by a square that has been drawn around the face. You can simply gain the result by Load Image From URL Action. You can set the URL Parameter in this action to the request format described a bit before.

    Some of the photos I've tested myself:

    Hope you have enjoyed this topic. I should apologize because of my bad English. I am not a native speaker and also I am not at the advanced level of English.

    Best wishes,

    Muhammad Mahdi Badfar

    Tagged:

Master Badfar's avatar

Master Badfar

Member since 8 Sep, 2016

Twitter
Master Badfar has 1 followers

Trophy Case

  • 8-Year Club
  • Email Verified

Progress

9/44
How to earn trophies