NIST Biometric Evaluation Framework
Software components for biometric technology evaluations
be_view_an2kview.h
Go to the documentation of this file.
1/*
2 * This software was developed at the National Institute of Standards and
3 * Technology (NIST) by employees of the Federal Government in the course
4 * of their official duties. Pursuant to title 17 Section 105 of the
5 * United States Code, this software is not subject to copyright protection
6 * and is in the public domain. NIST assumes no responsibility whatsoever for
7 * its use by other parties, and makes no guarantees, expressed or implied,
8 * about its quality, reliability, or any other characteristic.
9 */
10
11#ifndef __BE_VIEW_AN2KVIEW_H__
12#define __BE_VIEW_AN2KVIEW_H__
13
14#include <set>
15#include <string>
16#include <vector>
17
18#include <memory>
19
23#include <be_view_view.h>
24#include <be_image_image.h>
25
26/* an2k.h forward declares */
27struct record;
28typedef record RECORD;
29struct ansi_nist;
30typedef ansi_nist ANSI_NIST;
31
32namespace BiometricEvaluation
33{
34 namespace View
35 {
52 public:
54 enum class RecordType : uint16_t
55 {
56 Type_1 = 1,
57 Type_2 = 2,
58 Type_3 = 3,
59 Type_4 = 4,
60 Type_5 = 5,
61 Type_6 = 6,
62 Type_7 = 7,
63 Type_8 = 8,
64 Type_9 = 9,
65 Type_10 = 10,
66 Type_11 = 11,
67 Type_12 = 12,
68 Type_13 = 13,
69 Type_14 = 14,
70 Type_15 = 15,
71 Type_16 = 16,
72 Type_17 = 17,
73 Type_99 = 99
74 };
75
82 {
87 Controlled,
93 Assisted,
99 Observed,
104 Unattended,
106 Unknown,
108 NA
109 };
110
128 const char *dmm);
129
151 const uint16_t recordType,
152 const unsigned char *an2kValue);
153
159 static const double MinimumScanResolutionPPMM;
160 static const double HalfMinimumScanResolutionPPMM;
161
166 static const int FixedResolutionBitDepth = 8;
167
176 const std::string filename,
177 const RecordType typeID,
178 const uint32_t recordNumber);
179
189 const RecordType typeID,
190 const uint32_t recordNumber);
191
193
204 std::vector<Finger::AN2KMinutiaeDataRecord>
206
214
215 protected:
216
223 const;
224
233 RECORD*
235 const;
236
237 private:
238
257 void readImageCommon(
258 const ANSI_NIST *an2k,
259 const RecordType typeID,
260 const uint32_t recordNumber);
261
270 void
271 associateMinutiaeData(
272 Memory::uint8Array &buf);
273
282 void
283 associateMinutiaeData(
284 const std::string &filename);
285
294 void
295 addMinutiaeDataRecord(
297
298 /* The record that this object represents. The Nth
299 * record is searched for when the object is
300 * constructed and may be referenced by subclasses.
301 */
303 RECORD *_an2kRecord;
304 RecordType _recordType;
305 int _idc;
306
311 std::vector<Finger::AN2KMinutiaeDataRecord>
312 _minutiaeDataRecordSet;
313 };
314
319 std::ostream&
321 std::ostream &stream,
323 }
324}
325
328 BE_View_AN2KView_RecordType_EnumToStringMap);
329
332 BE_View_AN2KView_DeviceMonitoringMode_EnumToStringMap);
333
334#endif /* __BE_VIEW_AN2KVIEW_H__ */
335
ansi_nist ANSI_NIST
BE_FRAMEWORK_ENUMERATION_DECLARATIONS(BiometricEvaluation::View::AN2KView::RecordType, BE_View_AN2KView_RecordType_EnumToStringMap)
record RECORD
Representation of a Type-9 Record from an AN2K file.
A class to represent single biometric view and derived information.
RecordType getRecordType() const
Obtain the ANSI-NIST record type.
AN2KView(const std::string filename, const RecordType typeID, const uint32_t recordNumber)
Construct an AN2K view from a file.
RECORD * getAN2KRecord() const
Obtain a pointer to the single ANSI/NIST record.
DeviceMonitoringMode
The level of human monitoring for the image capture device.
std::vector< Finger::AN2KMinutiaeDataRecord > getMinutiaeDataRecordSet() const
Obtain the set of minutiae records.
static const double HalfMinimumScanResolutionPPMM
static const double MinimumScanResolutionPPMM
Constants to define the minimum resolution used for fingerprint images in an AN2k record.
static Image::CompressionAlgorithm convertCompressionAlgorithm(const uint16_t recordType, const unsigned char *an2kValue)
Convert a compression algorithm indicator from an AN2K finger image record.
static DeviceMonitoringMode convertDeviceMonitoringMode(const char *dmm)
Convert a device monitoring mode indicator from an AN2K record.
static const int FixedResolutionBitDepth
The defined bit-depth for fixed-resolution images.
RecordType
The type of AN2K record.
AN2KView(Memory::uint8Array &buf, const RecordType typeID, const uint32_t recordNumber)
Construct an AN2K view from a buffer.
Memory::AutoBuffer< ANSI_NIST > getAN2K() const
Obtain the complete ANSI/NIST record set.
A class to represent single biometric element view.
Definition: be_view_view.h:31
CompressionAlgorithm
Image compression algorithms.
Definition: be_image.h:35
std::ostream & operator<<(std::ostream &stream, const AN2KView::DeviceMonitoringMode &kind)
Output stream overload for DeviceMonitoringMode.
This software was developed at the National Institute of Standards and Technology (NIST) by employees...