I/O functions


Defines

#define it_assert(a, expr)   __it_assert((long)(a), "", 0, expr)

Functions

void it_vprintf (char *fmt, va_list args)
void it_fprintf (FILE *output, char *fmt,...)
void it_printf (char *fmt,...)
void it_vfprintf (FILE *output, char *fmt, va_list ap)
void it_warning (char *fmt,...)
void it_error (char *fmt,...)
void __it_assert (int a, const char *filename, int line, char *message)
void it_set_vec_default_fmt (char *fmt)
void it_set_mat_default_fmt (char *fmt)
char * it_read_int (char *s, int *p_val)
char * it_read_float (char *s, float *p_val)
char * it_read_double (char *s, double *p_val)
char * it_read_cplx (char *s, cplx *p_val)
char * it_read_vec (char *s, vec *v)
char * it_read_fvec (char *s, vec *v)
char * it_read_ivec (char *s, ivec *v)
char * it_read_bvec (char *s, bvec *v)
char * it_read_cvec (char *s, cvec *v)
char * it_read_mat (char *s, mat *m)
char * it_read_fmat (char *s, mat *m)
char * it_read_imat (char *s, imat *m)
char * it_read_bmat (char *s, bmat *m)
char * it_read_cmat (char *s, cmat *m)
vec vec_new_string (char *s)
vec fvec_new_string (char *s)
ivec ivec_new_string (char *s)
bvec bvec_new_string (char *s)
cvec cvec_new_string (char *s)
mat mat_new_string (char *s)
mat fmat_new_string (char *s)
imat imat_new_string (char *s)
bmat bmat_new_string (char *s)
cmat cmat_new_string (char *s)
char pnm_type (const char *filename)
int pnm_info (const char *filename, char *p_pnm_type, int *p_width, int *p_height, int *p_max_val, char *comments, int length)
mat mat_pgm_read (const char *filename)
imat imat_pgm_read (const char *filename)
int mat_pgm_write (const char *filename, mat m)
int imat_pgm_write (const char *filename, imat m)
int wav_info (const char *filename, int *p_channels, int *p_srate, int *p_depth, int *p_length)
mat mat_wav_read (const char *filename)
imat imat_wav_read (const char *filename)
void mat_wav_write (const char *filename, mat m, int srate, int depth)
void imat_wav_write (const char *filename, imat m, int srate, int depth)
void vec_fwrite (FILE *stream, vec v)
void fvec_fwrite (FILE *stream, vec v)
void bvec_fwrite (FILE *stream, bvec v)
void ivec_fwrite (FILE *stream, ivec v)
void cvec_fwrite (FILE *stream, cvec v)
int vec_fread (FILE *stream, vec v)
int fvec_fread (FILE *stream, vec v)
int bvec_fread (FILE *stream, bvec v)
int ivec_fread (FILE *stream, ivec v)
int cvec_fread (FILE *stream, cvec v)
vec vec_new_fread (FILE *stream)
vec fvec_new_fread (FILE *stream)
bvec bvec_new_fread (FILE *stream)
ivec ivec_new_fread (FILE *stream)
cvec cvec_new_fread (FILE *stream)
void mat_fwrite (FILE *stream, mat m)
void fmat_fwrite (FILE *stream, mat m)
void bmat_fwrite (FILE *stream, bmat m)
void imat_fwrite (FILE *stream, imat m)
void cmat_fwrite (FILE *stream, cmat m)
int vec_sread (void *buffer, vec v)
int fvec_sread (void *buffer, vec v)
int ivec_sread (void *buffer, ivec v)
mat mat_new_fread (FILE *stream)
bmat bmat_new_fread (FILE *stream)
imat imat_new_fread (FILE *stream)
cmat cmat_new_fread (FILE *stream)
bvec bvec_file_read_bits (const char *filename, int nb_max)
void bvec_file_write_bits (const char *filename, bvec v)

Detailed Description


Define Documentation


Function Documentation

void __it_assert ( int  a,
const char *  filename,
int  line,
char *  message 
)

Definition at line 108 of file io.c.

void bmat_fwrite ( FILE *  stream,
bmat  m 
)

Definition at line 2114 of file io.c.

References bmat_height(), and bmat_width().

bmat bmat_new_fread ( FILE *  stream  ) 

Definition at line 2225 of file io.c.

References bmat_new().

bmat bmat_new_string ( char *  s  ) 

Definition at line 1161 of file io.c.

References bmat_new_alloc(), it_error(), and it_read_bmat().

bvec bvec_file_read_bits ( const char *  filename,
int  nb_max 
)

Definition at line 2288 of file io.c.

References bvec_delete(), bvec_length(), bvec_new(), and it_error().

Referenced by main().

void bvec_file_write_bits ( const char *  filename,
bvec  v 
)

