|
||||||||||
| PREV CLASS Documentation homepage NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectilog.views.maps.raster.IlvRasterTileLoader
public class IlvRasterTileLoader
This class provides the mechanism for the dynamic tiling. A projected image
is cut into tiles and filled with pixels according to the projection of the
view. The pixels are computed according to the original projection of the
source raster.
The dynamic tiling also allows a subsampled preview in order to provide the
user with a rough image while the tile loader is computing the detailed
picture.
| Constructor Summary | |
|---|---|
IlvRasterTileLoader(IlvInputStream stream)
Reads the raster info from the specified input stream. |
|
IlvRasterTileLoader(IlvRasterProperties rasterProperties,
IlvRasterMappedBuffer rasterMappedBuffer,
IlvCoordinateTransformation transformation)
Constructor taking as parameters the information about the raster and the data in two separated objects. |
|
| Method Summary | |
|---|---|
protected int |
getBytePixel(IlvCoordinate pret,
int noData)
Compute the pixel value. |
IlvMathTransform |
getInternalTransformation()
Returns the internal transformation from lat/lon to raster x/y. |
protected int |
getIntPixel(IlvCoordinate pret,
int noData)
Compute the pixel value. |
int |
getPreviewDelay()
Returns the preview Delay. |
int |
getPreviewSubsampling()
Returns the subsampling factor for a possible preview image. |
IlvAttributeProperty |
getProperties()
The image properties. |
IlvRasterMappedBuffer |
getRasterMappedBuffer()
Return the data of the raster of the original image. |
IlvRasterProperties |
getRasterProperties()
Accesses the information about the raster of the image. |
ImageProducer |
getRawImageProducer()
Returns an image producer to return the whole unprojected image. |
ImageProducer |
getScaledImageProducer(int subsampling,
IlvRect managerBounds)
Returns an image producer able to generate an image for the parameters passed. |
IlvCoordinateTransformation |
getTransformation()
Returns Coordinate transformation to attach the image to a manager. |
boolean |
isHighQualityRendering()
Indicates if the icon should be rendered high quality. |
boolean |
isPersistent()
Returns true if the object must be saved by a tile controller. |
boolean |
isSynchronous()
Tests if this raster tile loader is loading images synchronously or not. |
void |
load(IlvTile tile)
Function called when a tile has to be loaded. |
protected IlvRasterIcon |
makeIcon(int subsampling,
Point2D.Double p1,
Point2D.Double p2)
Factory of icons from the subsampling and two corners parameters. |
protected void |
rasterTileLoaded(IlvTile tile)
This method is called when a raster tile has been loaded. |
void |
release(IlvTile tile)
Function called when a tile has to be released. |
void |
setHighQualityRendering(boolean value)
Changes the rendering quality state of the image. |
void |
setPreviewSubsampling(int previewSubsampling,
int previewDelay)
Sets the subsampling factor for a possible preview image. |
void |
setProperties(IlvAttributeProperty properties)
Sets the properties that will affect the image when it is created. |
void |
setSynchronous(boolean synchronous)
Sets the synchronous image loading policy for this tile loader. |
void |
setTransformation(IlvCoordinateTransformation transformation)
Sets the coordinate transformation to use for creating an image attached to a manager. |
protected void |
setupIcon(IlvRasterIcon icon)
Sets up the icon. |
void |
write(IlvOutputStream out)
Writes the attributes of a persistent object. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IlvRasterTileLoader(IlvInputStream stream)
throws IlvReadFileException
stream - The input stream.
IlvReadFileException - if an error occurs while reading the data.
public IlvRasterTileLoader(IlvRasterProperties rasterProperties,
IlvRasterMappedBuffer rasterMappedBuffer,
IlvCoordinateTransformation transformation)
rasterProperties - The information about the raster.rasterMappedBuffer - The data of the raster of the original image.transformation - The transformation to use from view to geographic coordinates.| Method Detail |
|---|
public IlvMathTransform getInternalTransformation()
public IlvRasterMappedBuffer getRasterMappedBuffer()
public final IlvRasterProperties getRasterProperties()
public ImageProducer getRawImageProducer()
public IlvCoordinateTransformation getTransformation()
public boolean isPersistent()
isPersistent in interface IlvTileLoaderIlvTileLoader.isPersistent()
public void load(IlvTile tile)
throws Exception
IlvTile.loadComplete to notify the
tile listeners.
load in interface IlvTileLoaderExceptionIlvTileLoader.load(ilog.views.tiling.IlvTile)protected void rasterTileLoaded(IlvTile tile)
tile -
protected IlvRasterIcon makeIcon(int subsampling,
Point2D.Double p1,
Point2D.Double p2)
subsampling - Initial subsampling of the image created.p1 - The definition rectangle of the object.p2 - The definition rectangle of the object.
protected void setupIcon(IlvRasterIcon icon)
icon - Icon to setup.public void release(IlvTile tile)
release in interface IlvTileLoaderIlvTileLoader.release(ilog.views.tiling.IlvTile)public void setHighQualityRendering(boolean value)
true will improve the rendering. The default value is
false.
value - The value.public boolean isHighQualityRendering()
true if the icon is high quality.public void setProperties(IlvAttributeProperty properties)
properties - Feature properties that will affect the image.public void setTransformation(IlvCoordinateTransformation transformation)
transformation - Coordinate transformation from view to geographic coordinates to
attach the image to a manager.
public void write(IlvOutputStream out)
throws IOException
write in interface IlvPersistentObjectwrite in interface IlvTileLoaderout - the output stream
IOException - thrown when an exception occurs during
the write operation for this object.IlvPersistentObject.write(ilog.views.io.IlvOutputStream)
protected int getBytePixel(IlvCoordinate pret,
int noData)
pret - Manager x,y coordinate.noData - Value to return when no pixel is present at the location.
noData.
protected int getIntPixel(IlvCoordinate pret,
int noData)
pret - Manager x,y coordinate.noData - Value to return when no pixel is present at the location.
noData.
public ImageProducer getScaledImageProducer(int subsampling,
IlvRect managerBounds)
subsampling - Subsampling to apply to the image.managerBounds - Manager bounds of the image.
public int getPreviewSubsampling()
public void setPreviewSubsampling(int previewSubsampling,
int previewDelay)
previewSubsampling - The subsampling factor for a possible preview image.previewDelay - The time in ms where the preview will be visible (for example
500ms).public IlvAttributeProperty getProperties()
public int getPreviewDelay()
public boolean isSynchronous()
true is returned.public void setSynchronous(boolean synchronous)
synchronous - Set to true to load images synchronously.
|
||||||||||
| PREV CLASS Documentation homepage NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||