def METHOD_NAME(imfilter: _vtk.vtkWindowToImageFilter):
    """Run a ``vtkWindowToImageFilter`` and get output as array.
    Parameters
    ----------
    imfilter : _vtk.vtkWindowToImageFilter
        The ``vtkWindowToImageFilter`` instance to be processed.
    Returns
    -------
    numpy.ndarray
        An array containing the filtered image data. The shape of the array
        is given by (height, width, -1) where height and width are the
        dimensions of the image.
    """
    # Update filter and grab pixels
    imfilter.Modified()
    imfilter.Update()
    image = wrap(imfilter.GetOutput())
    img_size = image.dimensions
    img_array = point_array(image, 'ImageScalars')
    # Reshape and write
    tgt_size = (img_size[1], img_size[0], -1)
    return img_array.reshape(tgt_size)[::-1]