Region2D - abstract base class for two dimensional geometric regions
use Region2D;
Region2D is an abstract class to be used to construct geometric regions. It should be used only as a parent class.
The following methods must be overridden:
Provide a completely independent clone of the object.
$area = $obj->area
This should return the area of the object. It takes no arguments.
@pdls = $obj->in( $pdl_x, $pdl_y, @other_pdls ); @pdls = $obj->in( $pdl_x, $pdl_y, @other_pdls, \%attr );
This filters the passed piddles, returning a list of piddles containing the
subset that is physically located inside the region (according to the
initial $pdl_x and $pdl_y locations). The list of piddles in the same order as in the argument list.
The optional %attr hash may be used by the in method as required; at the very least it should contain and act upon the
following keywords:
If true, the initial two piddles (the coordinates) should be returned along with the other piddles. If false, only the other piddles should be returned. This defaults to true.
@pdls = $obj->out( $pdl_x, $pdl_y, @other_pdls ); @pdls = $obj->out( $pdl_x, $pdl_y, @other_pdls, \%attr );
This filters the passed piddles, returning a list of piddles containing the
subset that is physically located outside the region (according to the
initial $pdl_x and $pdl_y locations). The list of piddles in the same order as in the argument list.
The optional %attr hash may be used by the in method as required; at the very least it should contain and act upon the
following keywords:
If true, the initial two piddles (the coordinates) should be returned along with the other piddles. If false, only the other piddles should be returned. This defaults to true.
Diab Jerius ( djerius@cfa.harvard.edu )
perl(1).