Main Page | Files | Data Structures | Functions | Global Variables |
gpiv-io.h File Reference

module for input/output. More...

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

Go to the source code of this file.

Macros

#define GPIV_PIV_FMT   "%4.0f %4.0f %12.3f %12.3f %12.3f %2d\n"
 Piv data Format. More...
 
#define GPIV_PIV_S_FMT   "%-12.5f %-12.5f %-12.5f %-12.5f %-6.2f %-2d\n"
 Piv scaled data Format. More...
 
#define GPIV_SCALAR_FMT   "%4.0f %4.0f %12.3f %2d\n"
 Scalar data Format with PIV data positions. More...
 
#define GPIV_SCALAR_S_FMT   "%-12.3f %-12.3f %-12.3f %-2d\n"
 Scalar data Format with PIV scaled data positions. More...
 
#define GPIV_EXT_HEADER   ".h"
 Extension of image header file name. More...
 
#define GPIV_EXT_RAW_IMAGE   ".r"
 Extension of raw image file name. More...
 
#define GPIV_EXT_PNG_IMAGE   ".png"
 Extension of png (Portable Network Graphics) formatted image file name. More...
 
#define GPIV_EXT_PNG_IMAGE_UPCASE   ".PNG"
 Uppercase extension of png. More...
 
#define GPIV_EXT_PNG_IMAGE_PROC   "_proc.png"
 Extension of processed png image file name. More...
 
#define GPIV_EXT_PGM_IMAGE   ".pgm"
 Extension of raw portable graymap (pgm) image file name. More...
 
#define GPIV_EXT_PGM_IMAGE_UPCASE   ".PGM"
 Uppercase extension of pgm. More...
 
#define GPIV_EXT_RAW_IMAGE_PROC   "_proc.r"
 Extension of processed raw binary image file name. More...
 
#define GPIV_EXT_PAR   ".par"
 Extension of file with used parameters. More...
 
#define GPIV_EXT_TA   ".ta"
 Extension of time averaged file name. More...
 
#define GPIV_EXT_SUBSTR   ".substr"
 Extension of file name with substracted data. More...
 
#define GPIV_EXT_GPIV   ".h5"
 Extension of gpiv file name (HDF 5 format) More...
 
#define GPIV_EXT_GPIV_UPCASE   ".H5"
 Uppercase extension of gpiv file name (HDF 5 format) More...
 
#define GPIV_EXT_PIV   ".piv"
 Extension of piv file name (ASCII format) More...
 
#define GPIV_EXT_DAVIS   ".img"
 DaVis image format. More...
 
#define GPIV_EXT_DAVIS_UPCASE   ".IMG"
 Uppercase DaVis image format. More...
 
#define GPIV_EXT_COV   ".cov"
 Extension of covariance data. More...
 
#define GPIV_EXT_INT   ".int"
 Extension of interrogation area. More...
 
#define GPIV_EXT_OLD   ".old.piv"
 Extension of old displacements. More...
 
#define GPIV_EXT_ERR_PIV   ".err.piv"
 Extension of erroneous-corrected piv file name. More...
 
#define GPIV_EXT_ERR_STAT   ".stat"
 Extension of residu statistics. More...
 
#define GPIV_EXT_PLK   ".plk"
 Extension of peaklocking output. More...
 
#define GPIV_EXT_UVHISTO   ".pdf"
 Extension of displacement histogram. More...
 
#define GPIV_EXT_VOR   ".vor"
 Extension of vorticity strain file name (ASCII format) More...
 
#define GPIV_EXT_NSTR   ".nstr"
 Extension of normal strain file name (ASCII format) More...
 
#define GPIV_EXT_SSTR   ".sstr"
 Extension of shear strain file name (ASCII format) More...
 
#define GPIV_EXT_MANI   ".ma.piv"
 Extension of manipulated file name (ASCII format) More...
 