Definition at line 2329 of file io.c.

References bvec_delete(), bvec_length(), bvec_new_zeros(), and it_error().

Referenced by main().

int bvec_fread ( FILE *  stream,
bvec  v 
)

Definition at line 1924 of file io.c.

References bvec_length().

void bvec_fwrite ( FILE *  stream,
bvec  v 
)

Definition at line 1814 of file io.c.

References bvec_length().

bvec bvec_new_fread ( FILE *  stream  ) 

Definition at line 2010 of file io.c.

References bvec_new().

bvec bvec_new_string ( char *  s  ) 

Definition at line 1097 of file io.c.

References bvec_new_alloc(), it_error(), and it_read_bvec().

Referenced by main().

void cmat_fwrite ( FILE *  stream,
cmat  m 
)

cmat cmat_new_fread ( FILE *  stream  ) 

Definition at line 2267 of file io.c.

References cmat_new().

cmat cmat_new_string ( char *  s  ) 

Definition at line 1141 of file io.c.

References cmat_new_alloc(), it_error(), and it_read_cmat().

int cvec_fread ( FILE *  stream,
cvec  v 
)

Definition at line 1945 of file io.c.

References cvec_length().

void cvec_fwrite ( FILE *  stream,
cvec  v 
)

Definition at line 1842 of file io.c.

References cvec_length().

cvec cvec_new_fread ( FILE *  stream  ) 

Definition at line 2051 of file io.c.

References cvec_new().

cvec cvec_new_string ( char *  s  ) 

Definition at line 1108 of file io.c.

References cvec_new_alloc(), it_error(), and it_read_cvec().

Referenced by main().

void fmat_fwrite ( FILE *  stream,
mat  m 
)

Definition at line 2089 of file io.c.

References mat_height(), and mat_width().

mat fmat_new_string ( char *  s  ) 

Definition at line 1130 of file io.c.

References it_error(), it_read_fmat(), and mat_new_alloc().

int fvec_fread ( FILE *  stream,
vec  v 
)

Definition at line 1878 of file io.c.

References vec_length().

void fvec_fwrite ( FILE *  stream,
vec  v 
)

Definition at line 1795 of file io.c.

References vec_length().

vec fvec_new_fread ( FILE *  stream  ) 

Definition at line 1986 of file io.c.

References vec_new().

vec fvec_new_string ( char *  s  ) 

Definition at line 1075 of file io.c.

References it_error(), it_read_fvec(), and vec_new_alloc().

int fvec_sread ( void *  buffer,
vec  v 
)

void imat_fwrite ( FILE *  stream,
imat  m 
)

Definition at line 2134 of file io.c.

References imat_height(), and imat_width().

imat imat_new_fread ( FILE *  stream  ) 

Definition at line 2246 of file io.c.

References imat_new().

imat imat_new_string ( char *  s  ) 

Definition at line 1151 of file io.c.

References imat_new_alloc(), it_error(), and it_read_imat().

imat imat_pgm_read ( const char *  filename  ) 

Definition at line 1336 of file io.c.

References _it_wavelet2D_::height, imat_new(), it_printf(), pnm_read_header(), and _it_wavelet2D_::width.

Referenced by main().

int imat_pgm_write ( const char *  filename,
imat  m 
)

Definition at line 1389 of file io.c.

References imat_height(), imat_width(), and pnm_write_header().

Referenced by main().

imat imat_wav_read ( const char *  filename  ) 

Definition at line 1689 of file io.c.

References imat_new(), it_printf(), wav_read_header(), and wav_read_sample().

Referenced by main().

void imat_wav_write ( const char *  filename,
imat  m,
int  srate,
int  depth 
)

Definition at line 1755 of file io.c.

References imat_height(), imat_width(), it_printf(), wav_write_header(), and wav_write_sample().

Referenced by main().

void it_printf ( char *  fmt,
  ... 
)

char* it_read_bmat ( char *  s,
bmat m 
)

char* it_read_bvec ( char *  s,
bvec v 
)

char* it_read_cmat ( char *  s,
cmat m 
)

char* it_read_cplx ( char *  s,
cplx p_val 
)

Definition at line 545 of file io.c.

References cimag, creal, it_assert, it_error(), and it_warning().

Referenced by it_read_cvec(), main(), parser_get_cplx(), and parser_get_cplx_verbose().

char* it_read_cvec ( char *  s,
cvec v 
)

char* it_read_double ( char *  s,
double *  p_val 
)

Definition at line 505 of file io.c.

References it_error().

Referenced by it_read_vec().

char* it_read_float ( char *  s,
float *  p_val 
)

Definition at line 525 of file io.c.

References it_error().

Referenced by it_read_fvec().

char* it_read_fmat ( char *  s,
mat m 
)

Definition at line 883 of file io.c.

