Read from MATLAB files. More...
Go to the source code of this file.
Classes | |
| class | vnl_vector< T > |
| Mathematical vector class, templated by type of element. More... | |
| class | vnl_matrix< T > |
| An ordinary mathematical matrix. More... | |
| class | vnl_matlab_readhdr |
Macros | |
| #define | fsm_declare_methods(T) |
Functions | |
| template<class T > | |
| VNL_EXPORT bool | vnl_matlab_read_or_die (std::istream &, vnl_vector< T > &, char const *name=nullptr) |
| Attempt to read vector or matrix. More... | |
| template<class T > | |
| VNL_EXPORT bool | vnl_matlab_read_or_die (std::istream &, vnl_matrix< T > &, char const *name=nullptr) |
| template<class T > | |
| VNL_EXPORT void | vnl_matlab_read_data (std::istream &s, T *ptr, unsigned n) |
| MATLAB stores its data as a real block followed by an imaginary block. More... | |
Read from MATLAB files.
Modifications LSB (Manchester) 23 Mar 2001 documentation tidied Feb.2002 - Peter Vanroose - brief doxygen comment placed on single line 21 Apr 2009 Kent Williams - Taking care of the byte ordering of the MAT file
Definition in file vnl_matlab_read.h.
| #define fsm_declare_methods | ( | T | ) |
Definition at line 70 of file vnl_matlab_read.h.
| VNL_EXPORT void vnl_matlab_read_data | ( | std::istream & | s, |
| T * | ptr, | ||
| unsigned | n | ||
| ) |
MATLAB stores its data as a real block followed by an imaginary block.
This function will read both blocks and interleave them into the area pointed to by ptr. For real T, it is equivalent to s.read(ptr, sizeof(T)*n);
| VNL_EXPORT bool vnl_matlab_read_or_die | ( | std::istream & | , |
| vnl_vector< T > & | , | ||
| char const * | name = nullptr |
||
| ) |
Attempt to read vector or matrix.
If the MATLAB header cannot be read, return false. Else, if a name is given, and it doesn't match what's in the file, abort(). If the data in the file cannot reasonably be read into the destination, abort().
The vector/matrix will be resized if necessary.
Definition at line 231 of file vnl_matlab_read.cxx.
| VNL_EXPORT bool vnl_matlab_read_or_die | ( | std::istream & | , |
| vnl_matrix< T > & | , | ||
| char const * | name = nullptr |
||
| ) |
Definition at line 257 of file vnl_matlab_read.cxx.
1.8.15