Beispiel #1
0
        static Template ConvertTemplate(PatientFingerprintMinutia template, ulong certificateID, ushort fingerOrdinal)
        {
            TemplateBuilder tb = new TemplateBuilder();
            Template        convertedTemplate = new Template(tb);

            return(convertedTemplate);
        }
Beispiel #2
0
        public void LoadTestFingerPrintImages(string imageDirectory)
        {
            DirectoryInfo dirInfo     = new DirectoryInfo(imageDirectory);
            Fingerprint   fingerprint = null;

            if (dirInfo.Exists)
            {
                foreach (DirectoryInfo dir in dirInfo.GetDirectories())
                {
                    foreach (DirectoryInfo dirSub in dir.GetDirectories())
                    {
                        foreach (DirectoryInfo dirSub2 in dirSub.GetDirectories())
                        {
                            foreach (FileInfo file in dirSub2.GetFiles())
                            {
                                fingerprint = new Fingerprint();
                                fingerprint.AsBitmapSource = WpfIO.Load(file.FullName);
                                if (fingerprint.Image != null)
                                {
                                    Afis.ExtractFingerprint(fingerprint);
                                    fingerprintList.Add(fingerprint.GetTemplate());
                                    PatientFingerprintMinutia dbFingerprintMinutia = new PatientFingerprintMinutia(nextID, 1, fingerprint.GetTemplate());
                                    dbFingerprintMinutiaList.Add(dbFingerprintMinutia);
                                    nextID = nextID + 1;
                                }
                            }
                        }
                    }
                }
                _probe = fingerprint;
            }
            SerializeDatabaseProto serialize = new SerializeDatabaseProto();

            serialize.WriteToDisk(DATABASE_PATH + @"finger.hive.0001.biodb", dbFingerprintMinutiaList);
        }