dekoh.portal.fwk.image
Class EXIFOrientation
java.lang.Object
java.lang.Enum
dekoh.portal.fwk.image.EXIFOrientation
- All Implemented Interfaces:
- Serializable, Comparable
public final class EXIFOrientation
- extends Enum
The Exif orientation value gives the orientation of the camera relative to the scene when the image was captured.
The relation of the '0th row' and '0th column' to visual position is shown as below.
| Value | 0th Row | 0th Column |
| 1 | top | left
side |
| 2 | top | rigth side |
| 3 | bottom
| rigth side |
| 4 | bottom | left side |
| 5 |
left side | top |
| 6 | right side | top |
| 7 |
right side | bottom |
| 8 | left side | bottom |
For
convenience, here is what the letter F would look like if it were tagged correctly and displayed by a program that
ignores the orientation tag:
1 2 3 4 5 6 7 8
888888 888888 88 88 8888888888 88 88 8888888888
88 88 88 88 88 88 88 88 88 88 88 88
8888 8888 8888 8888 88 8888888888 8888888888 88
88 88 88 88
88 88 888888 888888
- Since:
- Mar 12, 2007
- See Also:
- Serialized Form
TOP_LEFT
public static final EXIFOrientation TOP_LEFT
TOP_RIGHT
public static final EXIFOrientation TOP_RIGHT
BOTTOM_RIGHT
public static final EXIFOrientation BOTTOM_RIGHT
BOTTOM_LEFT
public static final EXIFOrientation BOTTOM_LEFT
LEFT_TOP
public static final EXIFOrientation LEFT_TOP
RIGHT_TOP
public static final EXIFOrientation RIGHT_TOP
RIGHT_BOTTOM
public static final EXIFOrientation RIGHT_BOTTOM
LEFT_BOTTOM
public static final EXIFOrientation LEFT_BOTTOM
values
public static final EXIFOrientation[] values()
valueOf
public static EXIFOrientation valueOf(String name)
getByteValue
public byte getByteValue()
getEXIFOrientation
public static EXIFOrientation getEXIFOrientation(int orientation)
- Parameters:
orientation - number between 1 and 8
- Returns:
- EXIFOrientation enum const for given value
getEXIFOrientation
public static EXIFOrientation getEXIFOrientation(byte byteValue)
compensateForRotation
public EXIFOrientation compensateForRotation(int toDegree)
- Gets orientation for an image which after a rotation by
toDegrees will be in the orientation
denoted by the current instance.
- Parameters:
toDegree - degree rotated (multiple of 90 only)
- Returns:
- EXIFOrientation the original orientation which after rotation of
toDegree will return
the current orientation.
mirror
public EXIFOrientation mirror()
© 2009 Pramati Technologies - Dekoh - Portal for Developers