/** Gets the reader appropriate for use with the given image plane. */ public IFormatReader getReader(int no) throws FormatException, IOException { if (noStitch) return reader; int[] q = computeIndices(no); int fno = q[0]; return getReader(getCoreIndex(), fno); }
/** Gets the reader appropriate for use with the given image plane. */ public IFormatReader getReader(int no) throws FormatException, IOException { if (noStitch) return reader; int[] q = computeIndices(no); int fno = q[0]; return getReader(getCoreIndex(), fno); }
@Override public byte[][] get8BitLookupTable() throws FormatException, IOException { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.get8BitLookupTable() : getReader(getCoreIndex(), 0).get8BitLookupTable(); }
@Override public byte[][] get8BitLookupTable() throws FormatException, IOException { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.get8BitLookupTable() : getReader(getCoreIndex(), 0).get8BitLookupTable(); }
@Override public short[][] get16BitLookupTable() throws FormatException, IOException { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.get16BitLookupTable() : getReader(getCoreIndex(), 0).get16BitLookupTable(); }
@Override public boolean isLittleEndian() { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.isLittleEndian() : getReader(getCoreIndex(), 0).isLittleEndian(); }
@Override public boolean isInterleaved() { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.isInterleaved() : getReader(getCoreIndex(), 0).isInterleaved(); }
@Override public Object openPlane(int no, int x, int y, int w, int h) throws FormatException, IOException { FormatTools.assertId(getCurrentFile(), true, 2); IFormatReader r = getReader(no); int ino = getAdjustedIndex(no); if (ino < r.getImageCount()) return r.openPlane(ino, x, y, w, h); return null; }
@Override public int getThumbSizeX() { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.getThumbSizeX() : getReader(getCoreIndex(), 0).getThumbSizeX(); }
@Override public short[][] get16BitLookupTable() throws FormatException, IOException { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.get16BitLookupTable() : getReader(getCoreIndex(), 0).get16BitLookupTable(); }
@Override public int getThumbSizeY() { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.getThumbSizeY() : getReader(getCoreIndex(), 0).getThumbSizeY(); }
@Override public boolean isLittleEndian() { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.isLittleEndian() : getReader(getCoreIndex(), 0).isLittleEndian(); }
@Override public boolean isInterleaved(int subC) { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.isInterleaved(subC) : getReader(getCoreIndex(), 0).isInterleaved(subC); }
@Override public int getThumbSizeY() { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.getThumbSizeY() : getReader(getCoreIndex(), 0).getThumbSizeY(); }
@Override public boolean isInterleaved(int subC) { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.isInterleaved(subC) : getReader(getCoreIndex(), 0).isInterleaved(subC); }
@Override public Object openPlane(int no, int x, int y, int w, int h) throws FormatException, IOException { FormatTools.assertId(getCurrentFile(), true, 2); IFormatReader r = getReader(no); int ino = getAdjustedIndex(no); if (ino < r.getImageCount()) return r.openPlane(ino, x, y, w, h); return null; }
@Override public int getThumbSizeX() { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.getThumbSizeX() : getReader(getCoreIndex(), 0).getThumbSizeX(); }
@Override public boolean isInterleaved() { FormatTools.assertId(getCurrentFile(), true, 2); return noStitch ? reader.isInterleaved() : getReader(getCoreIndex(), 0).isInterleaved(); }
@Override public byte[] openThumbBytes(int no) throws FormatException, IOException { FormatTools.assertId(getCurrentFile(), true, 2); IFormatReader r = getReader(no); int ino = getAdjustedIndex(no); if (ino < r.getImageCount()) return r.openThumbBytes(ino); // return a blank image to cover for the fact that // this file does not contain enough image planes return externals[getExternalSeries()].getBlankThumbBytes(); }
@Override public byte[] openThumbBytes(int no) throws FormatException, IOException { FormatTools.assertId(getCurrentFile(), true, 2); IFormatReader r = getReader(no); int ino = getAdjustedIndex(no); if (ino < r.getImageCount()) return r.openThumbBytes(ino); // return a blank image to cover for the fact that // this file does not contain enough image planes return externals[getExternalSeries()].getBlankThumbBytes(); }