split LayerInterface::render() into paint() and setViewport()