#include <amiraio.h>
Inheritance diagram for EMAN::AmiraIO:
Public Member Functions | |
AmiraIO (const string &filename, IOMode rw_mode=READ_ONLY) | |
~AmiraIO () | |
Static Public Member Functions | |
bool | is_valid (const void *first_block) |
Public Attributes | |
DEFINE_IMAGEIO_FUNC | |
Private Attributes | |
string | filename |
IOMode | rw_mode |
FILE * | amira_file |
bool | is_big_endian |
bool | initialized |
EMUtil::EMDataType | dt |
int | nx |
int | ny |
int | nz |
float | pixel |
float | xorigin |
float | yorigin |
float | zorigin |
Static Private Attributes | |
const char * | MAGIC = "# AmiraMesh" |
Its first line has some magic name to label it as an Amira image. The first few lines of the file is the ASCII header. Followed the header is the data in binary format. The data has nx x ny x nz pixels.
An Amira file has only 1 2D or 3D image.
Definition at line 52 of file amiraio.h.
|
Definition at line 52 of file amiraio.cpp. 00053 : filename(file), rw_mode(rw), amira_file(0), 00054 is_big_endian(true), initialized(false), dt(EMUtil::EM_UNKNOWN), 00055 nx(0), ny(0), nz(0), 00056 pixel(0), xorigin(0), yorigin(0), zorigin(0) 00057 { 00058 }
|
|
Definition at line 60 of file amiraio.cpp. References amira_file. 00061 { 00062 if (amira_file) { 00063 fclose(amira_file); 00064 amira_file = 0; 00065 } 00066 }
|
|
Definition at line 104 of file amiraio.cpp. References EMAN::Util::check_file_by_magic(), and MAGIC. Referenced by EMAN::EMUtil::fast_get_image_type(), and EMAN::EMUtil::get_image_type(). 00105 { 00106 ENTERFUNC; 00107 bool result = false; 00108 if (!first_block) { 00109 result = false; 00110 } 00111 else { 00112 result = Util::check_file_by_magic(first_block, MAGIC); 00113 } 00114 EXITFUNC; 00115 return result; 00116 }
|
|
Definition at line 64 of file amiraio.h. Referenced by ~AmiraIO(). |
|
|
|
|
|
|
|
|
|
|
|
Definition at line 50 of file amiraio.cpp. Referenced by is_valid(). |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|