#define GPIV_EXT_SA   ".sa.piv"
 Extension of spatial averaged file name (ASCII format) More...
 
#define GPIV_EXT_SC   ".sc.piv"
 Extension of scaled data file name (ASCII format) More...
 
#define GPIV_DAVIS_IMG_DEPTH   12
 Depth of mages generated by LaVision's Davis (general: PCO cameras) More...
 
#define GPIV_IMG_PARAM_RESOURCES
 As x_corr and depth are required to read properly the gpiv_image but may not necesarraly be present in the header for some image formats under specific situations, it is obtained from the parameter resources. More...
 

Enumerations

enum  GpivDataFormat { GPIV_RR = 1, GPIV_DAV = 2 }
 

Functions

void gpiv_io_make_fname (const gchar *fname_base, const gchar *EXT, gchar *fname_out)
 Constructs (output) filename from base name and extension. More...
 
GpivImagegpiv_read_image (FILE *fp)
 Reads image from fp. More...
 
GpivImagegpiv_fread_image (const gchar *fname)
 Reads image from file fname. More...
 
enum GpivDataFormat gpiv_find_pivdata_origin (const gchar line[GPIV_MAX_CHARS])
 Determines the name of the program that generated the data. More...
 
GpivPivDatagpiv_fread_pivdata (const gchar *fname)
 Reads PIV data from file fname. More...
 
gchar * gpiv_fwrite_pivdata (const gchar *fname, GpivPivData *piv_data, const gboolean free)
 Writes PIV data to file fname in ASCII format. More...
 
GpivPivDatagpiv_read_pivdata (FILE *fp)
 Reads PIV data from fp. More...
 
GpivPivDatagpiv_read_pivdata_fastx (FILE *fp)
 Reads PIV data from fp with fast running x-position variables. More...
 
gchar * gpiv_write_pivdata (FILE *fp, GpivPivData *piv_data, const gboolean free)
 Writes PIV data to fp in ASCII format. More...
 
GpivScalarDatagpiv_fread_scdata (const gchar *fname)
 Reads scalar data from file fname. More...
 
gchar * gpiv_fwrite_scdata (const gchar *fname, GpivScalarData *scalar_data, const gboolean free)
 Writes scalar data to file fname in ASCII format. More...
 
GpivScalarDatagpiv_read_scdata (FILE *fp)
 Reads scalar data form ascii file. More...
 
gchar * gpiv_write_scdata (FILE *fp, GpivScalarData *scalar_data, const gboolean free)
 Writes scalar data to file. More...
 
gchar * gpiv_write_sc_griddata (FILE *fp, GpivScalarData *scalar_data, const gboolean free)
 Writes scalar data to file in grid format for gnuplot. More...
 
gchar * gpiv_write_sc_mtvgriddata (FILE *fp, GpivScalarData *scalar_data, const gboolean free)
 Writes scalar data to file in grid format for plotmtv. More...
 
gchar * gpiv_print_histo (FILE *fp, GpivBinData *bin_data, const gboolean free)
 Writes bins data to file in histogram format. More...
 
gchar * gpiv_print_cumhisto_eqdatbin (FILE *fp, GpivBinData *klass, const gboolean free)
 Writing cumulative histogram data with an equal number of date per bin or klass to fp. More...
 
GpivImagegpiv_read_raw_image (FILE *fp)
 Reads an image from raw binary file. More...
 
GpivImagegpiv_fread_raw_image (const gchar *fname)
 Reads an image from raw binary file. More...
 
gchar * gpiv_write_raw_image (FILE *fp, GpivImage *gpiv_image)
 Writes raw binary image frames to fp. More...
 
gchar * gpiv_fwrite_raw_image (const gchar *fname, GpivImage *gpiv_image)
 Writes raw binary image data to file.r and header to file.h. More...
 
GpivImagegpiv_read_png_image (FILE *fp)
 Reads png formatted image. More...
 
