NAME

get_image_stats - Computes some image statistics

SYNOPSIS

#include "i/i_stat.h"

Example compile flags (system dependent):
  -DLINUX_X86_64 -DLINUX_X86_64_OPTERON  -DGNU_COMPILER 
   -I/home/kobus/include
   -L/home/kobus/misc/load/linux_x86_64_opteron -L/usr/lib/x86_64-linux-gnu
  -lKJB                               -lfftw3  -lgsl -lgslcblas -ljpeg  -lSVM -lstdc++                    -lpthread -lSLATEC -lg2c    -lacml -lacml_mv -lblas -lg2c      -lncursesw 


int get_image_stats
(
	int *num_valid_pixels_ptr,
	Vector **mean_vpp,
	Vector **stdev_vpp,
	const KJB_image *source_ip
);

DESCRIPTION

This routine computes some image statistics. The number of valid pixes, the image mean, and the image standard deviation are put into *num_valid_pixels_ptr, *mean_vpp, and *stdev_vpp, respectively. If *mean_vpp or *stdev_vpp are NULL, or are the wrong size, then they are created or resizes as need be. Any of the three output arguments may be set to NULL if you are not interested in that particular statistic. Statistics are only computed over valid pixels, and if there are not enough valid pixels to compute a requested statistic, then ERROR is returned.

RETURNS

NO_ERROR on success, and ERROR on failure, with an appropriate error message being set.

DISCLAIMER

This software is not adequatedly tested. It is recomended that results are checked independantly where appropriate.

AUTHOR

Kobus Barnard

DOCUMENTER

Kobus Barnard

SEE ALSO

get_ave_rgb , get_max_rgb , get_image_window_stats , get_ave_ratio_without_invalid , get_ave_sum_ratio_without_invalid