NAME

     hist_slide - performs histogram slide

SYNOPSIS

      #include <CVIPtoolkit.h>
      #include <CVIPimage.h>
      #include <CVIPmatrix.h>
      #include <CVIPhisto.h>

     Image* hist_slide(Image *input,int slide)

      <input> - pointer to an Image
      <slide> - amount of slide

PATH

     $CVIPHOME/HISTOGRAM/hist_slide.c

DESCRIPTION

     This function slides a histogram up if <slide>  is  positive
     or  down  if <slide> is negative. It requires CVIP_BYTE type
     input, and clips at 0 or 255.

TYPES AND CONSTANTS

     None

RETURN VALUES

     Pointer to the modified image

HISTORY

     History information recorded: None

EXAMPLE

      #include <CVIPtoolkit.h>
      #include <CVIPimage.h>
      #include <CVIPconvert.h>
      #include <CVIPview.h>
      #include "histogram.h"
      #define VIEWER "picture"
      #define VIDEO_APP "SunVideo &"

      void main()
      {
      Image *cvipImage;
      IMAGE_FORMAT format;
      char *inputfile,*outputfile;

      setDisplay_Image(VIEWER, "Default");

      print_CVIP("\n\t\tEnter the Input File Name:  ");
      inputfile =(char *) getString_CVIP();
      format = getFormat_CVIP(inputfile);
      cvipImage = read_Image(inputfile, 1);
      view_Image(cvipImage, inputfile);
      free(inputfile);
      /* the following call slides the histogram in the
      positive direction by 50 */
      cvipImage = hist_slide(cvipImage,50);
      print_CVIP("\n\t\tEnter the Output File Name:  ");
      outputfile = getString_CVIP();
      view_Image(cvipImage,outputfile);
      write_Image(cvipImage,outputfile,CVIP_NO,CVIP_NO,format,1);
      free(outputfile);
      }

SEE ALSO

     libhisto

AUTHOR

     Copyright (C) 1996 SIUE - by Scott E. Umbaugh and Kun Luo.