gchar * gpiv_write_png_image (FILE *fp, GpivImage *gpiv_image, const gboolean free)
 Writes image data and header to png formatted image. More...
 
gchar * gpiv_fcreate_hdf5 (const gchar *fname)
 Creates an hdf5 data file with POSITION, DATA and PARAMETERS groups. More...
 
gchar * gpiv_fread_hdf5_parameters (const gchar *fname, const gchar *par_key, void *pstruct)
 Reads parameters from hdf5 data file. More...
 
GpivImagegpiv_fread_hdf5_image (const gchar *fname)
 Reads image data to a hdf5 data file. More...
 
gchar * gpiv_fwrite_hdf5_image (const gchar *fname, GpivImage *image, const gboolean free)
 Writes image data to file in hdf version 5 format. More...
 
gchar * gpiv_fwrite_hdf5_parameters (const gchar *fname, const gchar *par_key, void *pstruct)
 Writes parameters to hdf5 data file. More...
 
GpivPivDatagpiv_fread_hdf5_pivdata (const gchar *fname, const gchar *DATA_KEY)
 Reads piv data from hdf5 data file. More...
 
gchar * gpiv_fwrite_hdf5_pivdata (const gchar *fname, GpivPivData *piv_data, const gchar *DATA_KEY, const gboolean free)
 Writes PIV data to file in hdf version 5 format. More...
 
GpivScalarDatagpiv_fread_hdf5_scdata (const gchar *fname, const gchar *DATA_KEY)
 Reads SCALAR data from a hdf5 data file. More...
 
gchar * gpiv_fwrite_hdf5_scdata (const gchar *fname, GpivScalarData *scalar_data, const gchar *DATA_KEY, const gboolean free)
 Writes SCALAR data to a file in hdf version 5 format. More...
 
gchar * gpiv_fread_hdf5_histo (const gchar *fname, GpivBinData *klass, const gchar *DATA_KEY)
 Reads histogram data to ouput file in hdf version 5 format. More...
 
gchar * gpiv_fwrite_hdf5_histo (const gchar *fname, const GpivBinData *klass, const gchar *DATA_KEY)
 Writes histogram data to ouput file in hdf version 5 format. More...
 
GpivImagegpiv_read_davis_image (FILE *fp)
 Reads Davis formatted image, with ext .IMG from file. More...
 

Detailed Description

module for input/output.

SOURCES: lib/io.c, lib/io_hdf.c lib/io_image.c lib/io_png.c lib/io_raw.c

LAST MODIFICATION DATE:

Id
gpiv-io.h,v 1.3 2008-05-07 08:24:44 gerber Exp

Definition in file gpiv-io.h.

Macro Definition Documentation

◆ GPIV_DAVIS_IMG_DEPTH

#define GPIV_DAVIS_IMG_DEPTH   12

Depth of mages generated by LaVision's Davis (general: PCO cameras)

Definition at line 135 of file gpiv-io.h.

◆ GPIV_EXT_COV

#define GPIV_EXT_COV   ".cov"

Extension of covariance data.

Definition at line 117 of file gpiv-io.h.

◆ GPIV_EXT_DAVIS

#define GPIV_EXT_DAVIS   ".img"

DaVis image format.

Definition at line 115 of file gpiv-io.h.

◆ GPIV_EXT_DAVIS_UPCASE

#define GPIV_EXT_DAVIS_UPCASE   ".IMG"

Uppercase DaVis image format.

Definition at line 116 of file gpiv-io.h.

◆ GPIV_EXT_ERR_PIV

#define GPIV_EXT_ERR_PIV   ".err.piv"

Extension of erroneous-corrected piv file name.

Definition at line 121 of file gpiv-io.h.

◆ GPIV_EXT_ERR_STAT

#define GPIV_EXT_ERR_STAT   ".stat"

Extension of residu statistics.

Definition at line 122 of file gpiv-io.h.

◆ GPIV_EXT_GPIV

