// Emacs: -*- C++ -*-

//
//	Copyright 1993, Center for Computer Vision and Visualization,
//	University of Florida.  All rights reserved.
//


//
// $Log: conversion.templ,v $
// Revision 1.1  1994/01/31  16:50:30  thoth
// Initial revision
//

IA_Image<IA_IntPoint, LTYPE>::
operator IA_Image<IA_IntPoint, ATYPE>( )
{
    IA_IntPointSet	domain = this->domain();
    // if the domain isn\'t extensive, we need a lazy conversion image...
    const unsigned	sz = domain.card();
    ATYPE * const	vec = new ATYPE[sz];
    {
	ATYPE	*scan = vec;
	IA_IVIter<IA_IntPoint,LTYPE>	iter(*this);
	LTYPE	temp;
	while (iter(temp)) {
	    *(scan++) = temp;
	}
    }

    return IA_Image<IA_IntPoint,ATYPE>(domain, vec, sz, 1);
}
