Crop window and resolution gate

This adds a resolution gate overlay and a tool for editing the crop window.