3 #ifndef __stir_IO_InterfileDynamicDiscretisedDensityInputFileFormat_h__ 4 #define __stir_IO_InterfileDynamicDiscretisedDensityInputFileFormat_h__ 39 const std::string get_name()
const override {
return "Interfile"; }
42 bool actual_can_read(
const FileSignature& signature, std::istream&)
const override 51 unique_ptr<data_type> ret;
54 error(
"failed to read an Interfile image from stream");
58 unique_ptr<data_type>
read_from_file(
const std::string& filename)
const override 63 error(
"failed to read an Interfile image from file \"%s\"", filename.c_str());
bool is_interfile_signature(const char *const signature)
Checks if the signature corresponds to the start of an interfile header.
Definition: interfile.cxx:75
A class to read/store the file signature.
Definition: FileSignature.h:34
This file declares various utility functions.
Declarations of functions which read/write Interfile data.
DynamicDiscretisedDensity * read_interfile_dynamic_image(std::istream &input, const std::string &directory_for_data)
Read dynamic image.
Definition: interfile.cxx:167
Declaration of stir::error()
Declaration of class stir::DynamicDiscretisedDensity.
const char * get_signature() const
get access to the signature
Definition: FileSignature.h:52
Definition of stir::is_null_ptr functions.
void error(const char *const s,...)
Print error with format string a la printf and throw exception.
Definition: error.cxx:42