test code to determine if photo is portrait or landscape