pgm.h
Go to the documentation of this file.
00001 
00006 /*
00007 Copyright (C) 2007-12 Andrea Vedaldi and Brian Fulkerson.
00008 All rights reserved.
00009 
00010 This file is part of the VLFeat library and is made available under
00011 the terms of the BSD license (see the COPYING file).
00012 */
00013 
00014 #ifndef VL_PGM_H
00015 #define VL_PGM_H
00016 
00017 #include "generic.h"
00018 #include "mathop.h"
00019 #include <stdio.h>
00020 
00023 #define VL_ERR_PGM_INV_HEAD  101 
00024 #define VL_ERR_PGM_INV_META  102 
00025 #define VL_ERR_PGM_INV_DATA  103 
00026 #define VL_ERR_PGM_IO        104 
00036 typedef struct _VlPgmImage
00037 {
00038   vl_size width ;      
00039   vl_size height ;     
00040   vl_size max_value ;  
00041   vl_bool is_raw ;     
00042 } VlPgmImage ;
00043 
00046 VL_EXPORT int vl_pgm_extract_head (FILE *f, VlPgmImage *im) ;
00047 VL_EXPORT int vl_pgm_extract_data (FILE *f, VlPgmImage const *im, void *data) ;
00048 VL_EXPORT int vl_pgm_insert (FILE *f,
00049                              VlPgmImage const *im,
00050                              void const*data ) ;
00051 VL_EXPORT vl_size vl_pgm_get_npixels (VlPgmImage const *im) ;
00052 VL_EXPORT vl_size vl_pgm_get_bpp (VlPgmImage const *im) ;
00057 VL_EXPORT int vl_pgm_write (char const *name,
00058                             vl_uint8 const *data,
00059                             int width, int height) ;
00060 VL_EXPORT int vl_pgm_write_f (char const *name,
00061                               float const *data,
00062                               int width, int height) ;
00063 VL_EXPORT int vl_pgm_read_new (char const *name,
00064                                VlPgmImage *im,
00065                                vl_uint8 **data) ;
00066 VL_EXPORT int vl_pgm_read_new_f (char const *name,
00067                                  VlPgmImage *im,
00068                                  float **data) ;
00069 
00072 /* VL_PGM_H */
00073 #endif


libvlfeat
Author(s): Andrea Vedaldi
autogenerated on Thu Jun 6 2019 20:25:51