-
Notifications
You must be signed in to change notification settings - Fork 8
/
FingerPrintUtility.cs
34 lines (30 loc) · 1.1 KB
/
FingerPrintUtility.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
using DPFP;
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Text;
namespace MyAttendance
{
class FingerPrintUtility
{
public static FeatureSet ExtractFeatures(Sample Sample, DPFP.Processing.DataPurpose Purpose)
{
DPFP.Processing.FeatureExtraction Extractor = new DPFP.Processing.FeatureExtraction();
DPFP.Capture.CaptureFeedback feedback = DPFP.Capture.CaptureFeedback.None;
FeatureSet features = new DPFP.FeatureSet();
Extractor.CreateFeatureSet(Sample, Purpose, ref feedback, ref features);
if (feedback == DPFP.Capture.CaptureFeedback.Good)
return features;
else
return null;
}
public static Bitmap ConvertSampleToBitmap(DPFP.Sample Sample)
{
DPFP.Capture.SampleConversion Convertor = new DPFP.Capture.SampleConversion();
Bitmap bitmap = null;
Convertor.ConvertToPicture(Sample, ref bitmap);
return bitmap;
}
}
}