irplib_hist.h

00001 /* $Id: irplib_hist.h,v 1.3 2007/09/07 14:23:50 lbilbao Exp $
00002  *
00003  * This file is part of the irplib package
00004  * Copyright (C) 2002, 2003 European Southern Observatory
00005  *
00006  * This program is free software; you can redistribute it and/or modify
00007  * it under the terms of the GNU General Public License as published by
00008  * the Free Software Foundation; either version 2 of the License, or
00009  * (at your option) any later version.
00010  *
00011  * This program is distributed in the hope that it will be useful,
00012  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
00014  * GNU General Public License for more details.
00015  *
00016  * You should have received a copy of the GNU General Public License
00017  * along with this program; if not, write to the Free Software
00018  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02111-1307 USA
00019  */
00020 
00021 /*
00022  * $Author: lbilbao $
00023  * $Date: 2007/09/07 14:23:50 $
00024  * $Revision: 1.3 $
00025  * $Name: detmon-1_2_0 $
00026  */
00027 
00028 #ifndef IRPLIB_HIST_H
00029 #define IRPLIB_HIST_H
00030 
00031 #include <cpl.h>
00032 
00033 typedef struct _irplib_hist_ irplib_hist;
00034 
00035 /* Creation/Destruction functions */
00036 
00037 irplib_hist *
00038 irplib_hist_new(void);
00039 
00040 void
00041 irplib_hist_delete(irplib_hist *);
00042 
00043 /* Initialisation function */
00044 
00045 cpl_error_code
00046 irplib_hist_init(irplib_hist   *,
00047                  unsigned long  ,
00048                  double         ,
00049                  double         );
00050 
00051 /* Accessor functions */
00052 
00053 unsigned long
00054 irplib_hist_get_value(const irplib_hist *,
00055                       const unsigned long);
00056 
00057 unsigned long
00058 irplib_hist_get_nbins(const irplib_hist *);
00059 
00060 double
00061 irplib_hist_get_bin_size(const irplib_hist *);
00062 
00063 double
00064 irplib_hist_get_range(const irplib_hist *);
00065 
00066 double
00067 irplib_hist_get_start(const irplib_hist *);
00068 
00069 /* Histogram computing function */
00070 
00071 cpl_error_code
00072 irplib_hist_fill(irplib_hist     *,
00073                  const cpl_image *);
00074 
00075 /* Statistics functions */
00076 
00077 unsigned long
00078 irplib_hist_get_max(const irplib_hist *,
00079                     unsigned long     *);
00080 
00081 /* Casting function */
00082 
00083 cpl_table *
00084 irplib_hist_cast_table(const irplib_hist *);
00085 
00086 /* Functions for operations on histograms */
00087 
00088 cpl_error_code
00089 irplib_hist_collapse(irplib_hist *,
00090                      unsigned long);
00091 
00092 #endif /* IRPLIB_HIST_H */
00093 

Generated on 7 Mar 2012 for DETMON Pipeline Reference Manual by  doxygen 1.6.1