This graph shows which files directly or indirectly include this file:

Go to the source code of this file.
Functions | |
| void | read_image (const string &filename, int img_index=0, bool header_only=false, const Region *region=0, bool is_3d=false) |
| read an image file and stores its information to this EMData object. | |
| void | write_image (const string &filename, int img_index=0, EMUtil::ImageType imgtype=EMUtil::IMAGE_UNKNOWN, bool header_only=false, const Region *region=0, EMUtil::EMDataType filestoragetype=EMUtil::EM_FLOAT, bool use_host_endian=true) |
| write the header and data out to an image. | |
| void | append_image (const string &filename, EMUtil::ImageType imgtype=EMUtil::IMAGE_UNKNOWN, bool header_only=false) |
| append to an image file; If the file doesn't exist, create one. | |
| void | write_lst (const string &filename, const string &reffile="", int refn=-1, const string &comment="") |
| Append data to a LST image file. | |
| void | print_image (const string str=string(""), ostream &out=std::cout) |
| Print the image data to a file stream (standard out by default). | |
| static vector< EMData * > | read_images (const string &filename, vector< int >img_indices=vector< int >(), bool header_only=false) |
| Read a set of images from file specified by 'filename'. | |
| static vector< EMData * > | read_images_ext (const string &filename, int img_index_start, int img_index_end, bool header_only=false, const string &ext="") |
| Read a set of images from file specified by 'filename'. | |
| void append_image | ( | const string & | filename, | |
| EMUtil::ImageType | imgtype = EMUtil::IMAGE_UNKNOWN, |
|||
| bool | header_only = false | |||
| ) |
append to an image file; If the file doesn't exist, create one.
| filename | The image file name. | |
| imgtype | Write to the given image format type. if not specified, use the 'filename' extension to decide. | |
| header_only | To write only the header or both header and data. |
| void print_image | ( | const string | str = string(""), |
|
| ostream & | out = std::cout | |||
| ) |
Print the image data to a file stream (standard out by default).
| out | Output stream; cout by default. | |
| str | Message string to be printed. |
| void read_image | ( | const string & | filename, | |
| int | img_index = 0, |
|||
| bool | header_only = false, |
|||
| const Region * | region = 0, |
|||
| bool | is_3d = false | |||
| ) |
read an image file and stores its information to this EMData object.
If a region is given, then only read a region of the image file. The region will be this EMData object. The given region must be inside the given image file. Otherwise, an error will be created.
| filename | The image file name. | |
| img_index | The nth image you want to read. | |
| header_only | To read only the header or both header and data. | |
| region | To read only a region of the image. | |
| is_3d | Whether to treat the image as a single 3D or a set of 2Ds. This is a hint for certain image formats which has no difference between 3D image and set of 2Ds. |
| ImageFormatException | ||
| ImageReadException |
| static vector< EMData * > read_images | ( | const string & | filename, | |
| vector< int > | img_indices = vector< int >(), |
|||
| bool | header_only = false | |||
| ) | [static] |
Read a set of images from file specified by 'filename'.
Which images are read is set by 'img_indices'.
| filename | The image file name. | |
| img_indices | Which images are read. If it is empty, all images are read. If it is not empty, only those in this array are read. | |
| header_only | If true, only read image header. If false, read both data and header. |
Referenced by EMAN::EMUtil::get_all_attributes().
| static vector< EMData * > read_images_ext | ( | const string & | filename, | |
| int | img_index_start, | |||
| int | img_index_end, | |||
| bool | header_only = false, |
|||
| const string & | ext = "" | |||
| ) | [static] |
Read a set of images from file specified by 'filename'.
If the given 'ext' is not empty, replace 'filename's extension it. Images with index from img_index_start to img_index_end are read.
| filename | The image file name. | |
| img_index_start | Starting image index. | |
| img_index_end | Ending image index. | |
| header_only | If true, only read image header. If false, read both data and header. | |
| ext | The new image filename extension. |
| void write_image | ( | const string & | filename, | |
| int | img_index = 0, |
|||
| EMUtil::ImageType | imgtype = EMUtil::IMAGE_UNKNOWN, |
|||
| bool | header_only = false, |
|||
| const Region * | region = 0, |
|||
| EMUtil::EMDataType | filestoragetype = EMUtil::EM_FLOAT, |
|||
| bool | use_host_endian = true | |||
| ) |
write the header and data out to an image.
If the img_index = -1, append the image to the given image file.
If the given image file already exists, this image format only stores 1 image, and no region is given, then truncate the image file to zero length before writing data out. For header writing only, no truncation happens.
If a region is given, then write a region only.
| filename | The image file name. | |
| img_index | The nth image to write as. | |
| imgtype | Write to the given image format type. if not specified, use the 'filename' extension to decide. | |
| header_only | To write only the header or both header and data. | |
| region | Define the region to write to. | |
| filestoragetype | The image data type used in the output file. | |
| use_host_endian | To write in the host computer byte order. |
| ImageFormatException | ||
| ImageWriteException |
| void write_lst | ( | const string & | filename, | |
| const string & | reffile = "", |
|||
| int | refn = -1, |
|||
| const string & | comment = "" | |||
| ) |
Append data to a LST image file.
| filename | The LST image file name. | |
| reffile | Reference file name. | |
| refn | The reference file number. | |
| comment | The comment to the added reference file. |
1.4.7