head	1.2;
access
	monica
	thoth;
symbols
	Eglin_alpha_1:1.1;
locks
	monica:1.2; strict;
comment	@// @;


1.2
date	94.08.17.04.12.11;	author monica;	state Exp;
branches;
next	1.1;

1.1
date	93.01.12.14.44.45;	author thoth;	state Exp;
branches;
next	;


desc
@speed test prototype for fast convolution.
@


1.2
log
@added int main & return 0
@
text
@// Emacs: -*- C++ -*-
static char rcsid[] = "$Id: test012.c,v 1.1 1993/01/12 14:44:45 thoth Exp monica $";

//
// $Log: test012.c,v $
// Revision 1.1  1993/01/12  14:44:45  thoth
// Initial revision
//
//

#include "IntPS.h"
#include "PSIter.h"

int main(int argc, char**)
{
    int	choice=(argc>1);
    
    IA_Set<IA_Point<int> >	big(IA_Point<int>(0,0), IA_Point<int>(63,63));
    const unsigned	gsize=5;
    IA_Point<int>	gauss[gsize] = {
	IA_Point<int>(-1,0),
	    IA_Point<int>(0,-1),
	    IA_Point<int>(0,0),
	    IA_Point<int>(0,1), 
	    IA_Point<int>(1,0)
	    };
    IA_Set<IA_Point<int> >	small = IA_Set<IA_Point<int> >(2, gauss, 5);
    
    IA_PSIter<IA_Point<int> >	iter(big);
    IA_Point<int>	ip, newp;
    int	*one, *two;
    
    cout << "going" << flush;
    switch (choice) {
    case 0:
	while (iter(ip)) {
	    for (unsigned i=0; i<gsize; i++) {
		newp = gauss[i]+ip;
		if (big.contains(newp)) {
		    big.index(newp);
		}
	    }
	}
	break;
    case 1:
	while (iter(ip)) {
	    IA_SetStructure	ss;
	    intersect_with_dualstruct(big, small+ip, &ss);
	}
	break;
    }
    cout << "gone\n";

    return 0;

}

@


1.1
log
@Initial revision
@
text
@d2 1
a2 1
static char rcsid[] = "$Id: test011.c,v 1.2 92/11/04 12:03:15 thoth Exp Locker: thoth $";
d5 3
a7 1
// $Log:	test011.c,v $
d9 1
a9 3

#include "IntPointSet.h"
#include "IPSIter.h"
d11 2
a12 1
#include "with-ia-pointset.h"
d18 1
a18 1
    IntPointSet	big(IntPoint(0,0), IntPoint(63,63));
d20 6
a25 6
    IntPoint	gauss[gsize] = {
	IntPoint(-1,0),
	    IntPoint(0,-1),
	    IntPoint(0,0),
	    IntPoint(0,1), 
	    IntPoint(1,0)
d27 1
a27 1
    IntPointSet	small = IntPointSet(2, gauss, 5);
d29 2
a30 2
    IPSIter	iter(big);
    IntPoint	ip, newp;
d47 1
a47 1
	    SetStructure	ss;
d53 3
d57 1
@
