Fix img flip regression in PDF

PDF Input: Fix a regression that caused some images to be flipped when
converting PDF files that use image rotation operators. See #1201083