Merge ../libgpiv-omp into fft-omp
[libgpiv.git] / lib / io.c
blobe10d425d3f233cb52ab77330ab7b0b48a8a6e9a3
1 /* -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 4 c-style: "K&R" -*- */
3 /*
4 libgpiv - library for Particle Image Velocimetry
6 Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008
7 Gerber van der Graaf
9 This file is part of libgpiv.
10 Libgpiv is free software; you can redistribute it and/or modify
11 it under the terms of the GNU General Public License as published by
12 the Free Software Foundation; either version 2, or (at your option)
13 any later version.
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License for more details.
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software Foundation,
22 Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
26 ---------------------------------------------------------------
27 FILENAME: io.c
28 LIBRARY: libgpiv:
29 EXTERNAL FUNCTIONS: gpiv_io_make_fname
31 gpiv_read_image
32 gpiv_fread_image
34 gpiv_find_pivdata_origin
35 gpiv_read_pivdata
36 gpiv_read_pivdata_fastx
37 gpiv_write_pivdata
39 gpiv_read_scdata
40 gpiv_write_scdata
42 gpiv_fwrite_griddata
43 gpiv_print_histo
44 gpiv_fprint_histo
47 LOCAL FUNCTIONS:
49 LAST MODIFICATION DATE: $Id: io.c,v 1.19 2008-09-25 13:19:53 gerber Exp $
50 --------------------------------------------------------------- */
52 #include <stdio.h>
53 #include <unistd.h>
54 #include <string.h>
55 #include <hdf5.h>
57 #include <gpiv.h>
60 static void
61 obtain_scdata_fromline (gchar line[],
62 GpivScalarData *piv_data,
63 guint *i,
64 guint *j
68 * Public functions
71 void
72 gpiv_io_make_fname (const gchar *fname_base,
73 const gchar *EXT,
74 gchar *fname_out
76 /*-----------------------------------------------------------------------------
77 * DESCRIPTION:
78 * Constructs (output) filename from base name and exetsion
80 * INPUTS:
81 * fname_base: file base name
82 * EXT: file extension name
83 * OUTPUTS:
84 * fname_out: completed filename
86 * RETURNS:
87 *---------------------------------------------------------------------------*/
89 g_snprintf(fname_out, GPIV_MAX_CHARS, "%s%s", fname_base, EXT);
96 * Local functions