SLIP
1.4
|
Provides some input/ouput algorithms. More...
#include <ios>
#include <stdexcept>
#include <iostream>
#include <iterator>
#include <iomanip>
#include <sstream>
#include <string>
#include <fstream>
#include <algorithm>
#include "error.hpp"
#include <cstdio>
#include <cstdlib>
#include "Array.hpp"
#include "Matrix.hpp"
#include "Point2d.hpp"
#include "Point3d.hpp"
#include "stride_iterator.hpp"
#include <boost/tokenizer.hpp>
Go to the source code of this file.
Namespaces | |
slip | |
This namespace corresponds to the kernel of the Simple Library on Image Processing (SLIP). That is to say that it contains the data structures and the algorithms needed by these data strucutres. | |
Functions | |
Miscellaneous algorithms | |
std::size_t | slip::split_extension (const std::string &file_path_name, std::string &file_path_name_cut, std::string &ext) |
Split a file_name in two substrings: the file_path_name string without the extension and the extension string. More... | |
std::string | slip::compose_file_name (const std::string &file_path_name, const std::size_t img) |
Compose a file_name from the file name format basenamend*.ext. More... | |
template<typename Container > | |
void | slip::print (const Container &C, const std::string &name="") |
Print the name of the container follow by the values of the container in a terminal. More... | |
Raw input/output algorithms | |
template<typename InputIterator > | |
void | slip::write_raw (InputIterator first, InputIterator last, const std::string &file_path_name) |
Write a Container to an raw file. More... | |
template<typename InputIterator > | |
void | slip::read_raw (const std::string &file_path_name, InputIterator first, InputIterator last) |
Write a Container to an raw file. More... | |
2d containers input/output | |
template<typename RandomAccessIterator2d , typename WriteType > | |
void | slip::write_ascii_2d (RandomAccessIterator2d upper_left, RandomAccessIterator2d bottom_right, const std::string &file_path_name) |
Write a Container2d to an ASCII file. More... | |
template<typename Container2d , typename WriteType > | |
void | slip::write_ascii_2d (const Container2d &cont, const std::string &file_path_name) |
Write a Container2d to an ASCII file. More... | |
template<typename Container2d > | |
void | slip::read_ascii_2d (Container2d &container, const std::string &file_path_name) |
Read a Container2d from an ASCII file. More... | |
template<typename RandomAccessIterator2d , typename WriteType > | |
void | slip::write_tecplot_2d (RandomAccessIterator2d upper_left, RandomAccessIterator2d bottom_right, const std::string &file_path_name, const std::string &title, const std::string &zone, const int precision=6) |
Write a Container2d to an ASCII file. More... | |
2d vector fields input/output | |
template<typename MultiContainer2d > | |
void | slip::write_gnuplot_vect2d (const MultiContainer2d &field, const std::string &file_path_name, const int precision=6) |
Write a DenseVector2dField2D to a gnuplot file. More... | |
template<typename MultiContainer2d , typename T > | |
void | slip::write_gnuplot_vect2d (const MultiContainer2d &field, const slip::Point2d< T > &init_point, const slip::Point2d< T > &step, const std::string &file_path_name, const int precision=6) |
Write a DenseVector2dField2D to a gnuplot file handle real regular grid 2d. More... | |
template<typename MultiContainer2d > | |
void | slip::write_tecplot_vect2d (const MultiContainer2d &field, const std::string &file_path_name, const std::string &title, const std::string &zone, const int precision=6) |
Write a DenseVector2dField2D to a tecplot file. More... | |
template<typename MultiContainer2d , typename T > | |
void | slip::write_tecplot_vect2d (const MultiContainer2d &field, const slip::Point2d< T > &init_point, const slip::Point2d< T > &step, const std::string &file_path_name, const std::string &title, const std::string &zone, const int precision=6) |
Write a DenseVector2dField2D to a tecplot file handle real regular grid 2d. More... | |
template<class MultiContainer2d > | |
void | slip::read_tecplot_vect2d (const std::string &file_path_name, MultiContainer2d &field) |
Create a DenseVector2dField2D from a tecplot file. More... | |
template<class MultiContainer2d , typename T > | |
void | slip::read_tecplot_vect2d (const std::string &file_path_name, MultiContainer2d &field, slip::Point2d< T > &init_point, slip::Point2d< T > &step) |
Create a DenseVector2dField2D from a tecplot file handle 2d real regular grid. More... | |
template<typename MultiContainer2d > | |
void | slip::read_tecplot_XY (const std::string &file_path_name, MultiContainer2d &XY) |
Create a XY DenseVector2dField2D from a tecplot file. More... | |
template<typename Vector1 , typename Vector2 > | |
void | slip::read_tecplot_XY (const std::string &file_path_name, Vector1 &X, Vector2 &Y) |
Reads X and Y column of an ASCII 2d tecplot file. More... | |
template<class MultiContainer2d > | |
void | slip::read_gnuplot_vect2d (const std::string &file_path_name, MultiContainer2d &field) |
Create a DenseVector2dField2D from a gnuplot file. More... | |
template<class MultiContainer2d , typename T > | |
void | slip::read_gnuplot_vect2d (const std::string &file_path_name, MultiContainer2d &field, slip::Point2d< T > &init_point, slip::Point2d< T > &step) |
Create a DenseVector2dField2D from a gnuplot file handle 2d real regular grid. More... | |
template<typename MultiContainer2d > | |
void | slip::read_gnuplot_XY (const std::string &file_path_name, MultiContainer2d &XY) |
Create a XY DenseVector2dField2D from a gnuplot file. More... | |
template<typename Vector1 , typename Vector2 > | |
void | slip::read_gnuplot_XY (const std::string &file_path_name, Vector1 &X, Vector2 &Y) |
Read X and Y column of a 2d gnuplot ASCII file. More... | |
3d vector fields input/output | |
template<typename DenseVector3dField3d > | |
void | slip::write_tecplot_vect3d (const DenseVector3dField3d &field, const std::string &file_path_name, const std::string &title, const std::string &zone, const int precision=6) |
Write a DenseVector3dField3D to a tecplot file. More... | |
template<typename DenseVector3dField3d , typename T > | |
void | slip::write_tecplot_vect3d (const DenseVector3dField3d &field, const slip::Point3d< T > &init_point, const slip::Point3d< T > &step, const std::string &file_path_name, const std::string &title, const std::string &zone, const int precision=6) |
Write a DenseVector3dField3D to a tecplot file handle 3d real regular grid. More... | |
template<class MultiContainer3d > | |
void | slip::read_tecplot_vect3d (const std::string &file_path_name, MultiContainer3d &field) |
Create a DenseVector3dField3D from a tecplot file. More... | |
template<class MultiContainer3d , typename T > | |
void | slip::read_tecplot_vect3d (const std::string &file_path_name, MultiContainer3d &field, slip::Point3d< T > &init_point, slip::Point3d< T > &step) |
Create a DenseVector3dField3D from a tecplot file handle 3d real regular grid. More... | |
template<class MultiContainer3d > | |
void | slip::read_tecplot_XYZ (const std::string &file_path_name, MultiContainer3d &XYZ) |
Create a XYZ DenseVector3dField3D from a tecplot file. More... | |
template<class Vector1 , class Vector2 , class Vector3 > | |
void | slip::read_tecplot_XYZ (const std::string &file_path_name, Vector1 &X, Vector2 &Y, Vector3 &Z) |
Create a XYZ DenseVector3dField3D from a tecplot file. More... | |
template<class MultiContainer3d > | |
void | slip::read_gnuplot_XYZ (const std::string &file_path_name, MultiContainer3d &XYZ) |
Create a XYZ DenseVector3dField3D from a gnuplot file. More... | |
1d ASCII containers input/output | |
template<typename InputIterator , typename WriteType > | |
void | slip::write_ascii_1d (InputIterator first, InputIterator last, const std::string &file_path_name) |
Write a Container1d to an ASCII file. More... | |
template<typename Container1d > | |
void | slip::read_ascii_1d (const std::string &file_path_name, Container1d &container) |
Read a Container1d from an ASCII file. More... | |
container3d (volume) input/output | |
template<typename Container3d > | |
void | slip::write_tecplot_vol (const Container3d &container, const std::string &file_path_name, const std::string &title) |
Write a Container3D to a tecplot file. More... | |
template<typename Container3d > | |
void | slip::write_to_images_tecplot (Container3d &container, const std::string &file_path_name, const std::string &title, const std::size_t from, const std::size_t to) |
Write slices of a Container3D to a tecplot file. More... | |