Improved LayerIterator.