Well, I currently working on that one too. UareU SDK V3.0.0,
But I have problem with Verify and Compare feature.
However, to answer your question, In case you have a fingerprint image,
You can import image into Fmd
directly. I meant this (I use ISO standard):
Fmd fmd = UareUGlobal.GetEngine().CreateFmd(bInput, 500, 550, 700, 0, 0, Fmd.Format.ISO_19794_2_2005)
Then, you can do compare
or verify
directly with this fmd
.
Note: with, height, resolution must be changed according to your image and reader.
cbeffid
parameter, I have tried 0 and 1.
If any one found the right answer for this parameter, please suggest me as well.
CBEFF
error
API call are invalid
Mostly, I found the resolution, fingerprint format and finger position param is in correct. fingerprint param, I usually set to 0 (first finger or first view)
Update
If you are using javascript
. I would recommend you to convert base64 string from javascript to bufferedImage
first.
public static Fmd importImageString(String image) throws UnsupportedEncodingException, IOException, UareUException {
byte[] bytes = Base64.getDecoder().decode(image.getBytes("UTF-8"));
if (null != bytes && bytes.length > 0) {
ByteArrayInputStream stream = new ByteArrayInputStream(bytes);
BufferedImage buf = ImageIO.read(stream);
if (null != buf) {
return UareUGlobal.GetEngine().CreateFmd(
TestDPuareU.toBytes(buf),
buf.getWidth(),
buf.getHeight(),
500, 0, 1, Fmd.Format.ISO_19794_2_2005
);
}
}
return null;
}
public static byte[] toBytes(BufferedImage image) throws IOException {
WritableRaster raster = image.getRaster();
DataBufferByte data = (DataBufferByte) raster.getDataBuffer();
return (data.getData());
}
The image
I got it from javascript (var finger
) sdk.onSamplesAcquired = function (s)
like below
var samples = JSON.parse(s.samples);
var finger = Fingerprint.b64UrlTo64(samples[0])