NAME
subtract_Image - subtracts two images
SYNOPSIS
#include "CVIPimage.h"
#include "CVIParithlogic.h"
#include "CVIPconvert.h" Image *subtract_Image(Image
*inputImage1,Image *inputImage2)
<inputImage1> - pointer to an Image structure
<inputImage2> - pointer to an Image structure
PATH
$CVIPHOME/ARITHLOGIC/arithlogic.c
DESCRIPTION
This function uses the CVIP function 'sub_Matrix' to perform
bitwise subtractition of two images. Complex matrices are
supported.
TYPES AND CONSTANTS
#define MATPWISE_DEFINED
RETURN VALUES
A subtracted image.
HISTORY
History information recorded: None
EXAMPLE
#include "CVIPimage.h"
#include "CVIParithlogic.h"
#include "CVIPconvert.h"
void main() {
Image *inputImage1, *inputImage2, *outputImage;
IMAGE_FORMAT format;
char *inputfile1, *inputfile2, *outputfile;
setDisplay_Image("picture", "Default");
print_CVIP("\n\tEnter the first Input File Name: ");
inputfile1 =(char *) getString_CVIP();
inputImage1 = read_Image(inputfile1, 1);
view_Image(inputImage1,inputfile1);
free(inputfile1);
print_CVIP("\n\t\tEnter the second Input File Name: ");
inputfile2 =(char *) getString_CVIP();
inputImage2 = read_Image(inputfile2, 1);
view_Image(inputImage2,inputfile2);
free(inputfile2);
outputImage = subtract_Image(inputImage1, inputImage2);
print_CVIP("\n\t\tEnter the Output File Name: ");
outputfile = getString_CVIP();
view_Image(outputImage,outputfile);
free(outputfile);
}
SEE ALSO
libarithlogic, $CVIPHOME/include/MATpwise.h
AUTHOR
Copyright (C) 1996 SIUE - by Scott E. Umbaugh and Greg
Hance.