Package qupath.imagej.images.writers
Class ZipWriterIJ
java.lang.Object
qupath.imagej.images.writers.ZipWriterIJ
- All Implemented Interfaces:
ImageWriter<BufferedImage>
ImageWriter implementation to write zipped TIFF images using ImageJ.
- Author:
- Pete Bankhead
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionGet further details of the writer, which may be displayed to a user.Get the file extensions used by the image writer.Get the class of supported images.getName()
Get the name of the image writer.boolean
supportsImageType
(ImageServer<BufferedImage> server) Test whether images provided by a specified ImageServer can be successfully written.boolean
Returns true if the writer is capable of storing pixel size information.boolean
Returns true if the writer is capable of writing pyramidal images.boolean
Check if writer can handle RGB (it probably can...).boolean
Check if writer can handle multiple timepoints.boolean
Check if writer can handle multiple z-slices.void
writeImage
(ImagePlus imp, OutputStream stream) void
writeImage
(ImagePlus imp, String pathOutput) void
writeImage
(BufferedImage img, OutputStream stream) Write a full image to a specified output stream.void
writeImage
(BufferedImage img, String pathOutput) Write a full image to a specified path.void
writeImage
(ImageServer<BufferedImage> server, OutputStream stream) Write a full image to a specified output stream.void
writeImage
(ImageServer<BufferedImage> server, String pathOutput) Write a full image to a specified path.void
writeImage
(ImageServer<BufferedImage> server, RegionRequest region, OutputStream stream) Write an image region to a specified output stream.void
writeImage
(ImageServer<BufferedImage> server, RegionRequest request, String pathOutput) Write an image region to a specified path.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface qupath.lib.images.writers.ImageWriter
getDefaultExtension
-
Constructor Details
-
ZipWriterIJ
public ZipWriterIJ()
-
-
Method Details
-
getName
Description copied from interface:ImageWriter
Get the name of the image writer.- Returns:
-
getDetails
Description copied from interface:ImageWriter
Get further details of the writer, which may be displayed to a user.- Returns:
-
supportsRGB
public boolean supportsRGB()Description copied from interface:ImageWriter
Check if writer can handle RGB (it probably can...).- Returns:
-
getExtensions
Description copied from interface:ImageWriter
Get the file extensions used by the image writer. These are returned without the leading 'dot'. In the case where multiple extensions are associated with a file type (e.g. "jpg", "jpeg", "tif", "tiff") the preferred should be returned first;- Returns:
-
writeImage
- Throws:
IOException
-
supportsT
public boolean supportsT()Description copied from interface:ImageWriter
Check if writer can handle multiple timepoints.- Specified by:
supportsT
in interfaceImageWriter<BufferedImage>
- Returns:
-
supportsZ
public boolean supportsZ()Description copied from interface:ImageWriter
Check if writer can handle multiple z-slices.- Specified by:
supportsZ
in interfaceImageWriter<BufferedImage>
- Returns:
-
supportsImageType
Description copied from interface:ImageWriter
Test whether images provided by a specified ImageServer can be successfully written.Reasons why it might not be are the number of channels and/or bit-depth.
- Specified by:
supportsImageType
in interfaceImageWriter<BufferedImage>
- Parameters:
server
-- Returns:
-
supportsPyramidal
public boolean supportsPyramidal()Description copied from interface:ImageWriter
Returns true if the writer is capable of writing pyramidal images.- Specified by:
supportsPyramidal
in interfaceImageWriter<BufferedImage>
- Returns:
-
supportsPixelSize
public boolean supportsPixelSize()Description copied from interface:ImageWriter
Returns true if the writer is capable of storing pixel size information.- Specified by:
supportsPixelSize
in interfaceImageWriter<BufferedImage>
- Returns:
-
writeImage
public void writeImage(ImageServer<BufferedImage> server, RegionRequest request, String pathOutput) throws IOException Description copied from interface:ImageWriter
Write an image region to a specified path.- Specified by:
writeImage
in interfaceImageWriter<BufferedImage>
- Parameters:
server
-request
-pathOutput
-- Throws:
IOException
-
writeImage
Description copied from interface:ImageWriter
Write a full image to a specified path.- Specified by:
writeImage
in interfaceImageWriter<BufferedImage>
- Parameters:
server
-pathOutput
-- Throws:
IOException
-
writeImage
Description copied from interface:ImageWriter
Write a full image to a specified path.- Specified by:
writeImage
in interfaceImageWriter<BufferedImage>
- Parameters:
img
-pathOutput
-- Throws:
IOException
-
writeImage
public void writeImage(ImageServer<BufferedImage> server, RegionRequest region, OutputStream stream) throws IOException Description copied from interface:ImageWriter
Write an image region to a specified output stream.- Specified by:
writeImage
in interfaceImageWriter<BufferedImage>
- Parameters:
server
-region
-stream
-- Throws:
IOException
-
writeImage
Description copied from interface:ImageWriter
Write a full image to a specified output stream.- Specified by:
writeImage
in interfaceImageWriter<BufferedImage>
- Parameters:
img
-stream
-- Throws:
IOException
-
writeImage
Description copied from interface:ImageWriter
Write a full image to a specified output stream.- Specified by:
writeImage
in interfaceImageWriter<BufferedImage>
- Parameters:
server
-stream
-- Throws:
IOException
-
getImageClass
Description copied from interface:ImageWriter
Get the class of supported images.- Specified by:
getImageClass
in interfaceImageWriter<BufferedImage>
- Returns:
ImageServer.getImageClass()
-
writeImage
- Throws:
IOException
-