References it_error(), it_read_vec(), mat_push_row, mat_set_height, vec_delete(), and vec_new().

Referenced by fmat_new_string().

char* it_read_fvec ( char *  s,
vec v 
)

Definition at line 677 of file io.c.

References it_read_float(), vec_push, and vec_set_length.

Referenced by fvec_new_string().

char* it_read_imat ( char *  s,
imat m 
)

char* it_read_int ( char *  s,
int *  p_val 
)

Definition at line 618 of file io.c.

References it_error().

Referenced by it_read_bvec(), and it_read_ivec().

char* it_read_ivec ( char *  s,
ivec v 
)

char* it_read_mat ( char *  s,
mat m 
)

char* it_read_vec ( char *  s,
vec v 
)

void it_set_mat_default_fmt ( char *  fmt  ) 

Definition at line 52 of file io.c.

References it_fmt_max_length, and it_printf_vec_default_fmt.

void it_set_vec_default_fmt ( char *  fmt  ) 

Definition at line 44 of file io.c.

References it_fmt_max_length, and it_printf_vec_default_fmt.

void it_vprintf ( char *  fmt,
va_list  args 
)

Definition at line 69 of file io.c.

References it_vfprintf().

int ivec_fread ( FILE *  stream,
ivec  v 
)

Definition at line 1905 of file io.c.

References ivec_length().

void ivec_fwrite ( FILE *  stream,
ivec  v 
)

Definition at line 1828 of file io.c.

References ivec_length().

ivec ivec_new_fread ( FILE *  stream  ) 

Definition at line 2030 of file io.c.

References ivec_new().

ivec ivec_new_string ( char *  s  ) 

Definition at line 1086 of file io.c.

References it_error(), it_read_ivec(), and ivec_new_alloc().

Referenced by main().

int ivec_sread ( void *  buffer,
ivec  v 
)

Definition at line 2190 of file io.c.

References ivec_init().

void mat_fwrite ( FILE *  stream,
mat  m 
)

Definition at line 2068 of file io.c.

References mat_height(), and mat_width().

mat mat_new_fread ( FILE *  stream  ) 

Definition at line 2204 of file io.c.

References mat_new().

mat mat_new_string ( char *  s  ) 

Definition at line 1119 of file io.c.

References it_error(), it_read_mat(), and mat_new_alloc().

mat mat_pgm_read ( const char *  filename  ) 

Definition at line 1309 of file io.c.

References _it_wavelet2D_::height, it_printf(), mat_new(), pnm_read_header(), and _it_wavelet2D_::width.

Referenced by main().

int mat_pgm_write ( const char *  filename,
mat  m 
)

Definition at line 1364 of file io.c.

References mat_height(), mat_width(), and pnm_write_header().

Referenced by main().

mat mat_wav_read ( const char *  filename  ) 

Definition at line 1662 of file io.c.

References it_printf(), mat_new(), wav_read_header(), and wav_read_sample().

Referenced by main().

void mat_wav_write ( const char *  filename,
mat  m,
int  srate,
int  depth 
)

Definition at line 1716 of file io.c.

References it_printf(), mat_height(), mat_width(), min(), wav_write_header(), and wav_write_sample().

Referenced by main().

int pnm_info ( const char *  filename,
char *  p_pnm_type,
int *  p_width,
int *  p_height,
int *  p_max_val,
char *  comments,
int  length 
)

Definition at line 1292 of file io.c.

References it_printf(), and pnm_read_header().

Referenced by main().

char pnm_type ( const char *  filename  ) 

Definition at line 1274 of file io.c.

References _it_wavelet2D_::height, it_printf(), pnm_read_header(), pnm_type(), and _it_wavelet2D_::width.

Referenced by main(), and pnm_type().

int vec_fread ( FILE *  stream,
vec  v 
)

Definition at line 1857 of file io.c.

References vec_length().

void vec_fwrite ( FILE *  stream,
vec  v 
)

Definition at line 1782 of file io.c.

References vec_length().

vec vec_new_fread ( FILE *  stream  ) 

Definition at line 1967 of file io.c.

References vec_new().

vec vec_new_string ( char *  s  ) 

Definition at line 1064 of file io.c.

References it_error(), it_read_vec(), and vec_new_alloc().

Referenced by main().

int vec_sread ( void *  buffer,
vec  v 
)

Definition at line 2176 of file io.c.

References vec_init().

int wav_info ( const char *  filename,
int *  p_channels,
int *  p_srate,
int *  p_depth,
int *  p_length 
)

Definition at line 1646 of file io.c.

References it_printf(), and wav_read_header().

Referenced by main().


Hosted by
Copyright (C) 2005-2006 Hervé Jégou
Vivien Chappelier
Francois Cayre
libit logo courtesy of Jonathan Delhumeau