#define GPIV_EXT_GPIV   ".h5"

Extension of gpiv file name (HDF 5 format)

Definition at line 112 of file gpiv-io.h.

◆ GPIV_EXT_GPIV_UPCASE

#define GPIV_EXT_GPIV_UPCASE   ".H5"

Uppercase extension of gpiv file name (HDF 5 format)

Definition at line 113 of file gpiv-io.h.

◆ GPIV_EXT_HEADER

#define GPIV_EXT_HEADER   ".h"

Extension of image header file name.

Definition at line 99 of file gpiv-io.h.

◆ GPIV_EXT_INT

#define GPIV_EXT_INT   ".int"

Extension of interrogation area.

Definition at line 118 of file gpiv-io.h.

◆ GPIV_EXT_MANI

#define GPIV_EXT_MANI   ".ma.piv"

Extension of manipulated file name (ASCII format)

Definition at line 129 of file gpiv-io.h.

◆ GPIV_EXT_NSTR

#define GPIV_EXT_NSTR   ".nstr"

Extension of normal strain file name (ASCII format)

Definition at line 127 of file gpiv-io.h.

◆ GPIV_EXT_OLD

#define GPIV_EXT_OLD   ".old.piv"

Extension of old displacements.

Definition at line 119 of file gpiv-io.h.

◆ GPIV_EXT_PAR

#define GPIV_EXT_PAR   ".par"

Extension of file with used parameters.

Definition at line 107 of file gpiv-io.h.

◆ GPIV_EXT_PGM_IMAGE

#define GPIV_EXT_PGM_IMAGE   ".pgm"

Extension of raw portable graymap (pgm) image file name.

Definition at line 104 of file gpiv-io.h.

◆ GPIV_EXT_PGM_IMAGE_UPCASE

#define GPIV_EXT_PGM_IMAGE_UPCASE   ".PGM"

Uppercase extension of pgm.

Definition at line 105 of file gpiv-io.h.

◆ GPIV_EXT_PIV

#define GPIV_EXT_PIV   ".piv"

Extension of piv file name (ASCII format)

Definition at line 114 of file gpiv-io.h.

◆ GPIV_EXT_PLK

#define GPIV_EXT_PLK   ".plk"

Extension of peaklocking output.

Definition at line 123 of file gpiv-io.h.

◆ GPIV_EXT_PNG_IMAGE

#define GPIV_EXT_PNG_IMAGE   ".png"

Extension of png (Portable Network Graphics) formatted image file name.

Definition at line 101 of file gpiv-io.h.

◆ GPIV_EXT_PNG_IMAGE_PROC

#define GPIV_EXT_PNG_IMAGE_PROC   "_proc.png"

Extension of processed png image file name.

Definition at line 103 of file gpiv-io.h.

◆ GPIV_EXT_PNG_IMAGE_UPCASE

#define GPIV_EXT_PNG_IMAGE_UPCASE   ".PNG"

Uppercase extension of png.

Definition at line 102 of file gpiv-io.h.

◆ GPIV_EXT_RAW_IMAGE

#define GPIV_EXT_RAW_IMAGE   ".r"

Extension of raw image file name.

Definition at line 100 of file gpiv-io.h.

◆ GPIV_EXT_RAW_IMAGE_PROC

#define GPIV_EXT_RAW_IMAGE_PROC   "_proc.r"

Extension of processed raw binary image file name.

Definition at line 106 of file gpiv-io.h.

◆ GPIV_EXT_SA

#define GPIV_EXT_SA   ".sa.piv"

Extension of spatial averaged file name (ASCII format)

Definition at line 130 of file gpiv-io.h.

◆ GPIV_EXT_SC

#define GPIV_EXT_SC   ".sc.piv"

Extension of scaled data file name (ASCII format)

Definition at line 131 of file gpiv-io.h.

◆ GPIV_EXT_SSTR

