fix orientation error introduced by mirroring