rebuild.graphics.tiff.tags
Class PhotometricInterpretationTag

java.lang.Object
  extended by rebuild.graphics.tiff.Tag
      extended by rebuild.graphics.tiff.tags.ShortTag
          extended by rebuild.graphics.tiff.tags.PhotometricInterpretationTag

public final class PhotometricInterpretationTag
extends ShortTag

The color space of the image data.

Since:
BBX 1.0.1

Field Summary
static short BLACK_IS_ZERO
          For bilevel and grayscale images: 0 is imaged as black.
static short CFA
          CFA (Color Filter Array)
static short CIELAB
          CIE L*a*b* (see also specification supplements 1 and 2)
static short ICCLAB
          CIE L*a*b*, alternate encoding also known as ICC L*a*b* (see also specification supplements 1 and 2)
static short ITULAB
          CIE L*a*b*, alternate encoding also known as ITU L*a*b*, defined in ITU-T Rec.
static short LINEAR_RAW
          LinearRaw
static short MASK
          This means that the image is used to define an irregularly shaped region of another image in the same TIFF file.
static short PALETTE
          In this model, a color is described with a single component.
static short RGB
          RGB value of (0,0,0) represents black, and (255,255,255) represents white, assuming 8-bit components.
static short SEPARATED
          Separated, usually CMYK.
static short WHITE_IS_ZERO
          For bilevel and grayscale images: 0 is imaged as white.
static short YCBCR
          YCbCr
 
Fields inherited from class rebuild.graphics.tiff.Tag
count, data, dataType, value
 
Constructor Summary
PhotometricInterpretationTag(short type)
          Create a new PhotometricInterpretation tag.
 
Method Summary
 short getImageType()
          Get the image type value.
 SamplesPerPixelTag getSamplesTag()
          Get a SamplesPerPixelTag for the current photometric.
static short getTagTypeValue()
          Get the Tag's type.
 void setCount(int count)
          There is always only 1 element.
 void setValue(int type)
          Set the image type.
 
Methods inherited from class rebuild.graphics.tiff.tags.ShortTag
extraData, getShort, hasDefault, isDefault, setDataType, setExtraData, setShort, setupForBigTIFF, writeData
 
Methods inherited from class rebuild.graphics.tiff.Tag
equals, getBigCount, getBigValue, getCount, getDataType, getExtraData, getIfExtraDataExists, getTagType, getValue, hashCode, setCount, setValue, toString, write, write, write, write, writeBig
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

WHITE_IS_ZERO

public static final short WHITE_IS_ZERO
For bilevel and grayscale images: 0 is imaged as white.

See Also:
Constant Field Values

BLACK_IS_ZERO

public static final short BLACK_IS_ZERO
For bilevel and grayscale images: 0 is imaged as black.

See Also:
Constant Field Values

RGB

public static final short RGB
RGB value of (0,0,0) represents black, and (255,255,255) represents white, assuming 8-bit components. The components are stored in the indicated order: first Red, then Green, then Blue.

See Also:
Constant Field Values

PALETTE

public static final short PALETTE
In this model, a color is described with a single component. The value of the component is used as an index into the red, green and blue curves in the ColorMap field to retrieve an RGB triplet that defines the color. When PhotometricInterpretation=PALETTE is used, ColorMap must be present and SamplesPerPixel must be 1.

See Also:
Constant Field Values

MASK

public static final short MASK
This means that the image is used to define an irregularly shaped region of another image in the same TIFF file. SamplesPerPixel and BitsPerSample must be 1. PackBits compression is recommended. The 1-bits define the interior of the region; the 0-bits define the exterior of the region.

See Also:
Constant Field Values

SEPARATED

public static final short SEPARATED
Separated, usually CMYK.

See Also:
Constant Field Values

YCBCR

public static final short YCBCR
YCbCr

See Also:
Constant Field Values

CIELAB

public static final short CIELAB
CIE L*a*b* (see also specification supplements 1 and 2)

See Also:
Constant Field Values

ICCLAB

public static final short ICCLAB
CIE L*a*b*, alternate encoding also known as ICC L*a*b* (see also specification supplements 1 and 2)

See Also:
Constant Field Values

ITULAB

public static final short ITULAB
CIE L*a*b*, alternate encoding also known as ITU L*a*b*, defined in ITU-T Rec. T.42, used in the TIFF-F and TIFF-FX standard (RFC 2301). The Decode tag, if present, holds information about this particular CIE L*a*b* encoding.

See Also:
Constant Field Values

CFA

public static final short CFA
CFA (Color Filter Array)

See Also:
Constant Field Values

LINEAR_RAW

public static final short LINEAR_RAW
LinearRaw

See Also:
Constant Field Values
Constructor Detail

PhotometricInterpretationTag

public PhotometricInterpretationTag(short type)
Create a new PhotometricInterpretation tag.

Parameters:
type - The type of image.
Method Detail

getTagTypeValue

public static short getTagTypeValue()
Get the Tag's type.

Returns:
The Tag's type.

setCount

public void setCount(int count)
There is always only 1 element.

Overrides:
setCount in class ShortTag
Parameters:
count - The number of Writer.SHORT contained in the tag. If the number is bigger than the current count then it will add 0 Writer.SHORT, else it will remove the Writer.SHORT.
See Also:
setCount

setValue

public void setValue(int type)
Set the image type.

Overrides:
setValue in class Tag
Parameters:
type - The image type.
See Also:
getValue

getImageType

public short getImageType()
Get the image type value.

Returns:
The image type that this tag is set to.

getSamplesTag

public SamplesPerPixelTag getSamplesTag()
Get a SamplesPerPixelTag for the current photometric.

Returns:
The SamplesPerPixelTag, if this is null than it is a variable number of components.