%N xyzplnrd %F $MIR/src/subs/xyzio.c
%D Get a plane from a dataset
%P bpw
%: image-i/o
%B
      subroutine xyzplnrd( tno, planenr, plane, mask, ndata )
      integer    tno
      integer    planenr
      real       plane(*)
      logical    mask(*)
      integer    ndata

This routine provides a more convenient version of calls to xyzs2c and
xyzread for the case that the calling program needs planes. It should
be used after a call to xyzsetup was used to set up two-dimensional
subcubes. The calling program can then loop over all planes (from 1 to
vircubesize(naxis)/vircubesize(2)). xyzplnrd takes care of reading the
datacube. The caveat is that the calling program should have an array
that is large enough to contain the complete plane.
Using this routine instead of xyzs2c and xyzread reduces the overhead
by 1% (for 64**2 cubes) or less.

    Input:
      tno           image file handle
      planenr       plane nr to be read from virtual-cube
    Output:
      plane         will contain the plane as a 1-d array
      mask          FALSE values indicate undefined pixels
      ndata         number of elements read                                   