#define GPIV_EXT_SSTR   ".sstr"

Extension of shear strain file name (ASCII format)

Definition at line 128 of file gpiv-io.h.

◆ GPIV_EXT_SUBSTR

#define GPIV_EXT_SUBSTR   ".substr"

Extension of file name with substracted data.

Definition at line 110 of file gpiv-io.h.

◆ GPIV_EXT_TA

#define GPIV_EXT_TA   ".ta"

Extension of time averaged file name.

Definition at line 109 of file gpiv-io.h.

◆ GPIV_EXT_UVHISTO

#define GPIV_EXT_UVHISTO   ".pdf"

Extension of displacement histogram.

Definition at line 124 of file gpiv-io.h.

◆ GPIV_EXT_VOR

#define GPIV_EXT_VOR   ".vor"

Extension of vorticity strain file name (ASCII format)

Definition at line 126 of file gpiv-io.h.

◆ GPIV_IMG_PARAM_RESOURCES

#define GPIV_IMG_PARAM_RESOURCES

As x_corr and depth are required to read properly the gpiv_image but may not necesarraly be present in the header for some image formats under specific situations, it is obtained from the parameter resources.

Definition at line 136 of file gpiv-io.h.

◆ GPIV_PIV_FMT

#define GPIV_PIV_FMT   "%4.0f %4.0f %12.3f %12.3f %12.3f %2d\n"

Piv data Format.

Definition at line 94 of file gpiv-io.h.

◆ GPIV_PIV_S_FMT

#define GPIV_PIV_S_FMT   "%-12.5f %-12.5f %-12.5f %-12.5f %-6.2f %-2d\n"

Piv scaled data Format.

Definition at line 95 of file gpiv-io.h.

◆ GPIV_SCALAR_FMT

#define GPIV_SCALAR_FMT   "%4.0f %4.0f %12.3f %2d\n"

Scalar data Format with PIV data positions.

Definition at line 96 of file gpiv-io.h.

◆ GPIV_SCALAR_S_FMT

#define GPIV_SCALAR_S_FMT   "%-12.3f %-12.3f %-12.3f %-2d\n"

Scalar data Format with PIV scaled data positions.

Definition at line 97 of file gpiv-io.h.

Enumeration Type Documentation

◆ GpivDataFormat

Enumerator
GPIV_RR 
GPIV_DAV 

Definition at line 148 of file gpiv-io.h.

Function Documentation

◆ gpiv_fcreate_hdf5()

gchar* gpiv_fcreate_hdf5 ( const gchar *  fname)

Creates an hdf5 data file with POSITION, DATA and PARAMETERS groups.

Parameters
[in]fnamepointer to complete filename
Returns
NULL on success or error message on failure

◆ gpiv_find_pivdata_origin()

enum GpivDataFormat gpiv_find_pivdata_origin ( const gchar  line[GPIV_MAX_CHARS])

Determines the name of the program that generated the data.

Parameters
[in]linecharacter line containing program that generated data
Returns
pdf enumerator of data origin

◆ gpiv_fread_hdf5_histo()

gchar* gpiv_fread_hdf5_histo ( const gchar *  fname,
GpivBinData klass,
const gchar *  DATA_KEY 
)

Reads histogram data to ouput file in hdf version 5 format.

Parameters
[in]fnamepointer to complete filename
[in]klassstruct bin containing the values for each bin
[in]DATA_KEYidentifier of data type (PEAK_LOCK, RESIDUS, ...)
Returns
NULL on success or error message on failure

◆ gpiv_fread_hdf5_image()

GpivImage* gpiv_fread_hdf5_image ( const gchar *  fname)

Reads image data to a hdf5 data file.

Parameters
[in]fnamepointer to complete filename
Returns
GpivImage on success or NULL on failure

◆ gpiv_fread_hdf5_parameters()

gchar* gpiv_fread_hdf5_parameters ( const gchar *  fname,
const gchar *  par_key,
void *  pstruct 
)

