file_io.h file
Functions for reading and writing images from/to files. See File I/O.
Classes
-
struct dip::
FileInformation - A data structure with information about an image file. more...
-
class dip::
FixedOutputBuffer - An output buffer implementation that cannot be resized. more...
-
class dip::
OutputBuffer abstract - An abstract base class for output buffers. more...
-
class dip::
SimpleOutputBuffer - A simple output buffer implementation. more...
Functions
-
auto dip::
FileAddExtension(dip::String const& filename, dip::String const& extension) -> dip::String deprecated - Adds the given extension to the file name, replacing any existing extension.
-
auto dip::
FileAppendExtension(dip::String const& filename, dip::String const& extension) -> dip::String - Appends the given extension to the file name.
-
auto dip::
FileCompareExtension(dip::String const& filename, dip::String const& extension) -> bool - Returns true if the file name has the given extension.
-
auto dip::
FileGetExtension(dip::String const& filename) -> dip::String - Gets the extension for the given file name, or an empty string if there’s no extension.
-
auto dip::
FileGetExtensionPosition(dip::String const& filename) -> String::size_type - Returns the location of the dot that separates the extension, or
dip::String::nposif there is no dot. -
auto dip::
FileHasExtension(dip::String const& filename) -> bool - Returns true if the file name has an extension.
-
auto dip::
ImageIsICS(dip::String const& filename) -> bool - Returns true if the file
filenameis an ICS file. -
auto dip::
ImageIsJPEG(dip::String const& filename) -> bool - Returns true if the file
filenameis a JPEG file. -
auto dip::
ImageIsNPY(dip::String const& filename) -> bool - Returns true if the file
filenameis a NPY file. -
auto dip::
ImageIsPNG(dip::String const& filename) -> bool - Returns true if the file
filenameis a PNG file. -
auto dip::
ImageIsTIFF(dip::String const& filename) -> bool - Returns true if the file
filenameis a TIFF file. -
auto dip::
ImageReadICS(dip::Image& out, dip::String const& filename, dip::RangeArray const& roi = {}, dip::Range const& channels = {}, dip::String const& mode = "") -> dip::FileInformation - Read the image in the ICS file
filenameand puts it inout. more... -
auto dip::
ImageReadICS(dip::Image& out, dip::String const& filename, dip::UnsignedArray const& origin, dip::UnsignedArray const& sizes = {}, dip::UnsignedArray const& spacing = {}, dip::Range const& channels = {}, dip::String const& mode = "") -> dip::FileInformation - This function is an overload of the previous function that defines the ROI using different parameters. more...
-
auto dip::
ImageReadICSInfo(dip::String const& filename) -> dip::FileInformation - Reads image information and metadata from the ICS file
filename, without reading the actual pixel data. Seedip::ImageReadICSfor more details on the file format and the handling offilename. -
auto dip::
ImageReadJPEG(dip::Image& out, dip::String const& filename) -> dip::FileInformation - Reads an image from the JPEG file
filenameand puts it inout. more... -
auto dip::
ImageReadJPEG(dip::Image& out, void const* buffer, dip::uint length) -> dip::FileInformation - Reads an image from the JPEG-encoded buffer and puts it in
out. more... -
auto dip::
ImageReadJPEGInfo(dip::String const& filename) -> dip::FileInformation - Reads image information and metadata from the JPEG file
filename, without reading the actual pixel data. Seedip::ImageReadJPEGfor more details on the handling offilename. -
auto dip::
ImageReadJPEGInfo(void const* buffer, dip::uint length) -> dip::FileInformation - Reads image information and metadata from the JPEG-encoded buffer, without reading the actual pixel data. more...
-
auto dip::
ImageReadNPY(dip::Image& out, dip::String const& filename) -> dip::FileInformation - Reads a numeric array from the NumPy NPY file
filenameand puts it inout. more... -
auto dip::
ImageReadNPYInfo(dip::String const& filename) -> dip::FileInformation - Reads array information (size and data type) from the NumPy NPY file
filename, without reading the actual pixel data. Seedip::ImageReadNPYfor more details on the handling offilename. -
auto dip::
ImageReadPNG(dip::Image& out, dip::String const& filename) -> dip::FileInformation - Reads an image from the PNG file
filenameand puts it inout. more... -
auto dip::
ImageReadPNG(dip::Image& out, void const* buffer, dip::uint length) -> dip::FileInformation - Reads an image from the PNG-encoded buffer and puts it in
out. more... -
auto dip::
ImageReadPNGInfo(dip::String const& filename) -> dip::FileInformation - Reads image information and metadata from the PNG file
filename, without reading the actual pixel data. Seedip::ImageReadPNGfor more details on the handling offilename. -
auto dip::
ImageReadPNGInfo(void const* buffer, dip::uint length) -> dip::FileInformation - Reads image information and metadata from the PNG-encoded buffer, without reading the actual pixel data. more...
-
auto dip::
ImageReadTIFF(dip::Image& out, dip::String const& filename, dip::Range imageNumbers = Range{0}, dip::RangeArray const& roi = {}, dip::Range const& channels = {}, dip::String const& useColorMap = S::APPLY) -> dip::FileInformation - Reads an image from the TIFF file
filenameand puts it inout. more... -
auto dip::
ImageReadTIFF(dip::Image& out, dip::String const& filename, dip::Range const& imageNumbers, dip::UnsignedArray const& origin, dip::UnsignedArray const& sizes = {}, dip::UnsignedArray const& spacing = {}, dip::Range const& channels = {}, dip::String const& useColorMap = S::APPLY) -> dip::FileInformation - This function is an overload of the previous function that defines the ROI using different parameters. more...
-
auto dip::
ImageReadTIFFInfo(dip::String const& filename, dip::uint imageNumber = 0) -> dip::FileInformation - Reads image information and metadata from the TIFF file
filename, without reading the actual pixel data. Seedip::ImageReadTIFFfor more details on the handling offilenameandimageNumber. -
void dip::
ImageReadTIFFSeries(dip::Image& out, dip::StringArray const& filenames, dip::String const& useColorMap = S::APPLY) - Reads a set of 2D TIFF images as a single 3D image. more...
-
void dip::
ImageWriteICS(dip::Image const& image, dip::String const& filename, dip::StringArray const& history = {}, dip::uint significantBits = 0, dip::StringSet const& options = {}) - Writes
imageas an ICS file. more... -
void dip::
ImageWriteJPEG(dip::Image const& image, dip::String const& filename, dip::uint jpegLevel = 80) - Writes
imageas a JPEG file. more... -
void dip::
ImageWriteJPEG(dip::Image const& image, dip::OutputBuffer& buffer, dip::uint jpegLevel = 80) - Encodes
imageas a JPEG file and writes it to a user-created buffer. Seedip::ImageWriteJPEGfor details. -
auto dip::
ImageWriteJPEG(dip::Image const& image, dip::uint jpegLevel = 80) -> std::vector<dip::uint8> - Encodes
imageas a JPEG file and writes it to a buffer that is returned. Seedip::ImageWriteJPEGfor details. -
void dip::
ImageWriteNPY(dip::Image const& image, dip::String const& filename) - Writes
imageas a numeric array to a NumPy NPY file. more... -
void dip::
ImageWritePNG(dip::Image const& image, dip::String const& filename, dip::sint compressionLevel = 6, dip::StringSet const& filterChoice = {S::ALL}, dip::uint significantBits = 0) - Writes
imageas a PNG file. more... -
void dip::
ImageWritePNG(dip::Image const& image, dip::OutputBuffer& buffer, dip::sint compressionLevel = 6, dip::StringSet const& filterChoice = {S::ALL}, dip::uint significantBits = 0) - Encodes
imageas a PNG file and writes it to a user-created buffer. Seedip::ImageWritePNGfor details. -
auto dip::
ImageWritePNG(dip::Image const& image, dip::sint compressionLevel = 6, dip::StringSet const& filterChoice = {S::ALL}, dip::uint significantBits = 0) -> std::vector<dip::uint8> - Encodes
imageas a PNG file and writes it to a buffer that is returned. Seedip::ImageWritePNGfor details. -
void dip::
ImageWriteTIFF(dip::Image const& image, dip::String const& filename, dip::String const& compression = "", dip::uint jpegLevel = 80) - Writes
imageas a TIFF file. more...