module for image header en parameters More...
Go to the source code of this file.
Data Structures | |
struct | __GpivImagePar |
Image parameters or header info. More... | |
struct | __GpivImage |
Piv image header and data. More... | |
Typedefs | |
typedef struct __GpivImagePar | GpivImagePar |
typedef struct __GpivImage | GpivImage |
Functions | |
void | gpiv_img_parameters_set (GpivImagePar *image_par, const gboolean flag) |
Sets flag for image_par__set. More... | |
GpivImagePar * | gpiv_img_get_parameters_from_resources (const gchar *localrc, const gboolean verbose) |
Reads image parameters from localrc, $HOME/.gpivrc and system-wide gpiv.conf. More... | |
void | gpiv_img_default_parameters (GpivImagePar *image_par, const gboolean force) |
Sets default parameter values. More... | |
void | gpiv_img_read_header (FILE *fp, GpivImagePar *image_par, const gboolean include_key, const gboolean verbose, FILE *fp_par_out) |
Reads each line of file fp and looks for image header parameters. More... | |
gchar * | gpiv_img_check_header_read (const GpivImagePar *image_par) |
Checks out if all image header info has been read. More... | |
gchar * | gpiv_img_check_header_required_read (const GpivImagePar *image_par) |
Checks out if the required image header info for reading/storing has been read. More... | |
gchar * | gpiv_img_check_header_scale_read (const GpivImagePar *image_par) |
Checks out if image header info for time/spatial scaling has been read. More... | |
gchar * | gpiv_img_test_header (const GpivImagePar *image_par) |
Checks out if all header parameters have been read. More... | |
void | gpiv_img_print_header (FILE *fp, const GpivImagePar *image_par) |
Prints header information to file fp. More... | |
void | gpiv_img_fprint_header (const gchar *fname, const GpivImagePar *image_par) |
Prints image header parameters to file. More... | |
GpivImagePar * | gpiv_img_cp_parameters (const GpivImagePar *image_par) |
Generate a new copy of image parameters from image_par if image_par_dest have not been set. More... | |
void | gpiv_img_ovwrt_parameters (const GpivImagePar *image_par_src, GpivImagePar *image_par_dest) |
Overwrites image parameters from image_par_src to image_par_dest. More... | |
void | gpiv_img_print_parameters (FILE *fp, const GpivImagePar *image_par) |
Prints image header or parameters to fp. More... | |
void | gpiv_img_fprint_parameters (const gchar *fname, const GpivImagePar *image_par) |
Prints image header or parameters to file. More... | |
GpivImagePar * | gpiv_img_fread_hdf5_parameters (const gchar *fname) |
Reads image parameters from hdf5 data file without IMAGE_PAR_KEY. More... | |
gchar * | gpiv_img_fwrite_hdf5_parameters (const gchar *fname, const GpivImagePar *image_par) |
Writes image parameters to an existing hdf5 data file. More... | |
gchar * | gpiv_img_fread_davis_parameters (const gchar *fname, GpivImagePar *image_par) |
Reads image specifications from Davis formatted image, with ext .IMG, from file. More... | |
module for image header en parameters
SOURCE: lib/img.c
LAST MODIFICATION DATE:
Definition in file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__AUTHOR "" |
Default parameter for author of __GpivImagePar.
Definition at line 77 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__COMMENT "" |
Default parameter for comment of __GpivImagePar.
Definition at line 83 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__COPYRIGHT "" |
Default parameter for copyright of __GpivImagePar.
Definition at line 84 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__CREATION_DATE "" |
Default parameter for creation_date of __GpivImagePar.
Definition at line 75 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__DEPTH 8 |
Default parameter for depth of __GpivImagePar.
Definition at line 65 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__DISCLAIMER "See The GNU General Public License (GPL)" |
Default parameter for disclaimer of __GpivImagePar.
Definition at line 82 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__EMAIL "" |
Default parameter for email of __GpivImagePar.
Definition at line 85 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__LOCATION "" |
Default parameter for location of __GpivImagePar.
Definition at line 76 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__NCOLUMNS 256 |
Default parameter for ncolumns of __GpivImagePar.
Definition at line 66 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__NROWS 256 |
Default parameter for nrows of __GpivImagePar.
Definition at line 67 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__S_SCALE 1.0 |
Default parameter for s_scale of __GpivImagePar.
Definition at line 69 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__SOFTWARE "gpiv / gpiv_rr" |
Default parameter for software of __GpivImagePar.
Definition at line 78 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__SOURCE "" |
Default parameter for source of __GpivImagePar.
Definition at line 79 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__T_SCALE 1.0 |
Default parameter for t_scale of __GpivImagePar.
Definition at line 70 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__TITLE "" |
Default parameter for title of __GpivImagePar.
Definition at line 74 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__URL "" |
Default parameter for url of __GpivImagePar.
Definition at line 86 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__USERTEXT "" |
Default parameter for usertext of __GpivImagePar.
Definition at line 80 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__WARNING "" |
Default parameter for warning of __GpivImagePar.
Definition at line 81 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__X_CORR 1 |
Default parameter for x_corr of __GpivImagePar.
Definition at line 68 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__Z_OFF_X 0.0 |
Default parameter for z_off_x of __GpivImagePar.
Definition at line 71 of file gpiv-img.h.
#define GPIV_IMGPAR_DEFAULT__Z_OFF_Y 0.0 |
Default parameter for z_off_y of __GpivImagePar.
Definition at line 72 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY "IMG" |
Key of image parameters.
Definition at line 89 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__AUTHOR "author" |
Key for author of __GpivImagePar.
Definition at line 102 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__COMMENT "comment" |
Key for comment of __GpivImagePar.
Definition at line 108 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__COPYRIGHT "copyright" |
Key for copyright of __GpivImagePar.
Definition at line 109 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__CREATION_DATE "creation_date" |
Key for creation_date of __GpivImagePar.
Definition at line 100 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__DEPTH "depth" |
Key for depth of __GpivImagePar.
Definition at line 90 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__DISCLAIMER "disclaimer" |
Key for disclaimer of __GpivImagePar.
Definition at line 107 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__EMAIL "email" |
Key for email of __GpivImagePar.
Definition at line 110 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__LOCATION "location" |
Key for location of __GpivImagePar.
Definition at line 101 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__NCOLUMNS "ncolumns" |
Key for ncolumns of __GpivImagePar.
Definition at line 91 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__NROWS "nrows" |
Key for nrows of __GpivImagePar.
Definition at line 92 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__S_SCALE "s_scale" |
Key for s_scale of __GpivImagePar.
Definition at line 94 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__SOFTWARE "software" |
Key for software of __GpivImagePar.
Definition at line 103 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__SOURCE "source" |
Key for source of __GpivImagePar.
Definition at line 104 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__T_SCALE "t_scale" |
Key for t_scale of __GpivImagePar.
Definition at line 95 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__TITLE "title" |
Key for title of __GpivImagePar.
Definition at line 99 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__URL "url" |
Key for url of __GpivImagePar.
Definition at line 111 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__USERTEXT "usertext" |
Key for usertext of __GpivImagePar.
Definition at line 105 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__WARNING "warning" |
Key for warning of __GpivImagePar.
Definition at line 106 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__X_CORR "x_corr" |
Key for x_corr of __GpivImagePar.
Definition at line 93 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__Z_OFF_X "zoff_x" |
Key for z_off_x of __GpivImagePar.
Definition at line 96 of file gpiv-img.h.
#define GPIV_IMGPAR_KEY__Z_OFF_Y "zoff_y" |
Key for z_off_y of __GpivImagePar.
Definition at line 97 of file gpiv-img.h.
typedef struct __GpivImage GpivImage |
Definition at line 188 of file gpiv-img.h.
typedef struct __GpivImagePar GpivImagePar |
Definition at line 113 of file gpiv-img.h.
gchar* gpiv_img_check_header_read | ( | const GpivImagePar * | image_par | ) |
Checks out if all image header info has been read.
[in] | image_par | image parameters |
gchar* gpiv_img_check_header_required_read | ( | const GpivImagePar * | image_par | ) |
Checks out if the required image header info for reading/storing has been read.
[in] | image_par | image parameters |
gchar* gpiv_img_check_header_scale_read | ( | const GpivImagePar * | image_par | ) |
Checks out if image header info for time/spatial scaling has been read.
[in] | image_par | image parameters |
GpivImagePar* gpiv_img_cp_parameters | ( | const GpivImagePar * | image_par | ) |
Generate a new copy of image parameters from image_par if image_par_dest have not been set.
[in] | image_par | source image parameters to be copied |
void gpiv_img_default_parameters | ( | GpivImagePar * | image_par, |
const gboolean | force | ||
) |
Sets default parameter values.
[in] | force | flag to enforce parameters set to defaults |
[out] | image_par | image parameters |
void gpiv_img_fprint_header | ( | const gchar * | fname, |
const GpivImagePar * | image_par | ||
) |
Prints image header parameters to file.
Identic to gpiv_img_fprint_parameters(), but without GPIV_IMGPAR_KEY
[in] | fname | header filename |
[in] | image_par | image parameters |
void gpiv_img_fprint_parameters | ( | const gchar * | fname, |
const GpivImagePar * | image_par | ||
) |
Prints image header or parameters to file.
Idententic to gpiv_img_fprint_header(), but includes IMAGE_PAR_KEY
[in] | fname | header filename |
[in] | image_par | image parameters |
gchar* gpiv_img_fread_davis_parameters | ( | const gchar * | fname, |
GpivImagePar * | image_par | ||
) |
Reads image specifications from Davis formatted image, with ext .IMG, from file.
[in] | fname | filename |
[out] | image_par | image parameters |
GpivImagePar* gpiv_img_fread_hdf5_parameters | ( | const gchar * | fname | ) |
Reads image parameters from hdf5 data file without IMAGE_PAR_KEY.
[in] | fname | filename |
gchar* gpiv_img_fwrite_hdf5_parameters | ( | const gchar * | fname, |
const GpivImagePar * | image_par | ||
) |
Writes image parameters to an existing hdf5 data file.
[in] | fname | filename |
[in] | image_par | image parameters |
GpivImagePar* gpiv_img_get_parameters_from_resources | ( | const gchar * | localrc, |
const gboolean | verbose | ||
) |
Reads image parameters from localrc, $HOME/.gpivrc and system-wide gpiv.conf.
[in] | localrc | resource filename containing parameter at current directory |
[in] | verbose | prints parameter values when read |
void gpiv_img_ovwrt_parameters | ( | const GpivImagePar * | image_par_src, |
GpivImagePar * | image_par_dest | ||
) |
Overwrites image parameters from image_par_src to image_par_dest.
[in] | image_par_src | source image parameters to be copied |
[in] | image_par_dest | the copied image parameters |
void gpiv_img_parameters_set | ( | GpivImagePar * | image_par, |
const gboolean | flag | ||
) |
Sets flag for image_par__set.
[in] | flag | flag to enforce parameters set to defaults |
[out] | image_par | image parameters |
void gpiv_img_print_header | ( | FILE * | fp, |
const GpivImagePar * | image_par | ||
) |
Prints header information to file fp.
Identic to gpiv_img_print_parameters(), but without GPIV_IMGPAR_KEY
[in] | fp | file pointer. If NULL, stdout will be used |
[in] | image_par | image parameters |
void gpiv_img_print_parameters | ( | FILE * | fp, |
const GpivImagePar * | image_par | ||
) |
Prints image header or parameters to fp.
Idententic to gpiv_img_print_header(), but includes IMAGE_PAR_KEY
[in] | fp | file pointer. If NULL, stdout will be used |
[in] | image_par | image parameters |
void gpiv_img_read_header | ( | FILE * | fp, |
GpivImagePar * | image_par, | ||
const gboolean | include_key, | ||
const gboolean | verbose, | ||
FILE * | fp_par_out | ||
) |
Reads each line of file fp and looks for image header parameters.
[in] | fp | file pointer to header or paremeter file. If NULL, stdin will be used. |
[in] | fp_par_out | file pointer of which parameter will have to be printed or NULL for stdout |
[in] | verbose | flag to print parameters to fp_par_out (TRUE) or not (FALSE) |
[in] | include_key | flag if module key is included |
[out] | image_par | image header parameters |
gchar* gpiv_img_test_header | ( | const GpivImagePar * | image_par | ) |
Checks out if all header parameters have been read.
[in] | image_par | image parameters |