public interface BufferManager
Modifier and Type | Field and Description |
---|---|
static int |
TYPE_BYTE |
static int |
TYPE_DOUBLE |
static int |
TYPE_FLOAT |
static int |
TYPE_INT |
static int |
TYPE_SHORT |
static int |
TYPE_UNDEFINED |
static int |
TYPE_USHORT |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
coerce(int dataType,
java.lang.Object value) |
BandPageManager |
createAwtRasterBandPageManager(java.awt.image.Raster img,
int band) |
java.util.List<PageManager> |
createAwtRasterBandPageManagerList(java.awt.image.Raster img) |
Band |
createBand(int dataType,
int rows,
int columns,
NoData noData,
PageManager pageManager)
Creates a
Band . |
BandInfo |
createBandInfo(int band,
java.lang.String name,
java.lang.String description,
int dataType,
java.util.List<java.util.Map.Entry<java.lang.Object,java.lang.Object>> values)
Creates
BandInfo with information about one band. |
Buffer |
createBuffer(Buffer buffer,
boolean paginated)
Creates a buffer from another buffer.
|
Buffer |
createBuffer(int rows,
int columns,
int[] bandDataTypes,
IProjection projection)
Creates a memory buffer.
|
Buffer |
createBuffer(int rows,
int columns,
int[] bandDataTypes,
NoData[] bandNodata,
IProjection projection)
Creates a memory buffer.
|
Buffer |
createBuffer(int rows,
int columns,
int[] bandDataTypes,
NoData[] bandNodata,
IProjection projection,
Envelope envelope)
Creates a memory buffer.
|
Buffer |
createBuffer(int rows,
int columns,
int[] bandDataTypes,
NoData[] bandNoData,
IProjection projection,
Envelope envelope,
java.util.List<PageManager> pageManagers)
Creates a buffer.
|
BufferDimensions |
createBufferDimensions(int rows,
int columns,
Envelope envelope) |
Buffer |
createBufferFromAwtRaster(java.awt.image.Raster raster,
IProjection projection,
Envelope envelope) |
Band |
createClippedBand(Buffer buffer,
Band band)
Creates a clipping of a band.
|
Buffer |
createClippedBuffer(Buffer buffer,
Envelope envelope)
Creates a buffer from clipping of a buffer.
|
Band |
createConvertedTypeBand(Buffer buffer,
Band band,
int type)
Create one band from another by changing the type.
|
Buffer |
createConvertedTypeBuffer(Buffer buffer,
int type)
Create one buffer from another by changing the type.
|
Kernel |
createKernel(double[][] k) |
Kernel |
createKernel(double[][] k,
double divisor) |
NoData |
createNoData(java.lang.Number value,
java.lang.Number defaultValue)
Creates a NoData object.
|
java.util.List<Buffer> |
createOneBufferPerBand(Buffer buffer,
boolean paginated) |
Buffer |
createRGBABuffer(java.awt.image.BufferedImage img,
IProjection projection,
Envelope envelope)
Creates a forced RGBA Buffer from a BufferedImage
|
Buffer |
createRGBBuffer(java.awt.image.BufferedImage img,
IProjection projection,
Envelope envelope)
Creates a forced RGB Buffer from a BufferedImage
|
PageManager |
createSimpleBandPageManager(java.io.File file,
int rows,
int columns,
int dataType) |
java.util.List<PageManager> |
createSimpleBandPageManagerList(java.io.File[] files,
int rows,
int columns,
int[] dataType) |
int |
getBufferTypeFromAwtRaster(java.awt.image.Raster raster) |
java.lang.String |
getBufferTypeName(int dataType) |
int |
getDataTypeSize(int dataType) |
java.io.File |
getLastFolderUsedToSaveRaster() |
java.lang.String |
getTypeName(int type)
Return type's name
|
void |
setLastFolderUsedToSaveRaster(java.io.File folder) |
static final int TYPE_UNDEFINED
static final int TYPE_BYTE
static final int TYPE_USHORT
static final int TYPE_SHORT
static final int TYPE_INT
static final int TYPE_FLOAT
static final int TYPE_DOUBLE
NoData createNoData(java.lang.Number value, java.lang.Number defaultValue)
value
- defaultValue
- BandInfo createBandInfo(int band, java.lang.String name, java.lang.String description, int dataType, java.util.List<java.util.Map.Entry<java.lang.Object,java.lang.Object>> values)
BandInfo
with information about one band.band
- Band of this BandInfo
name
- Band namedescription
- Description of banddataType
- Data type of band. See BufferManager
to check types.values
- A key-value map with information properties about bandBand createBand(int dataType, int rows, int columns, NoData noData, PageManager pageManager) throws BandException
Band
. If PageManager
is null, the band will be
in
memory, otherwise, the band will be paginated using page manager.dataType
- Type of band. Check BufferManager
to see what types
are availablerows
- Band rowscolumns
- Band columnsnoData
- NoData
of band. If It is null, a undefined NoData will
be set.pageManager
- Page manager to paginate band. It page manager is null, band
will be in memory.BandException
- If there are problems creating the band.createNoData(Number, Number)
,
BufferManager#createBandInfo(String, String, List)
,
createSimpleBandPageManager(File, int, int, int)
Buffer createBuffer(int rows, int columns, int[] bandDataTypes, IProjection projection) throws BufferException
rows
- Rows of buffer. All buffer bands will have the same rows as
buffer.columns
- Columns of buffer. All buffer bands will have the same
columns as buffer.bandDataTypes
- Types of buffer bands, see BufferManager
to get types.
The length of array indicates number of buffer bands.projection
- Projection of buffer.BufferException
- If there is any problem creating buffer.Buffer createBuffer(int rows, int columns, int[] bandDataTypes, NoData[] bandNodata, IProjection projection) throws BufferException
rows
- Rows of buffer. All buffer bands will have the same rows as
buffer.columns
- Columns of buffer. All buffer bands will have the same
columns as buffer.bandDataTypes
- Types of buffer bands, see BufferManager
to get types.
The length of array indicates number of buffer bands.bandNodata
- NoData
of each band. It can be null. If there are
bands without NoData object, a undefined NoData will be set.projection
- Projection of buffer.BufferException
- If there is any problem creating buffer.Buffer createBuffer(int rows, int columns, int[] bandDataTypes, NoData[] bandNodata, IProjection projection, Envelope envelope) throws BufferException
rows
- Rows of buffer. All buffer bands will have the same rows as
buffer.columns
- Columns of buffer. All buffer bands will have the same
columns as buffer.bandDataTypes
- Types of buffer bands, see BufferManager
to get types.
The length of array indicates number of buffer bands.bandNodata
- NoData
of each band. If there are bands without NoData
object, a undefined NoData will be set. It can be
null
.projection
- Projection of buffer.envelope
- Envelope of data. It can be null
.BufferException
- If there is any problem creating buffer.Buffer createBuffer(int rows, int columns, int[] bandDataTypes, NoData[] bandNoData, IProjection projection, Envelope envelope, java.util.List<PageManager> pageManagers) throws BufferException
BandPageManager
.rows
- Rows of buffer. All buffer bands will have the same rows as
buffer.columns
- Columns of buffer. All buffer bands will have the same
columns as buffer.bandDataTypes
- Types of buffer bands, see BufferManager
to get types.
The length of array indicates number of buffer bands.bandNoData
- NoData
of each band. If there are bands without NoData
object, a undefined NoData will be set. It can be
null
.projection
- Projection of buffer.envelope
- Envelope of data. It can be null
.pageManagers
- Page manager list to paginate data bands. If there are bands
without page manager,
they will be loaded at memory.BufferException
- If there is any problem creating buffer.Buffer createBuffer(Buffer buffer, boolean paginated) throws BufferException
buffer
- paginated
- BufferException
Buffer createConvertedTypeBuffer(Buffer buffer, int type) throws BufferException
buffer
- type
- BufferException
Buffer createClippedBuffer(Buffer buffer, Envelope envelope) throws BufferException
buffer
- envelope
- BufferException
PageManager createSimpleBandPageManager(java.io.File file, int rows, int columns, int dataType) throws java.io.IOException
file
- rows
- columns
- dataType
- java.io.IOException
java.util.List<PageManager> createSimpleBandPageManagerList(java.io.File[] files, int rows, int columns, int[] dataType) throws java.io.IOException
files
- rows
- columns
- dataType
- java.io.IOException
int getDataTypeSize(int dataType)
dataType
- Data tpyeBand createClippedBand(Buffer buffer, Band band) throws BandException
buffer
- band
- BandException
Band createConvertedTypeBand(Buffer buffer, Band band, int type) throws BandException
buffer
- band
- type
- BandException
Buffer createRGBABuffer(java.awt.image.BufferedImage img, IProjection projection, Envelope envelope) throws BufferException
img
- projection
- envelope
- BufferException
Buffer createRGBBuffer(java.awt.image.BufferedImage img, IProjection projection, Envelope envelope) throws BufferException
img
- projection
- envelope
- BufferException
java.lang.String getTypeName(int type)
type
- java.lang.String getBufferTypeName(int dataType)
dataType
- java.lang.Object coerce(int dataType, java.lang.Object value) throws CoercionException
CoercionException
java.util.List<Buffer> createOneBufferPerBand(Buffer buffer, boolean paginated) throws BufferException
BufferException
BufferDimensions createBufferDimensions(int rows, int columns, Envelope envelope)
rows
- columns
- envelope
- void setLastFolderUsedToSaveRaster(java.io.File folder)
folder
- java.io.File getLastFolderUsedToSaveRaster()
Kernel createKernel(double[][] k)
Kernel createKernel(double[][] k, double divisor)
java.util.List<PageManager> createAwtRasterBandPageManagerList(java.awt.image.Raster img) throws java.io.IOException
img
- java.io.IOException
BandPageManager createAwtRasterBandPageManager(java.awt.image.Raster img, int band)
img
- band
- int getBufferTypeFromAwtRaster(java.awt.image.Raster raster)
raster
- Buffer createBufferFromAwtRaster(java.awt.image.Raster raster, IProjection projection, Envelope envelope) throws java.io.IOException, BufferException
raster
- projection
- envelope
- java.io.IOException
BufferException