head	1.3;
access;
symbols;
locks; strict;
comment	@// @;


1.3
date	94.10.11.00.27.28;	author rjj;	state Exp;
branches;
next	1.2;

1.2
date	94.09.02.01.47.44;	author rjj;	state Exp;
branches;
next	1.1;

1.1
date	94.09.01.00.11.08;	author rjj;	state Exp;
branches;
next	;


desc
@Placing under RCS.  This should be the source corresponding to UM 1.0
@


1.3
log
@Modified to use 'return 0;' rather than 'exit(0);'.
@
text
@// image_example.01.c     Read a PGM file and display it

#include "UcharDI.h"
#include "IntDI.h"


int main() {
    IA_Image<IA_Point<int>,int>
	im1;	// im1 is an uninitialized image whose
    		// pixel values of type int

    IA_Image<IA_Point<int>,u_char> 
	im2;	// im2 is an uninitialized image whose
                // pixel values of type unsigned char

    im1 = read_int_PGM(cin);
    // im1 is initialized from the standard input stream

    cout << "Domain infimum is:  " << im1.domain().inf() << ".\n"
	 << "Domain supremum is: " << im1.domain().sup() << ".\n";

    im2 = to_uchar(im1);
    // im1 is converted to an IA_UcharDiscreteImage
    // whose value is assigned to im2

    im2 = max(im2) - im2;  // This inverts the sense of the values in im2.

    display( im2 );

    return 0;
}
@


1.2
log
@Modified to be iac++ v2.0 compliant.
@
text
@a2 1
#include <stdlib.h>
d30 1
a30 1
    exit( 0 );
@


1.1
log
@Initial revision
@
text
@a0 2
// Emacs: -*- C++ -*-

d3 3
a5 6
//#include "IntPoint.h"
//#include "Image.h"
//#include "BitDI.h"
//#include "IntDI.h"
//#include "UcharDI.h"
#include "imagealgebra.h"
d8 1
a8 1
main() {
a17 1
//    im1 = IA_IntDiscreteImage::read_PGM(cin);
d29 3
a31 1
//    display( im2 );
@