Reads parameters from hdf5 data file.

Parameters
[in]fnamepointer to complete filename
[in]par_keykey for apropiate parameter
[out]pstructparameter structure
Returns
NULL on success or error message on failure

◆ gpiv_fread_hdf5_pivdata()

GpivPivData* gpiv_fread_hdf5_pivdata ( const gchar *  fname,
const gchar *  DATA_KEY 
)

Reads piv data from hdf5 data file.

Parameters
[in]fnamepointer to complete filename
[in]DATA_KEYlocation of the data in the DATA group in the hdf file
Returns
GpivPivData or NULL on failure

◆ gpiv_fread_hdf5_scdata()

GpivScalarData* gpiv_fread_hdf5_scdata ( const gchar *  fname,
const gchar *  DATA_KEY 
)

Reads SCALAR data from a hdf5 data file.

Parameters
[in]fnamepointer to complete filename
[in]DATA_KEYkey to specify data type/origin (NORMAL_STRAIN, ...)
Returns
GpivScalarData or NULL on failure

◆ gpiv_fread_image()

GpivImage* gpiv_fread_image ( const gchar *  fname)

Reads image from file fname.

Parameters
[in]fnamecomplete filename. This is used to pick the image format loader. Eventually checking the format signature is done in the loader itself
Returns
GpivImage or NULL on failure

◆ gpiv_fread_pivdata()

GpivPivData* gpiv_fread_pivdata ( const gchar *  fname)

Reads PIV data from file fname.

Parameters
[in]fnamecomplete input filename.
Returns
GpivPivData or NULL on failure

◆ gpiv_fread_raw_image()

GpivImage* gpiv_fread_raw_image ( const gchar *  fname)

Reads an image from raw binary file.

Expects the arrray(s) have not been allocated yet. Reads image data from file.r, header from file.h Eventually, required header info will be read from (system) resources gpiv.conf or $HOME/.gpivrc.

Parameters
[in]fnamecomplete image filename (ending on .r)
Returns
GpivImage on success or NULL on failure

◆ gpiv_fread_scdata()

GpivScalarData* gpiv_fread_scdata ( const gchar *  fname)

Reads scalar data from file fname.

Parameters
[in]fnamecomplete input filename.
Returns
GpivScalarData or NULL on failure

◆ gpiv_fwrite_hdf5_histo()

gchar* gpiv_fwrite_hdf5_histo ( const gchar *  fname,
const GpivBinData klass,
const gchar *  DATA_KEY 
)

Writes histogram data to ouput file in hdf version 5 format.

Parameters
[in]fnamepointer to complete filename
[in]klassstruct bin containing the values for each bin
[in]DATA_KEYidentifier of data type (PEAK_LOCK, RESIDUS, ...)
Returns
NULL on success or error message on failure

◆ gpiv_fwrite_hdf5_image()

gchar* gpiv_fwrite_hdf5_image ( const gchar *  fname,
GpivImage image,
const gboolean  free 
)

Writes image data to file in hdf version 5 format.

Parameters
[in]fnamepointer to complete filename
[in]imageimage frkames and header
[in]freeboolean whether to free memory of image arrays
Returns
NULL on success or error message on failure

◆ gpiv_fwrite_hdf5_parameters()

gchar* gpiv_fwrite_hdf5_parameters ( const gchar *  fname,
const gchar *  par_key,
void *  pstruct 
)

Writes parameters to hdf5 data file.

Parameters
[in]fnamepointer to complete filename
[in]par_keykey for apropiate parameter
[in]pstructparameter structure
Returns
NULL on success or error message on failure

◆ gpiv_fwrite_hdf5_pivdata()

gchar* gpiv_fwrite_hdf5_pivdata ( const gchar *  fname,
GpivPivData piv_data,
const gchar *  DATA_KEY,
const gboolean  free 
)

Writes PIV data to file in hdf version 5 format.

