public class NDPIReader extends BaseTiffReader
Modifier and Type | Field and Description |
---|---|
private static int |
BLUE_MULTIPLIER |
private static int |
BYTE_COUNT_HIGH_BYTES |
private static int |
CAPTURE_MODE |
private static int |
DEFAULT_GAMMA |
private static int |
EXPOSURE_RATIO |
private static int |
EXPOSURE_TIME |
private static int |
FILTER_SET_NAME |
private static int |
FIRMWARE_VERSION |
private static int |
FOCUS_OFFSET |
private static int |
FOCUS_POINT_REGIONS |
private static int |
FOCUS_TIME |
private static int |
FULLY_AUTO_FOCUS |
private static int |
GREEN_MULTIPLIER |
private int |
initializedPlane |
private int |
initializedSeries |
private java.lang.String |
instrumentModel |
private static int |
JPEG_QUALITY |
private static int |
LABEL_OBSCURED |
private static int |
LAMP_AGE |
private java.lang.Double |
magnification |
private static int |
MARKER_TAG |
private static int |
MAX_SIZE |
private static int |
METADATA_TAG |
private static int |
OFFSET_HIGH_BYTES |
private int |
pyramidHeight |
private static int |
RED_MULTIPLIER |
private static int |
REFERENCE |
private static int |
REFOCUS_INTERVAL |
private static int |
SCAN_TIME |
private static int |
SERIAL_NUMBER |
private java.lang.String |
serialNumber |
private JPEGTurboService |
service |
private int |
sizeZ |
private static int |
SOURCE_LENS |
private static int |
THUMB_TAG_2 |
private static int |
TISSUE_INDEX |
private static int |
VERSION |
private static int |
WAVELENGTH |
private static int |
WRITE_TIME |
private static int |
X_POSITION |
private static int |
Y_POSITION |
private static int |
Z_POSITION |
DATE_FORMATS, LOGGER
canSeparateSeries, equalStrips, ifds, lastPlane, mergeSubIFDs, noSubresolutions, seriesToIFD, subResolutionIFDs, thumbnailIFDs, tiffParser, use64Bit
core
coreIndex, datasetDescription, domains, filterMetadata, flattenedResolutions, group, hasCompanionFiles, in, indexedAsRGB, metadata, metadataStore, normalizeData, resolution, saveOriginalMetadata, series, suffixNecessary, suffixSufficient, THUMBNAIL_DIMENSION
COMPRESSION_SUFFIXES, currentId, format, metadataOptions, suffixes
CAN_GROUP, CANNOT_GROUP, MUST_GROUP
Constructor and Description |
---|
NDPIReader()
Constructs a new NDPI reader.
|
Modifier and Type | Method and Description |
---|---|
void |
close(boolean fileOnly)
Closes the currently open file.
|
int |
fileGroupOption(java.lang.String id)
Returns an indication of whether the files in a multi-file dataset can
be handled individually.
|
private int |
getBitsPerSample(int mode)
Get the number of bits per sample associated with the given capture mode.
|
private java.lang.String |
getCaptureMode(int mode)
Get the description of the given capture mode.
|
private int |
getIFDIndex(int seriesIndex,
int zIndex) |
int |
getOptimalTileHeight()
Returns the optimal sub-image height for use with openBytes.
|
int |
getOptimalTileWidth()
Returns the optimal sub-image width for use with openBytes.
|
protected void |
initFile(java.lang.String id)
Initializes the given file (parsing header information, etc.).
|
protected void |
initMetadataStore()
Populates the metadata store using the data parsed in
BaseTiffReader.initStandardMetadata() along with some further parsing done in
the method itself. |
protected void |
initStandardMetadata()
Parses standard metadata.
|
boolean |
isThisType(java.lang.String name,
boolean open)
Checks if a file matches the type of this format reader.
|
byte[] |
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.
|
byte[] |
openThumbBytes(int no)
Obtains a thumbnail for the specified image plane from the current file,
as a byte array.
|
private boolean |
useTiffParser(IFD ifd) |
getExifTagName, getImageCreationDate, initMetadata, put, put, put, put, put, put, put, put, put, put, putDouble, putInt, putString
get16BitLookupTable, get8BitLookupTable, getIFDs, getThumbnailIFDs, getThumbSizeX, getThumbSizeY, initTiffParser, isThisType, reopenFile, setResolutionLevel
coreIndexToSeries, flattenHashtables, getCoreIndex, getCoreMetadataList, getCurrentCore, getResolution, getResolutionCount, getSeries, getSeriesCount, seriesToCoreIndex, setCoreIndex, setResolution, setSeries
addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMeta, addGlobalMetaList, addMeta, addMetaList, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMeta, addSeriesMetaList, close, getAcquisitionMode, getAdvancedSeriesUsedFiles, getAdvancedUsedFiles, getArcType, getBinning, getBitsPerPixel, getCompression, getContrastMethod, getCorrection, getCurrentFile, getDatasetStructureDescription, getDetectorType, getDimensionOrder, getDimensionOrder, getDomains, getEffectiveSizeC, getExperimentType, getFilamentType, getFillRule, getFilterType, getFontFamily, getFontStyle, getGlobalMeta, getGlobalMetadata, getIlluminationType, getImageCount, getImmersion, getIndex, getIndex, getLaserMedium, getLaserType, getMarker, getMedium, getMetadataStore, getMetadataStoreRoot, getMetadataValue, getMicrobeamManipulationType, getMicroscopeType, getModuloC, getModuloT, getModuloZ, getNamingConvention, getPixelType, getPixelType, getPossibleDomains, getPulse, getRequiredDirectories, getRGBChannelCount, getRotationTransform, getSeriesMeta, getSeriesMetadata, getSeriesMetadataValue, getSeriesUsedFiles, getSeriesUsedFiles, getSizeC, getSizeT, getSizeX, getSizeY, getSizeZ, getUnderlyingReaders, getUsedFiles, getUsedFiles, getZCTCoords, getZCTModuloCoords, hasCompanionFiles, hasFlattenedResolutions, isFalseColor, isGroupFiles, isIndexed, isInterleaved, isInterleaved, isLittleEndian, isMetadataComplete, isMetadataFiltered, isNormalized, isOrderCertain, isOriginalMetadataPopulated, isRGB, isSingleFile, isThisType, isThisType, isThumbnailSeries, isUsedFile, makeFilterMetadata, openBytes, openBytes, openBytes, openPlane, readPlane, readPlane, setFlattenedResolutions, setGroupFiles, setId, setMetadataFiltered, setMetadataStore, setNormalized, setOriginalMetadataPopulated, updateMetadataLists
checkSuffix, checkSuffix, getFormat, getMetadataOptions, getNativeDataType, getSuffixes, getSupportedMetadataLevels, setMetadataOptions
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getFormat, getNativeDataType, getSuffixes
getMetadataOptions, getSupportedMetadataLevels, setMetadataOptions
private static final int MAX_SIZE
private static final int OFFSET_HIGH_BYTES
private static final int BYTE_COUNT_HIGH_BYTES
private static final int VERSION
private static final int SOURCE_LENS
private static final int X_POSITION
private static final int Y_POSITION
private static final int Z_POSITION
private static final int TISSUE_INDEX
private static final int MARKER_TAG
private static final int REFERENCE
private static final int FILTER_SET_NAME
private static final int EXPOSURE_RATIO
private static final int RED_MULTIPLIER
private static final int GREEN_MULTIPLIER
private static final int BLUE_MULTIPLIER
private static final int THUMB_TAG_2
private static final int FOCUS_POINT_REGIONS
private static final int CAPTURE_MODE
private static final int SERIAL_NUMBER
private static final int JPEG_QUALITY
private static final int REFOCUS_INTERVAL
private static final int FOCUS_OFFSET
private static final int FIRMWARE_VERSION
private static final int METADATA_TAG
private static final int LABEL_OBSCURED
private static final int WAVELENGTH
private static final int LAMP_AGE
private static final int EXPOSURE_TIME
private static final int FOCUS_TIME
private static final int SCAN_TIME
private static final int WRITE_TIME
private static final int FULLY_AUTO_FOCUS
private static final int DEFAULT_GAMMA
private int initializedSeries
private int initializedPlane
private int sizeZ
private int pyramidHeight
private JPEGTurboService service
private java.lang.Double magnification
private java.lang.String serialNumber
private java.lang.String instrumentModel
public boolean isThisType(java.lang.String name, boolean open)
FormatReader
FormatReader.isThisType(RandomAccessInputStream)
.isThisType
in interface IFormatReader
isThisType
in class FormatReader
open
- If true, and the file extension is insufficient to determine
the file type, the (existing) file is opened for further analysis.public int fileGroupOption(java.lang.String id) throws FormatException, java.io.IOException
IFormatReader
fileGroupOption
in interface IFormatReader
fileGroupOption
in class FormatReader
id
- a file in the multi-file datasetFormatTools.MUST_GROUP
indicates that the
files cannot be handled separately; the reader will always detect and
read all files in the dataset. FormatTools.CAN_GROUP
indicates
that the files may be handled separately, but file grouping must then
be disabled via IFormatReader.setGroupFiles(boolean)
.
FormatTools.CANNOT_GROUP
indicates that the files must be handled
separately; the reader will not attempt to read all files in the dataset
(this is rare).FormatException
java.io.IOException
IFormatReader.fileGroupOption(String)
public byte[] openBytes(int no, byte[] buf, int x, int y, int w, int h) throws FormatException, java.io.IOException
IFormatReader
openBytes
in interface IFormatReader
openBytes
in class MinimalTiffReader
no
- the image index within the file.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-imagebuf
for convenience.FormatException
- if there was a problem parsing the metadata of the
file.java.io.IOException
- if there was a problem reading the file.IFormatReader.openBytes(int, byte[], int, int, int, int)
public byte[] openThumbBytes(int no) throws FormatException, java.io.IOException
IFormatReader
openThumbBytes
in interface IFormatReader
openThumbBytes
in class MinimalTiffReader
FormatException
java.io.IOException
public void close(boolean fileOnly) throws java.io.IOException
IFormatReader
Closeable.close()
.close
in interface IFormatReader
close
in class MinimalTiffReader
java.io.IOException
public int getOptimalTileWidth()
IFormatReader
getOptimalTileWidth
in interface IFormatReader
getOptimalTileWidth
in class MinimalTiffReader
public int getOptimalTileHeight()
IFormatReader
getOptimalTileHeight
in interface IFormatReader
getOptimalTileHeight
in class MinimalTiffReader
protected void initFile(java.lang.String id) throws FormatException, java.io.IOException
SubResolutionFormatReader
initFile
in class BaseTiffReader
FormatException
- if a parsing error occurs processing the file.java.io.IOException
- if an I/O error occurs processing the fileprotected void initStandardMetadata() throws FormatException, java.io.IOException
BaseTiffReader
initStandardMetadata
in class BaseTiffReader
FormatException
java.io.IOException
protected void initMetadataStore() throws FormatException
BaseTiffReader
BaseTiffReader.initStandardMetadata()
along with some further parsing done in
the method itself.
All calls to the active MetadataStore
should be made in this
method and only in this method. This is especially important for
sub-classes that override the getters for pixel set array size, etc.initMetadataStore
in class BaseTiffReader
FormatException
private int getIFDIndex(int seriesIndex, int zIndex)
private boolean useTiffParser(IFD ifd) throws FormatException
FormatException
private java.lang.String getCaptureMode(int mode)
private int getBitsPerSample(int mode)
Copyright © 2020 Open Microscopy Environment