Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
I have two tifs that are similar. What happens during normal processing of the original is it has gotten the alpha channel removed and some functions have been applied to the image. Unfortunately, to my dismay despite asking them to fix it, the processing that is done "sometimes" flips the image and rotates it. What I'm trying to do is figure out the most efficient and best way to identify if a flip is needed since these images are generally multi-gigbyte files. Below is the input and the output in a case where the image was flipped (I shrunk them down from the 1.5GB original):
My original thought would be to extract the alpha channel from the original, and then take all the black pixels from the "possibly flipped" and make them alpha, compare the alpha channels, And if it's within some reasonable variance (since the output may have black pixels that I care about that are now identified as alpha) then don't flip otherwise do flip. It just seems like there would be a better way to answer this question
I updated the photos with larger versions (1200 pixels). Towards the pixel coordinates 437,37 in the original, there's a blue circle (it's water) and in the flipped version, it's the black hole at the bottom This is also a screenshot showing what I mean: http://screencast.com/t/R4AN5RJECaZ
If all your images do not have such a unique marker and in the same relative location, then I do not see how that helps.
I, too, do not see any way to identify whether the image needs flipping, unless you have some key marker that you know where it should be in the original image.