Пример #1
0
        public static int MC_DetectFaces4Image(byte[] bgr24, int width, int height, int widthstep, out FaceModel[] faceModel, int MaxCount)
        {
            int result;

            try
            {
                object obj = FaceCompare._obj;
                lock (obj)
                {
                    FaceModelV3[] array    = new FaceModelV3[20];
                    int           arg_32_0 = FaceCompare._FacesDetect(FaceCompare.FaceEngne, bgr24, width, height, widthstep, array, 20);
                    faceModel = FaceUnit.FaceModelV3ToFaceModel(array);
                    result    = arg_32_0;
                }
            }
            catch (Exception arg_3F_0)
            {
                throw arg_3F_0;
            }
            return(result);
        }
Пример #2
0
        public static int MC_DetectFaces4Image(Image <Bgr, byte> image, out FaceModel[] faceModel)
        {
            int result;

            try
            {
                object obj = FaceCompare._obj;
                lock (obj)
                {
                    FaceModelV3[] array    = new FaceModelV3[20];
                    int           arg_4A_0 = FaceCompare._FacesDetect(FaceCompare.FaceEngne, image.Bytes, image.Width, image.Height, image.MIplImage.WidthStep, array, 20);
                    faceModel = FaceUnit.FaceModelV3ToFaceModel(array);
                    result    = arg_4A_0;
                }
            }
            catch (Exception arg_57_0)
            {
                throw arg_57_0;
            }
            return(result);
        }