Package gov.nasa.worldwind.formats.tiff
Class Subfile
- java.lang.Object
-
- gov.nasa.worldwind.formats.tiff.Subfile
-
public class Subfile extends java.lang.Object
A representation of a Tiff subfile. This class maintains information provided by the Image File Directory and image data. This class is not thread safe.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int[]
getBitsPerSample()
int
getCompression()
java.nio.ByteBuffer
getData(java.nio.ByteBuffer result)
Writes the uncompressed data from the Tiff data associated with the Subfile to the provided ByteBuffer.int
getDataSize()
Calculates the uncompressed data size.java.util.Map<java.lang.Integer,Field>
getFields()
int
getImageLength()
int
getImageWidth()
int
getNewSubfileType()
int
getOffset()
int
getPhotometricInterpretation()
int
getPlanarConfiguration()
int
getResolutionUnit()
int
getRowsPerStrip()
int[]
getSampleFormat()
int
getSamplesPerPixel()
int[]
getStripByteCounts()
int[]
getStripOffsets()
Tiff
getTiff()
int[]
getTileByteCounts()
int
getTileLength()
int[]
getTileOffsets()
int
getTileWidth()
double
getXResolution()
double
getYResolution()
-
-
-
Constructor Detail
-
Subfile
public Subfile()
Empty Subfile constructor. Will not provide parsed default values.
-
Subfile
public Subfile(Tiff tiff, int offset)
-
-
Method Detail
-
getTiff
public Tiff getTiff()
-
getFields
public java.util.Map<java.lang.Integer,Field> getFields()
-
getNewSubfileType
public int getNewSubfileType()
-
getImageWidth
public int getImageWidth()
-
getImageLength
public int getImageLength()
-
getBitsPerSample
public int[] getBitsPerSample()
-
getCompression
public int getCompression()
-
getPhotometricInterpretation
public int getPhotometricInterpretation()
-
getSamplesPerPixel
public int getSamplesPerPixel()
-
getXResolution
public double getXResolution()
-
getYResolution
public double getYResolution()
-
getPlanarConfiguration
public int getPlanarConfiguration()
-
getResolutionUnit
public int getResolutionUnit()
-
getOffset
public int getOffset()
-
getStripOffsets
public int[] getStripOffsets()
-
getStripByteCounts
public int[] getStripByteCounts()
-
getTileOffsets
public int[] getTileOffsets()
-
getTileByteCounts
public int[] getTileByteCounts()
-
getRowsPerStrip
public int getRowsPerStrip()
-
getTileWidth
public int getTileWidth()
-
getTileLength
public int getTileLength()
-
getSampleFormat
public int[] getSampleFormat()
-
getDataSize
public int getDataSize()
Calculates the uncompressed data size. Should be used when preparing the ByteBuffer for write Tiff data in thegetData(ByteBuffer)
method.- Returns:
- the size in bytes of the uncompressed data
-
getData
public java.nio.ByteBuffer getData(java.nio.ByteBuffer result)
Writes the uncompressed data from the Tiff data associated with the Subfile to the provided ByteBuffer. The data copied to the provided buffer will use the original datas byte order and may override the byte order specified by the provided buffer.- Parameters:
result
- a ByteBuffer ready for the uncompressed Tiff data, should have a capacity of at least the return value ofgetDataSize()
- Returns:
- the populated provided ByteBuffer
-
-