Package org.jmrtd.lds.iso19794
Class IrisInfo
- java.lang.Object
-
- org.jmrtd.lds.AbstractLDSInfo
-
- org.jmrtd.lds.AbstractListInfo<IrisBiometricSubtypeInfo>
-
- org.jmrtd.lds.iso19794.IrisInfo
-
- All Implemented Interfaces:
Serializable
,BiometricDataBlock
,LDSElement
public class IrisInfo extends AbstractListInfo<IrisBiometricSubtypeInfo> implements BiometricDataBlock
Iris record header and biometric subtype blocks based on Section 6.5.3 and Table 2 of ISO/IEC 19794-6 2005. TODO: proper enums for fields.- Version:
- $Revision: 1799 $
- Author:
- The JMRTD team ([email protected])
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static int
CAPTURE_DEVICE_UNDEF
Constant for capture device Id, based on Table 2 in Section 5.5 in ISO 19794-6.static int
IMAGEFORMAT_MONO_JPEG
Image format.static int
IMAGEFORMAT_MONO_JPEG_LS
Image format.static int
IMAGEFORMAT_MONO_JPEG2000
Image format.static int
IMAGEFORMAT_MONO_RAW
Image format.static int
IMAGEFORMAT_RGB_JPEG
Image format.static int
IMAGEFORMAT_RGB_JPEG_LS
Image format.static int
IMAGEFORMAT_RGB_JPEG2000
Image format.static int
IMAGEFORMAT_RGB_RAW
Image format.static int
INTENSITY_DEPTH_UNDEF
static int
IRBNDY_PROCESSED
static int
IRBNDY_UNDEF
static int
IROC_UNITFILL
Iris occlusion filling (polar only), based on Table 2 in Section 5.5 in ISO 19794-6.static int
IROCC_PROCESSED
Iris occlusion (polar only), based on Table 2 in Section 5.5 in ISO 19794-6.static int
IROCC_UNDEF
Iris occlusion (polar only), based on Table 2 in Section 5.5 in ISO 19794-6.static int
IROCC_ZEROFILL
Iris occlusion filling (polar only), based on Table 2 in Section 5.5 in ISO 19794-6.static int
ORIENTATION_BASE
Constant for horizontal and veritical orientation, based on Table 2 in Section 5.5 in ISO 19794-6.static int
ORIENTATION_FLIPPED
Constant for horizontal and veritical orientation, based on Table 2 in Section 5.5 in ISO 19794-6.static int
ORIENTATION_UNDEF
Constant for horizontal and veritical orientation, based on Table 2 in Section 5.5 in ISO 19794-6.static int
SCAN_TYPE_CORRECTED
Scan type (rectilinear only), based on Table 2 in Section 5.5 in ISO 19794-6.static int
SCAN_TYPE_INTERLACE_FIELD
Scan type (rectilinear only), based on Table 2 in Section 5.5 in ISO 19794-6.static int
SCAN_TYPE_INTERLACE_FRAME
Scan type (rectilinear only), based on Table 2 in Section 5.5 in ISO 19794-6.static int
SCAN_TYPE_PROGRESSIVE
Scan type (rectilinear only), based on Table 2 in Section 5.5 in ISO 19794-6.static int
SCAN_TYPE_UNDEF
Scan type (rectilinear only), based on Table 2 in Section 5.5 in ISO 19794-6.static int
TRANS_STD
static int
TRANS_UNDEF
-
Constructor Summary
Constructors Constructor Description IrisInfo(int captureDeviceId, int horizontalOrientation, int verticalOrientation, int scanType, int irisOcclusion, int occlusionFilling, int boundaryExtraction, int irisDiameter, int imageFormat, int rawImageWidth, int rawImageHeight, int intensityDepth, int imageTransformation, byte[] deviceUniqueId, List<IrisBiometricSubtypeInfo> irisBiometricSubtypeInfos)
Constructs a new iris info object.IrisInfo(InputStream inputStream)
Constructs an iris info from binary encoding.IrisInfo(StandardBiometricHeader sbh, int captureDeviceId, int horizontalOrientation, int verticalOrientation, int scanType, int irisOcclusion, int occlusionFilling, int boundaryExtraction, int irisDiameter, int imageFormat, int rawImageWidth, int rawImageHeight, int intensityDepth, int imageTransformation, byte[] deviceUniqueId, List<IrisBiometricSubtypeInfo> irisBiometricSubtypeInfos)
Constructs a new iris info object.IrisInfo(StandardBiometricHeader sbh, InputStream inputStream)
Constructs an iris info from binary encoding.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addIrisBiometricSubtypeInfo(IrisBiometricSubtypeInfo irisBiometricSubtypeInfo)
Adds an iris biometric subtype info to this iris info.boolean
equals(Object obj)
int
getBoundaryExtraction()
Returns the boundary extraction.int
getCaptureDeviceId()
Returns the capture device identifier.byte[]
getDeviceUniqueId()
Returns the device unique id.int
getHorizontalOrientation()
Returns the horizontal orientation.int
getImageFormat()
Returns the image format.int
getImageTransformation()
Returns the image transformation.int
getIntensityDepth()
Returns the intensity depth.List<IrisBiometricSubtypeInfo>
getIrisBiometricSubtypeInfos()
Returns the iris biometric subtype infos embedded in this iris info.int
getIrisDiameter()
Returns the iris diameter.int
getIrisOcclusion()
Returns the iris occlusion.int
getOcclusionFilling()
Returns the iris occlusing filling.int
getRawImageHeight()
Returns the raw image height.int
getRawImageWidth()
Returns the raw image width.int
getScanType()
Returns the scan type.StandardBiometricHeader
getStandardBiometricHeader()
Returns the standard biometric header of this iris info.int
getVerticalOrientation()
Returns the vertical orientation.int
hashCode()
void
readObject(InputStream inputStream)
Reads this iris info from input stream.void
removeIrisBiometricSubtypeInfo(int index)
Removes an iris biometric subtype info from this iris info.String
toString()
Generates a textual representation of this object.void
writeObject(OutputStream outputStream)
Writes this iris info to an output stream.-
Methods inherited from class org.jmrtd.lds.AbstractLDSInfo
getEncoded
-
Methods inherited from class org.jmrtd.lds.AbstractListInfo
add, addAll, getSubRecords, remove
-
-
-
-
Field Detail
-
IMAGEFORMAT_MONO_RAW
public static final int IMAGEFORMAT_MONO_RAW
Image format.- See Also:
- Constant Field Values
-
IMAGEFORMAT_RGB_RAW
public static final int IMAGEFORMAT_RGB_RAW
Image format.- See Also:
- Constant Field Values
-
IMAGEFORMAT_MONO_JPEG
public static final int IMAGEFORMAT_MONO_JPEG
Image format.- See Also:
- Constant Field Values
-
IMAGEFORMAT_RGB_JPEG
public static final int IMAGEFORMAT_RGB_JPEG
Image format.- See Also:
- Constant Field Values
-
IMAGEFORMAT_MONO_JPEG_LS
public static final int IMAGEFORMAT_MONO_JPEG_LS
Image format.- See Also:
- Constant Field Values
-
IMAGEFORMAT_RGB_JPEG_LS
public static final int IMAGEFORMAT_RGB_JPEG_LS
Image format.- See Also:
- Constant Field Values
-
IMAGEFORMAT_MONO_JPEG2000
public static final int IMAGEFORMAT_MONO_JPEG2000
Image format.- See Also:
- Constant Field Values
-
IMAGEFORMAT_RGB_JPEG2000
public static final int IMAGEFORMAT_RGB_JPEG2000
Image format.- See Also:
- Constant Field Values
-
CAPTURE_DEVICE_UNDEF
public static final int CAPTURE_DEVICE_UNDEF
Constant for capture device Id, based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
ORIENTATION_UNDEF
public static final int ORIENTATION_UNDEF
Constant for horizontal and veritical orientation, based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
ORIENTATION_BASE
public static final int ORIENTATION_BASE
Constant for horizontal and veritical orientation, based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
ORIENTATION_FLIPPED
public static final int ORIENTATION_FLIPPED
Constant for horizontal and veritical orientation, based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
SCAN_TYPE_UNDEF
public static final int SCAN_TYPE_UNDEF
Scan type (rectilinear only), based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
SCAN_TYPE_PROGRESSIVE
public static final int SCAN_TYPE_PROGRESSIVE
Scan type (rectilinear only), based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
SCAN_TYPE_INTERLACE_FRAME
public static final int SCAN_TYPE_INTERLACE_FRAME
Scan type (rectilinear only), based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
SCAN_TYPE_INTERLACE_FIELD
public static final int SCAN_TYPE_INTERLACE_FIELD
Scan type (rectilinear only), based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
SCAN_TYPE_CORRECTED
public static final int SCAN_TYPE_CORRECTED
Scan type (rectilinear only), based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
IROCC_UNDEF
public static final int IROCC_UNDEF
Iris occlusion (polar only), based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
IROCC_PROCESSED
public static final int IROCC_PROCESSED
Iris occlusion (polar only), based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
IROCC_ZEROFILL
public static final int IROCC_ZEROFILL
Iris occlusion filling (polar only), based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
IROC_UNITFILL
public static final int IROC_UNITFILL
Iris occlusion filling (polar only), based on Table 2 in Section 5.5 in ISO 19794-6.- See Also:
- Constant Field Values
-
INTENSITY_DEPTH_UNDEF
public static final int INTENSITY_DEPTH_UNDEF
- See Also:
- Constant Field Values
-
TRANS_UNDEF
public static final int TRANS_UNDEF
- See Also:
- Constant Field Values
-
TRANS_STD
public static final int TRANS_STD
- See Also:
- Constant Field Values
-
IRBNDY_UNDEF
public static final int IRBNDY_UNDEF
- See Also:
- Constant Field Values
-
IRBNDY_PROCESSED
public static final int IRBNDY_PROCESSED
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
IrisInfo
public IrisInfo(int captureDeviceId, int horizontalOrientation, int verticalOrientation, int scanType, int irisOcclusion, int occlusionFilling, int boundaryExtraction, int irisDiameter, int imageFormat, int rawImageWidth, int rawImageHeight, int intensityDepth, int imageTransformation, byte[] deviceUniqueId, List<IrisBiometricSubtypeInfo> irisBiometricSubtypeInfos)
Constructs a new iris info object.- Parameters:
captureDeviceId
- capture device identifier assigned by vendorhorizontalOrientation
- horizontal orientation:ORIENTATION_UNDEF
,ORIENTATION_BASE
, orORIENTATION_FLIPPED
verticalOrientation
- vertical orientation:ORIENTATION_UNDEF
,ORIENTATION_BASE
, orORIENTATION_FLIPPED
scanType
- scan typeirisOcclusion
- iris occlusion (polar only)occlusionFilling
- occlusion filling (polar only)boundaryExtraction
- boundary extraction (polar only)irisDiameter
- expected iris diameter in pixels (rectilinear only)imageFormat
- image format of data blob (JPEG, raw, etc.)rawImageWidth
- raw image width, pixelsrawImageHeight
- raw image height, pixelsintensityDepth
- intensity depth, bits, per colorimageTransformation
- transformation to polar image (polar only)deviceUniqueId
- a 16 character string uniquely identifying the device or source of that datairisBiometricSubtypeInfos
- the iris biometric subtype records
-
IrisInfo
public IrisInfo(StandardBiometricHeader sbh, int captureDeviceId, int horizontalOrientation, int verticalOrientation, int scanType, int irisOcclusion, int occlusionFilling, int boundaryExtraction, int irisDiameter, int imageFormat, int rawImageWidth, int rawImageHeight, int intensityDepth, int imageTransformation, byte[] deviceUniqueId, List<IrisBiometricSubtypeInfo> irisBiometricSubtypeInfos)
Constructs a new iris info object.- Parameters:
sbh
- standard biometric header to usecaptureDeviceId
- capture device identifier assigned by vendorhorizontalOrientation
- horizontal orientation:ORIENTATION_UNDEF
,ORIENTATION_BASE
, orORIENTATION_FLIPPED
verticalOrientation
- vertical orientation:ORIENTATION_UNDEF
,ORIENTATION_BASE
, orORIENTATION_FLIPPED
scanType
- scan typeirisOcclusion
- iris occlusion (polar only)occlusionFilling
- occlusion filling (polar only)boundaryExtraction
- boundary extraction (polar only)irisDiameter
- expected iris diameter in pixels (rectilinear only)imageFormat
- image format of data blob (JPEG, raw, etc.)rawImageWidth
- raw image width, pixelsrawImageHeight
- raw image height, pixelsintensityDepth
- intensity depth, bits, per colorimageTransformation
- transformation to polar image (polar only)deviceUniqueId
- a 16 character string uniquely identifying the device or source of that datairisBiometricSubtypeInfos
- the iris biometric subtype records
-
IrisInfo
public IrisInfo(InputStream inputStream) throws IOException
Constructs an iris info from binary encoding.- Parameters:
inputStream
- an input stream- Throws:
IOException
- if reading fails
-
IrisInfo
public IrisInfo(StandardBiometricHeader sbh, InputStream inputStream) throws IOException
Constructs an iris info from binary encoding.- Parameters:
sbh
- standard biometric header to useinputStream
- an input stream- Throws:
IOException
- if reading fails
-
-
Method Detail
-
readObject
public void readObject(InputStream inputStream) throws IOException
Reads this iris info from input stream.- Specified by:
readObject
in classAbstractListInfo<IrisBiometricSubtypeInfo>
- Parameters:
inputStream
- an input stream- Throws:
IOException
- if reading fails
-
writeObject
public void writeObject(OutputStream outputStream) throws IOException
Writes this iris info to an output stream.- Specified by:
writeObject
in classAbstractListInfo<IrisBiometricSubtypeInfo>
- Parameters:
outputStream
- an output stream- Throws:
IOException
- if writing fails
-
getCaptureDeviceId
public int getCaptureDeviceId()
Returns the capture device identifier.- Returns:
- the capture device identifier
-
getHorizontalOrientation
public int getHorizontalOrientation()
Returns the horizontal orientation.- Returns:
- the horizontalOrientation, one of
ORIENTATION_UNDEF
,ORIENTATION_BASE
, orORIENTATION_FLIPPED
-
getVerticalOrientation
public int getVerticalOrientation()
Returns the vertical orientation.- Returns:
- the verticalOrientation, one of
ORIENTATION_UNDEF
,ORIENTATION_BASE
, orORIENTATION_FLIPPED
-
getScanType
public int getScanType()
Returns the scan type. One ofSCAN_TYPE_UNDEF
,SCAN_TYPE_PROGRESSIVE
,SCAN_TYPE_INTERLACE_FRAME
,SCAN_TYPE_INTERLACE_FIELD
, orSCAN_TYPE_CORRECTED
.- Returns:
- the scanType
-
getIrisOcclusion
public int getIrisOcclusion()
Returns the iris occlusion.- Returns:
- the irisOcclusion
-
getOcclusionFilling
public int getOcclusionFilling()
Returns the iris occlusing filling.- Returns:
- the occlusionFilling
-
getBoundaryExtraction
public int getBoundaryExtraction()
Returns the boundary extraction.- Returns:
- the boundaryExtraction
-
getIrisDiameter
public int getIrisDiameter()
Returns the iris diameter.- Returns:
- the irisDiameter
-
getImageFormat
public int getImageFormat()
Returns the image format.- Returns:
- the imageFormat
-
getRawImageWidth
public int getRawImageWidth()
Returns the raw image width.- Returns:
- the rawImageWidth
-
getRawImageHeight
public int getRawImageHeight()
Returns the raw image height.- Returns:
- the rawImageHeight
-
getIntensityDepth
public int getIntensityDepth()
Returns the intensity depth.- Returns:
- the intensityDepth
-
getImageTransformation
public int getImageTransformation()
Returns the image transformation.- Returns:
- the imageTransformation
-
getDeviceUniqueId
public byte[] getDeviceUniqueId()
Returns the device unique id.- Returns:
- the deviceUniqueId
-
getStandardBiometricHeader
public StandardBiometricHeader getStandardBiometricHeader()
Returns the standard biometric header of this iris info.- Specified by:
getStandardBiometricHeader
in interfaceBiometricDataBlock
- Returns:
- the standard biometric header
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classAbstractListInfo<IrisBiometricSubtypeInfo>
-
equals
public boolean equals(Object obj)
- Overrides:
equals
in classAbstractListInfo<IrisBiometricSubtypeInfo>
-
toString
public String toString()
Generates a textual representation of this object.- Overrides:
toString
in classObject
- Returns:
- a textual representation of this object
- See Also:
Object.toString()
-
getIrisBiometricSubtypeInfos
public List<IrisBiometricSubtypeInfo> getIrisBiometricSubtypeInfos()
Returns the iris biometric subtype infos embedded in this iris info.- Returns:
- iris biometric subtype infos
-
addIrisBiometricSubtypeInfo
public void addIrisBiometricSubtypeInfo(IrisBiometricSubtypeInfo irisBiometricSubtypeInfo)
Adds an iris biometric subtype info to this iris info.- Parameters:
irisBiometricSubtypeInfo
- an iris biometric subtype info
-
removeIrisBiometricSubtypeInfo
public void removeIrisBiometricSubtypeInfo(int index)
Removes an iris biometric subtype info from this iris info.- Parameters:
index
- the index of the biometric subtype info to remove
-
-