|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.bbn.openmap.layer.rpf.RpfFrame
public class RpfFrame
The object that organizes the information found within the RPF frame file. The RpfFrame handles reading through the different sections, and holds on to the compressed subframe data. The cache handler gets the compressed subframe data and decompresses it before storing the uncompressed subframe in the cache.
Nested Class Summary | |
---|---|
static class |
RpfFrame.Compression
|
static class |
RpfFrame.Image
|
static class |
RpfFrame.LookupTable
|
Field Summary | |
---|---|
protected RpfAttributes |
attributes
|
protected RpfColortable |
colortable
|
protected RpfFileSections.RpfCoverageSection |
coverage
|
protected boolean |
DEBUG_RPFDETAIL
|
protected boolean |
DEBUG_RPFFRAME
|
protected RpfFileSections |
fileSections
|
protected RpfHeader |
header
|
protected NitfHeader |
nitfHeader
|
Constructor Summary | |
---|---|
RpfFrame(RpfFrameEntry rfe)
Loads the RpfFrame, given the RpfFrameEntry that the RpfCacheHandler got from the RpfTocHandler. |
|
RpfFrame(java.lang.String framePath)
Loads the RpfFrame, given a complete path to the file. |
Method Summary | |
---|---|
byte[] |
decompressSubframe(int x,
int y)
Decompress a subframe into an array of bytes suitable for in indexed color model image. |
int[] |
decompressSubframe(int x,
int y,
RpfColortable colortable)
Decompress a subframe into an array of ints suitable for a direct color model image. |
RpfSubframe |
decompressSubframe(int x,
int y,
RpfSubframe subframe,
RpfColortable colortable,
RpfViewAttributes viewAttributes)
Decompress a subframe into a cache entry OMRaster (RpfSubframe). |
RpfAttributes |
getAttributes()
Get the attributes for the RpfFrame. |
java.awt.Color[] |
getColors(BinaryFile binFile,
RpfColortable ct)
The only reason to call this is to read the colortable that is within the frame file, and set the colors that you will be using for all the frames accordingly. |
static java.awt.Color[] |
getColors(java.lang.String framePath,
RpfColortable ct)
Load the colortable with the colors from a particular frame file. |
RpfColortable |
getColortable()
Get the colortable stored inside this RpfFrame. |
RpfFileSections.RpfCoverageSection |
getCoverage()
Get the coverage section. |
RpfFileSections |
getFileSections()
Get the different file sections. |
RpfHeader |
getHeader()
Get the RpfFrame header. |
NitfHeader |
getNitfHeader()
Get the NitfFile header. |
java.lang.String |
getReport(int x,
int y,
RpfFrameEntry entry,
boolean Cib)
Get the attribute html text to display on the screen. |
protected boolean |
initFile(java.lang.String framePath)
|
boolean |
isValid()
|
static void |
main(java.lang.String[] argv)
|
boolean |
read(BinaryFile binFile)
Read the RPF frame. |
protected void |
setReport(boolean Cib)
Create the screen text used on a subframe. |
void |
view()
A quick hack to pop up a window that displays the entire frame image. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected NitfHeader nitfHeader
protected RpfHeader header
protected RpfFileSections fileSections
protected RpfAttributes attributes
protected RpfFileSections.RpfCoverageSection coverage
protected RpfColortable colortable
protected boolean DEBUG_RPFDETAIL
protected boolean DEBUG_RPFFRAME
Constructor Detail |
---|
public RpfFrame(java.lang.String framePath)
public RpfFrame(RpfFrameEntry rfe)
Method Detail |
---|
protected boolean initFile(java.lang.String framePath)
public boolean isValid()
protected void setReport(boolean Cib)
Cib
- whether the frame is a Cib frame. The report is different if it
is.public java.lang.String getReport(int x, int y, RpfFrameEntry entry, boolean Cib)
x
- subframe index within the array from the TocEntry.y
- subframe index within the array from the TocEntryentry
- the RpfFrameEntry describing the frame.Cib
- whether the frame is an imagery frame.public NitfHeader getNitfHeader()
public RpfHeader getHeader()
public RpfFileSections getFileSections()
public RpfAttributes getAttributes()
public RpfFileSections.RpfCoverageSection getCoverage()
public java.awt.Color[] getColors(BinaryFile binFile, RpfColortable ct)
public static java.awt.Color[] getColors(java.lang.String framePath, RpfColortable ct)
public RpfColortable getColortable()
public boolean read(BinaryFile binFile)
public RpfSubframe decompressSubframe(int x, int y, RpfSubframe subframe, RpfColortable colortable, RpfViewAttributes viewAttributes)
x
- the x coord for the subframey
- the y coord for the subframesubframe
- the subframe to create the image for. The resulting image
will be loaded into the RpfSubframe. If null, a new RpfSubframe
will be created.colortable
- the colortable to use with this image. If null, the
colortable from this RpfFrame will be used.viewAttributes
- our image generation parameters.
public byte[] decompressSubframe(int x, int y)
x
- the x coord for the subframey
- the y coord for the subframepublic int[] decompressSubframe(int x, int y, RpfColortable colortable)
x
- the x coord for the subframey
- the y coord for the subframecolortable
- the colortable to use with this image. If null, the
RpfColortable from the frame will be used.public static void main(java.lang.String[] argv)
public void view()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |