final PFile file = frame.getFile(channel); if (file == null) { warnFile(sequence, index, channel);
final PFile file = frame.getFile(channel); if (file == null) { warnFile(sequence, index, channel);
final PFile file = firstFrame.getFile(channel);
final PFile file = firstFrame.getFile(channel);
@Override public byte[] openBytes(int no, byte[] buf, int x, int y, int w, int h) throws FormatException, IOException { FormatTools.checkPlaneParameters(this, no, buf.length, x, y, w, h); if (singleTiffMode) return tiff.openBytes(no, buf, x, y, w, h); // convert 1D index to (sequence, index, channel) coordinates. final int[] zct = getZCTCoords(no); final int z = zct[0], c = zct[1], t = zct[2]; final Sequence sequence = sequence(t, getSeries()); final int index = frameIndex(sequence, z, t, getSeries()); final Frame frame = sequence.getFrame(index); if (frame == null) { warnFrame(sequence, index); return blank(buf); } final int channel = channels[c]; final PFile file = frame.getFile(channel); if (file == null) { warnFile(sequence, index, channel); return blank(buf); } tiff.setId(getPath(file)); return tiff.openBytes(0, buf, x, y, w, h); }
@Override public byte[] openBytes(int no, byte[] buf, int x, int y, int w, int h) throws FormatException, IOException { FormatTools.checkPlaneParameters(this, no, buf.length, x, y, w, h); if (singleTiffMode) return tiff.openBytes(no, buf, x, y, w, h); // convert 1D index to (sequence, index, channel) coordinates. final int[] zct = getZCTCoords(no); final int z = zct[0], c = zct[1], t = zct[2]; final Sequence sequence = sequence(t, getSeries()); final int index = frameIndex(sequence, z, t, getSeries()); final Frame frame = sequence.getFrame(index); if (frame == null) { warnFrame(sequence, index); return blank(buf); } final int channel = channels[c]; final PFile file = frame.getFile(channel); if (file == null) { warnFile(sequence, index, channel); return blank(buf); } tiff.setId(getPath(file)); return tiff.openBytes(0, buf, x, y, w, h); }
/** * Gets the {@code Frame} at the given ({@code cycle}, {@code index}, * {@code channel}). */ public PFile getFile(final int index, final int channel) { final Frame frame = getFrame(index); if (frame == null) return null; return frame.getFile(channel); }
/** * Gets the {@code Frame} at the given ({@code cycle}, {@code index}, * {@code channel}). */ public PFile getFile(final int cycle, final int index, final int channel) { final Frame frame = getFrame(cycle, index); if (frame == null) return null; return frame.getFile(channel); }
/** * Gets the {@code Frame} at the given ({@code cycle}, {@code index}, * {@code channel}). */ public PFile getFile(final int cycle, final int index, final int channel) { final Frame frame = getFrame(cycle, index); if (frame == null) return null; return frame.getFile(channel); }
/** * Gets the {@code Frame} at the given ({@code cycle}, {@code index}, * {@code channel}). */ public PFile getFile(final int index, final int channel) { final Frame frame = getFrame(index); if (frame == null) return null; return frame.getFile(channel); }