fix image orientation problem