Class WorldFileWriter
MathTransform
or AffineTransform
.
The content of a world file describes an affine transformation which was used by the ESRI software to map from the rater world to the spatial world (what we usually call a grid to world transform).
Specifically a world file should be as follows:
scalex shearx sheary scaley upperleftx upperlefty
which translates into the following affine transformation.
| : | | scalex shearx : translatex| | : | | sheary scaley : transaltey| |----------------------------| | 0 0 : 1 | | : |
Note that a world file usually takes as reference the centre of the pixel.
- Author:
- Simone Giannecchini, GeoSolutions
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
Default buffer size we wil luse to write out. -
Constructor Summary
ConstructorsConstructorDescriptionWorldFileWriter
(File outLocation, AffineTransform transform) Constructor.WorldFileWriter
(File outLocation, AffineTransform transform, int buffSize) Constructor.WorldFileWriter
(File outLocation, MathTransform transform) Constructor.WorldFileWriter
(File outLocation, MathTransform transform, int buffSize) Constructor.WorldFileWriter
(OutputStream outLocation, AffineTransform transform) Constructor.WorldFileWriter
(OutputStream outLocation, AffineTransform transform, int buffSize) Constructor.WorldFileWriter
(OutputStream outLocation, MathTransform transform) Constructor.WorldFileWriter
(OutputStream outLocation, MathTransform transform, int buffSize) Constructor. -
Method Summary
-
Field Details
-
DEFAULT_BUFFER_SIZE
public static final int DEFAULT_BUFFER_SIZEDefault buffer size we wil luse to write out.- See Also:
-
-
Constructor Details
-
WorldFileWriter
Constructor.- Parameters:
outLocation
- where to create the world file.transform
- the transformation that we want to write out.- Throws:
IOException
- in case something bad happens.
-
WorldFileWriter
public WorldFileWriter(File outLocation, AffineTransform transform, int buffSize) throws IOException Constructor.- Parameters:
outLocation
- where to create the world file.transform
- the transformation that we want to write out.buffSize
- size of the buffer to use.- Throws:
IOException
- in case something bad happens.
-
WorldFileWriter
Constructor.- Parameters:
outLocation
- where to create the world file.transform
- the transformation that we want to write out.- Throws:
IOException
- in case something bad happens.
-
WorldFileWriter
public WorldFileWriter(OutputStream outLocation, AffineTransform transform, int buffSize) throws IOException Constructor.- Parameters:
outLocation
- where to create the world file.transform
- the transformation that we want to write out.buffSize
- size of the buffer to use.- Throws:
IOException
- in case something bad happens.
-
WorldFileWriter
Constructor.Note that the
MathTransform
must be a 2D affine transform.- Parameters:
outLocation
- where to create the world file.transform
- the transformation that we want to write out.- Throws:
IOException
- in case something bad happens.
-
WorldFileWriter
public WorldFileWriter(OutputStream outLocation, MathTransform transform, int buffSize) throws IOException Constructor.Note that the
MathTransform
must be a 2D affine transform.- Parameters:
outLocation
- where to create the world file.transform
- the transformation that we want to write out.buffSize
- size of the buffer to use.- Throws:
IOException
- in case something bad happens.
-
WorldFileWriter
Constructor.Note that the
MathTransform
must be a 2D affine transform.- Parameters:
outLocation
- where to create the world file.transform
- the transformation that we want to write out.buffSize
- size of the buffer to use.- Throws:
IOException
- in case something bad happens.
-
WorldFileWriter
Constructor.Note that the
MathTransform
must be a 2D affine transform.- Parameters:
outLocation
- where to create the world file.transform
- the transformation that we want to write out.- Throws:
IOException
- in case something bad happens.
-