Parameters
[in]fnamepointer to complete filename
[in]piv_datapiv data containing all variables in a datafile
[in]DATA_KEYlocation of the data in the DATA group in the hdf file
[in]freeboolean whether to free memory of PIV data
Returns
NULL on success or error message on failure

◆ gpiv_fwrite_hdf5_scdata()

gchar* gpiv_fwrite_hdf5_scdata ( const gchar *  fname,
GpivScalarData scalar_data,
const gchar *  DATA_KEY,
const gboolean  free 
)

Writes SCALAR data to a file in hdf version 5 format.

Parameters
[in]fnamepointer to complete filename
[in]scalar_datastruct GpivScalarData containing all variables in a datafile
[in]DATA_KEYidentifier of data type
[in]freeboolean whether to free memory of SCALAR data
Returns
NULL on success or error message on failure

◆ gpiv_fwrite_pivdata()

gchar* gpiv_fwrite_pivdata ( const gchar *  fname,
GpivPivData piv_data,
const gboolean  free 
)

Writes PIV data to file fname in ASCII format.

Parameters
[in]piv_dataPIV data
[in]fnamecomplete output filename.
[in]freeflag if allocated memory if piv_data will be freed
Returns
NULL on success or error message on failure

◆ gpiv_fwrite_raw_image()

gchar* gpiv_fwrite_raw_image ( const gchar *  fname,
GpivImage gpiv_image 
)

Writes raw binary image data to file.r and header to file.h.

Parameters
[in]fnamecomplete image filename (ending on .r)
[in]gpiv_imageimage frames and header info
Returns
NULL on success or error message on failure

◆ gpiv_fwrite_scdata()

gchar* gpiv_fwrite_scdata ( const gchar *  fname,
GpivScalarData scalar_data,
const gboolean  free 
)

Writes scalar data to file fname in ASCII format.

Parameters
[in]scalar_datascalar data
[in]fnamecomplete output filename.
[in]freeflag if allocated memory if piv_data will be freed
Returns
NULL on success or error message on failure

◆ gpiv_io_make_fname()

void gpiv_io_make_fname ( const gchar *  fname_base,
const gchar *  EXT,
gchar *  fname_out 
)

Constructs (output) filename from base name and extension.

Parameters
[in]fname_basefile base name
[in]EXTfile extension name
[out]fname_outcompleted filename
Returns
void

◆ gpiv_print_cumhisto_eqdatbin()

gchar* gpiv_print_cumhisto_eqdatbin ( FILE *  fp,
GpivBinData klass,
const gboolean  free 
)

Writing cumulative histogram data with an equal number of date per bin or klass to fp.

Special output for validation; work around to print float data as y-values.

Parameters
[in]fpoutput file
[in]klassstruct GpivBinData containing the values for each bin
[in]freeflag if allocated memory if scalar_data will be freed
Returns
NULL on success or error message on failure

◆ gpiv_print_histo()

gchar* gpiv_print_histo ( FILE *  fp,
GpivBinData bin_data,
const gboolean  free 
)

Writes bins data to file in histogram format.

Parameters
[in]fpoutput file. If NULL, stdout is used.
[in]bin_datadata containing the values for each bin
[in]freeflag if allocated memory if scalar_data will be freed
Returns
NULL on success or error message on failure

◆ gpiv_read_davis_image()

GpivImage* gpiv_read_davis_image ( FILE *  fp)

Reads Davis formatted image, with ext .IMG from file.

Parameters
[in]fppointer to input file
Returns
GpivImage on success or NULL on failure

◆ gpiv_read_image()

GpivImage* gpiv_read_image ( FILE *  fp)

Reads image from fp.

Image will have to be png formatted.

Parameters
[in]fpfile pointer. If NULL, stdin will be used.
Returns
pointer to GpivImage

◆ gpiv_read_pivdata()

GpivPivData* gpiv_read_pivdata ( FILE *  fp)

