1f206b4ce4
Rather than storing the shadow_image in the untransformed space and rotating on copy to hw_buffer we store both on the transformed space. This means a copy between them is a straight copy, and that apps supplying correctly transformed surface buffers need not change them. We also correctly handle all output transform including the previously unhandled flipped ones, as well as client supplied buffer_transforms (which were previously ignored). We also simplify the actual rendering by just converting any damage region to output coordinates and set it on a clip and composite the whole buffer, letting pixman do the rectangle handling. This means we always do all the transforms, including the surface positioning as a pixman_image transform. This simplifies the code and sets us up for handling scaling at a later stage. The transform looks complicated, but in practice it ends up being an integer translation almost always, so it will hit the pixman fastpaths.