IMP logo
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes
IMP::em2d::Image Class Reference

Detailed Description

2D Electron Microscopy images in IMP

+ Inheritance diagram for IMP::em2d::Image:

List of all members.

Public Member Functions

 Image (int rows, int cols)
 Create image of the proper size.
 Image (String filename, const ImageReaderWriter *reader)
 Create the image reading from a file.
void destroyed_msg ()
cv::Mat & get_data ()
 Access to the matrix of data.
em::ImageHeaderget_header ()
 Access to the header.
FloatRange get_min_and_max_values () const
String get_name () const
double operator() (int i, int j) const
void read (String filename, const ImageReaderWriter *reader)
void set_data (const cv::Mat &mat)
 Sets the entire matrix of data.
void set_name (const String &name)
void set_size (int rows, int cols)
void set_size (Image *img)
 Resize to the same size of the parameter image.
void set_value (double val)
void set_value (int i, int j, double val)
void set_zeros ()
void show (std::ostream &out) const
void update_header ()
void write (const String &filename, const ImageReaderWriter *writer)
- Public Member Functions inherited from IMP::base::Object
std::size_t __hash__ () const
virtual std::string get_type_name () const =0
 Return a string identifying the type of the object.
virtual IMP::base::VersionInfo get_version_info () const =0
 Get information about the module and version of the object.
void set_check_level (CheckLevel l)
void set_log_level (LogLevel l)
 Set the logging level used in this object.
void set_was_used (bool tf) const
void set_name (std::string name)

Static Public Member Functions

static Imageget_from (IMP::base::Object *o)
 Define the basic things needed by any Object.

Protected Member Functions

void set_defaults ()
void set_size_data (int rows, int cols)
- Protected Member Functions inherited from IMP::base::Object
 Object (std::string name)

Protected Attributes

cv::Mat data_
 Matrix with the data for the image.
em::ImageHeader header_
 Header for the image with all the pertinent information.
String name_
 Name of the image. Frequently it will be the name of the file.

Constructor & Destructor Documentation

IMP::em2d::Image::Image ( int  rows,
int  cols 
)

Create image of the proper size.

IMP::em2d::Image::Image ( String  filename,
const ImageReaderWriter *  reader 
)

Create the image reading from a file.


Member Function Documentation

cv::Mat& IMP::em2d::Image::get_data ( )

Access to the matrix of data.

static Image* IMP::em2d::Image::get_from ( IMP::base::Object o)
static

Define the basic things needed by any Object.

em::ImageHeader& IMP::em2d::Image::get_header ( )

Access to the header.

void IMP::em2d::Image::read ( String  filename,
const ImageReaderWriter *  reader 
)

Reads and casts the image from the file (the image matrix of data must be stored as floats)

void IMP::em2d::Image::set_data ( const cv::Mat &  mat)

Sets the entire matrix of data.

void IMP::em2d::Image::set_size ( Image img)

Resize to the same size of the parameter image.

void IMP::em2d::Image::update_header ( )

Adjusts the information of the imager header taking into account the dimensions of the data and setting the time, date, type, etc ...

void IMP::em2d::Image::write ( const String filename,
const ImageReaderWriter *  writer 
)

Writes the image to a file (the image matrix of data is stored as floats when writing)


Member Data Documentation

cv::Mat IMP::em2d::Image::data_
protected

Matrix with the data for the image.

em::ImageHeader IMP::em2d::Image::header_
protected

Header for the image with all the pertinent information.

String IMP::em2d::Image::name_
protected

Name of the image. Frequently it will be the name of the file.

Reimplemented from IMP::base::Object.


The documentation for this class was generated from the following file:

Generated on Tue May 22 2012 23:33:34 for IMP by doxygen 1.8.1