Search code examples
androidapiandroid-cameraface-detection

Human body part detection in Android


Currently I am working on Google face detection API from this API I am able to detect human complete face (eye, nose and other parts) and also as per this concept I have developed one application, if you stand in front of the front face camera then it will detect your face and show some gestures.

Context context = Applications.getAppContext();

FaceDetector detector = new FaceDetector.Builder(context)
            .setClassificationType(FaceDetector.ALL_CLASSIFICATIONS)
            .build();

detector.setProcessor(
         new MultiProcessor.Builder<>(new GraphicFaceTrackerFactory())
         .build());

if (!detector.isOperational()) {

}

mCameraSource = new CameraSource.Builder(context, detector)
            .setRequestedPreviewSize(640, 480)
            .setFacing(CameraSource.CAMERA_FACING_FRONT)
            .setRequestedFps(30.0f)
            .build();

Application video link which i have developed till now :-

https://www.dropbox.com/s/097todfu90ic12j/VirtualMirror.mp4?dl=0

Application play store link:-

https://play.google.com/store/apps/details?id=com.twins.virtualmirror

Is there any API available where we can recognize human other body parts (Chest, hand, legs and other parts of the body), because as per the Google vision API it's only able to detect face of the human not other parts.


Solution

  • Update 2021

    You can train a Convolutional Neural Network to detect any body part. I recommend you to learn machine learning from scratch But if you don't have time. you can use google auto ml.

    Old Answer

    Currently there is no API for detecting other body parts. If you wants to detect other body parts you have to code , It wont be easy but not Impossible