Package loci.formats.in
Class LiFlimReader
java.lang.Object
loci.formats.FormatHandler
loci.formats.FormatReader
loci.formats.in.LiFlimReader
- All Implemented Interfaces:
Closeable,AutoCloseable,ICompressedTileReader,IFormatHandler,IFormatReader,IMetadataConfigurable,IPyramidHandler
LiFlimReader is the file format reader for LI-FLIM files.
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringprivate Stringprivate Stringprivate Stringprivate Stringprivate Stringprivate Stringprivate Stringprivate Stringstatic final Stringprivate Stringprivate Stringstatic final Stringstatic final Stringstatic final Stringprivate Stringstatic final Stringprivate longOffset to start of pixel data.private Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringprivate Doubleprivate ome.units.unit.Unit<ome.units.quantity.Time> static final Stringprivate Stringprivate DataInputStreamStream to use for reading gzip-compressed pixel data.private booleanTrue if gzip compression was used to deflate the pixels.private intImage number indicating position in gzip stream.private intSeries number indicating position in gzip stream.static final Stringprivate loci.common.IniListParsed configuration data.static final String[]static final Stringstatic final Stringstatic final Stringprivate intstatic final Stringprivate Stringstatic final Stringprivate Stringstatic final Stringprivate Map<Integer, LiFlimReader.ROI> static final Stringstatic final Stringprivate Stringprivate booleanif DataType is UINT12, data is compressed in 12 bits.private DataInputStreamprivate intprivate intprivate Stringstatic final Stringstatic final Stringprivate Stringstatic final Stringprivate Stringstatic final Stringprivate StringFields inherited from class loci.formats.FormatReader
core, coreIndex, datasetDescription, domains, fillColor, filterMetadata, flattenedResolutions, group, hasCompanionFiles, in, indexedAsRGB, metadata, metadataStore, normalizeData, resolution, saveOriginalMetadata, series, suffixNecessary, suffixSufficient, THUMBNAIL_DIMENSIONFields inherited from class loci.formats.FormatHandler
COMPRESSION_SUFFIXES, currentId, format, LOGGER, metadataOptions, suffixesFields inherited from interface loci.formats.IFormatReader
CAN_GROUP, CANNOT_GROUP, MUST_GROUP -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose(boolean fileOnly) Closes the currently open file.private static byte[]convert12to16LSB(byte[] image) private static byte[]convert12to16MSB(byte[] image) private intgetPixelTypeFromString(String type) private Stringprivate voidprotected voidInitializes the given file (parsing header information, etc.).private voidprivate voidbyte[]openBytes(int no, byte[] buf, int x, int y, int w, int h) Obtains a sub-image of the specified image plane into a pre-allocated byte array.private voidprivate voidprepareGZipStream(int no) private voidprepareUINT12Stream(int no) Similar to Gzip, make a DataInputstream for UINT12 dataprivate voidskip(InputStream is, long num) Methods inherited from class loci.formats.FormatReader
addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMetaList, addMeta, addMetaList, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMetaList, close, coreIndexToSeries, fileGroupOption, flattenHashtables, get16BitLookupTable, get8BitLookupTable, getAcquisitionMode, getAdvancedSeriesUsedFiles, getAdvancedUsedFiles, getArcType, getAvailableOptions, getBinning, getBitsPerPixel, getCompression, getContrastMethod, getCoreIndex, getCoreMetadataList, getCorrection, getCurrentCore, getCurrentFile, getDatasetStructureDescription, getDetectorType, getDimensionOrder, getDimensionOrder, getDomains, getEffectiveSizeC, getExperimentType, getFilamentType, getFillColor, getFillRule, getFilterType, getFontFamily, getFontStyle, getGlobalMeta, getGlobalMetadata, getIlluminationType, getImageCount, getImmersion, getIndex, getIndex, getLaserMedium, getLaserType, getMarker, getMedium, getMetadataStore, getMetadataStoreRoot, getMetadataValue, getMicrobeamManipulationType, getMicroscopeType, getModuloC, getModuloT, getModuloZ, getNamingConvention, getOptimalTileHeight, getOptimalTileWidth, getPixelType, getPixelType, getPossibleDomains, getPulse, getRequiredDirectories, getResolution, getResolutionCount, getRGBChannelCount, getRotationTransform, getSeries, getSeriesCount, getSeriesMeta, getSeriesMetadata, getSeriesMetadataValue, getSeriesUsedFiles, getSeriesUsedFiles, getSizeC, getSizeT, getSizeX, getSizeY, getSizeZ, getThumbSizeX, getThumbSizeY, getTileColumns, getTileRows, getUnderlyingReaders, getUsedFiles, getUsedFiles, getZCTCoords, getZCTModuloCoords, hasCompanionFiles, hasFlattenedResolutions, isFalseColor, isGroupFiles, isIndexed, isInterleaved, isInterleaved, isLittleEndian, isMetadataComplete, isMetadataFiltered, isNormalized, isOrderCertain, isOriginalMetadataPopulated, isRGB, isSingleFile, isThisType, isThisType, isThisType, isThisType, isThumbnailSeries, isUsedFile, makeFilterMetadata, openBytes, openBytes, openBytes, openPlane, openThumbBytes, readPlane, readPlane, readPlane, reopenFile, seriesToCoreIndex, setCoreIndex, setFillColor, setFlattenedResolutions, setGroupFiles, setId, setMetadataFiltered, setMetadataStore, setNormalized, setOriginalMetadataPopulated, setResolution, setSeries, updateMetadataListsMethods inherited from class loci.formats.FormatHandler
checkSuffix, checkSuffix, getFormat, getMetadataOptions, getNativeDataType, getSuffixes, getSupportedMetadataLevels, setMetadataOptionsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface loci.formats.ICompressedTileReader
getTileCodec, getTileCodecOptions, openCompressedBytes, openCompressedBytesMethods inherited from interface loci.formats.IFormatHandler
getFormat, getNativeDataType, getSuffixesMethods inherited from interface loci.formats.IMetadataConfigurable
getMetadataOptions, getSupportedMetadataLevels, setMetadataOptions
-
Field Details
-
INFO_TABLE
- See Also:
-
LAYOUT_TABLE
- See Also:
-
BACKGROUND_TABLE
- See Also:
-
VERSION_KEY
- See Also:
-
COMPRESSION_KEY
- See Also:
-
DATATYPE_KEY
- See Also:
-
PACKING_KEY
- See Also:
-
C_KEY
- See Also:
-
X_KEY
- See Also:
-
Y_KEY
- See Also:
-
Z_KEY
- See Also:
-
P_KEY
- See Also:
-
F_KEY
- See Also:
-
T_KEY
- See Also:
-
DarkImage_KEY
- See Also:
-
TIMESTAMP_KEY
- See Also:
-
NUMBEROFFRAMES_KEY
- See Also:
-
NUMBEROFDARKIMAGES_KEY
- See Also:
-
PIXELFORMAT_KEY
- See Also:
-
KNOWN_VERSIONS
-
COMPRESSION_NONE
- See Also:
-
COMPRESSION_GZIP
- See Also:
-
DATATYPE_UINT8
- See Also:
-
DATATYPE_INT8
- See Also:
-
DATATYPE_UINT16
- See Also:
-
DATATYPE_INT16
- See Also:
-
DATATYPE_UINT32
- See Also:
-
DATATYPE_INT32
- See Also:
-
DATATYPE_REAL32
- See Also:
-
DATATYPE_REAL64
- See Also:
-
DATATYPE_UINT12
- See Also:
-
dataOffset
private long dataOffsetOffset to start of pixel data. -
ini
private loci.common.IniList iniParsed configuration data. -
version
-
compression
-
datatype
-
packing
-
channels
-
xLen
-
yLen
-
zLen
-
phases
-
frequencies
-
timestamps
-
DarkImage
-
backgroundDatatype
-
backgroundX
-
backgroundY
-
backgroundC
-
backgroundZ
-
backgroundT
-
backgroundP
-
backgroundF
-
numRegions
private int numRegions -
rois
-
stampValues
-
exposureTime
-
exposureTimeUnit
private ome.units.unit.Unit<ome.units.quantity.Time> exposureTimeUnit -
gzip
private boolean gzipTrue if gzip compression was used to deflate the pixels. -
gz
Stream to use for reading gzip-compressed pixel data. -
gzPos
private int gzPosImage number indicating position in gzip stream. -
gzSeries
private int gzSeriesSeries number indicating position in gzip stream. -
TypeUINT12
private boolean TypeUINT12if DataType is UINT12, data is compressed in 12 bits. Similar to Gzipstream make use of a DataInputStream to unpack the compressed UINT12 pixel data into 16 bits. -
UINT12stream
-
UINT12streamPos
private int UINT12streamPos -
UINT12streamSeries
private int UINT12streamSeries
-
-
Constructor Details
-
LiFlimReader
public LiFlimReader()Constructs a new LI-FLIM reader.
-
-
Method Details
-
openBytes
public byte[] openBytes(int no, byte[] buf, int x, int y, int w, int h) throws FormatException, IOException Description copied from interface:IFormatReaderObtains a sub-image of the specified image plane into a pre-allocated byte array.- Specified by:
openBytesin interfaceIFormatReader- Specified by:
openBytesin classFormatReader- Parameters:
no- the plane index within the current series.buf- a pre-allocated buffer.x- X coordinate of the upper-left corner of the sub-imagey- Y coordinate of the upper-left corner of the sub-imagew- width of the sub-imageh- height of the sub-image- Returns:
- the pre-allocated buffer
buffor convenience. - Throws:
FormatException- if there was a problem parsing the metadata of the file.IOException- if there was a problem reading the file.- See Also:
-
close
Description copied from interface:IFormatReaderCloses the currently open file. If the flag is set, this is all that happens; if unset, it is equivalent to callingCloseable.close().- Specified by:
closein interfaceIFormatReader- Overrides:
closein classFormatReader- Throws:
IOException
-
initFile
Description copied from class:FormatReaderInitializes the given file (parsing header information, etc.). Most subclasses should override this method to perform initialization operations such as parsing metadata.- Overrides:
initFilein classFormatReader- Throws:
FormatException- if a parsing error occurs processing the file.IOException- if an I/O error occurs processing the file
-
getVersion
-
parseHeader
- Throws:
IOException
-
initOriginalMetadata
private void initOriginalMetadata() -
initCoreMetadata
- Throws:
FormatException
-
initOMEMetadata
private void initOMEMetadata() -
getPixelTypeFromString
- Throws:
FormatException
-
prepareGZipStream
- Throws:
IOException
-
prepareUINT12Stream
Similar to Gzip, make a DataInputstream for UINT12 data- Throws:
IOException
-
convert12to16LSB
private static byte[] convert12to16LSB(byte[] image) -
convert12to16MSB
private static byte[] convert12to16MSB(byte[] image) -
skip
- Throws:
IOException
-