Reads PIV data from fp.

Parameters
[in]fpinput file. If NULL, stdin is used.
Returns
GpivPivData

◆ gpiv_read_pivdata_fastx()

GpivPivData* gpiv_read_pivdata_fastx ( FILE *  fp)

Reads PIV data from fp with fast running x-position variables.

(1st column in data stream)

Parameters
[in]fpinput file. If NULL, stdin is used.
Returns
GpivPivData

◆ gpiv_read_png_image()

GpivImage* gpiv_read_png_image ( FILE *  fp)

Reads png formatted image.

Parameters
[in]fpfile pointer
Returns
pointer to GpivImage

◆ gpiv_read_raw_image()

GpivImage* gpiv_read_raw_image ( FILE *  fp)

Reads an image from raw binary file.

Expects the arrray (s) have not been allocated yet. Eventually, required header info will be read from (system) resources gpiv.conf or $HOME/.gpivrc.

Parameters
[in]fpinput file. If NULL, stdin will be used
Returns
GpivImage on success or NULL on failure

◆ gpiv_read_scdata()

GpivScalarData* gpiv_read_scdata ( FILE *  fp)

Reads scalar data form ascii file.

Parameters
[in]fpinput file. If NULL, stin is used.
Returns
GpivScalarData or NULL on failure

◆ gpiv_write_pivdata()

gchar* gpiv_write_pivdata ( FILE *  fp,
GpivPivData piv_data,
const gboolean  free 
)

Writes PIV data to fp in ASCII format.

Parameters
[in]piv_dataPIV data
[in]fpoutput file. If NULL, stout is used.
[in]freeflag if allocated memory if piv_data will be freed
Returns
NULL on success or error message on failure

◆ gpiv_write_png_image()

gchar* gpiv_write_png_image ( FILE *  fp,
GpivImage gpiv_image,
const gboolean  free 
)

Writes image data and header to png formatted image.

Optionally frees allocated memory.

Parameters
[in]fpoutput file.
[in]gpiv_imageimage header and data
[in]freeboolean whether to free memory of image arrays
Returns
NULL on success or error message on failure

◆ gpiv_write_raw_image()

gchar* gpiv_write_raw_image ( FILE *  fp,
GpivImage gpiv_image 
)

Writes raw binary image frames to fp.

Parameters
[in]fpoutput file. If NULL, stdout will be used
[in]gpiv_imageimage frames and header
Returns
NULL on success or error message on failure

◆ gpiv_write_sc_griddata()

gchar* gpiv_write_sc_griddata ( FILE *  fp,
GpivScalarData scalar_data,
const gboolean  free 
)

Writes scalar data to file in grid format for gnuplot.

Parameters
[in]fpoutput file. If NULL, stdout is used.
[in]scalar_datascalar data containing all variables in a datafile
[in]freeflag if allocated memory if scalar_data will be freed
Returns
NULL on success or error message on failure

◆ gpiv_write_sc_mtvgriddata()

gchar* gpiv_write_sc_mtvgriddata ( FILE *  fp,
GpivScalarData scalar_data,
const gboolean  free 
)

Writes scalar data to file in grid format for plotmtv.

Parameters
[in]fpoutput file. If NULL, stdout is used.
[in]scalar_datascalar data containing all variables in a datafile
[in]freeflag if allocated memory if scalar_data will be freed
Returns
NULL on success or error message on failure

◆ gpiv_write_scdata()

gchar* gpiv_write_scdata ( FILE *  fp,
GpivScalarData scalar_data,
const gboolean  free 
)

Writes scalar data to file.

Parameters
[in]fpoutput file. If NULL, stout is used.
[in]scalar_datascalar data containing all variables in a datafile
[in]freeflag if allocated memory if scalar_data will be freed
Returns
NULL on success or error message on failure

Generated for libgpiv-0.6.1 by doxygen 1.8.13