|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectes.prodevelop.gvsig.mobile.fmap.driver.raster.ecw.EcwReader
Utility class to access Ermapper's libraries through JNI
EcwRasterDriver
Constructor Summary | |
EcwReader()
|
Method Summary | |
static boolean |
closeEcwFile(long ptr)
Closes the ECW file. |
static double[] |
getEcwImageInfo(long ptr)
Gets metadata from the ECW raster |
static int[] |
getEcwView(long ptr,
double geo_min_x,
double geo_min_y,
double geo_w,
double geo_h,
double filemingeox,
double filemingeoy,
double filexcell,
double ffileycell,
int filew,
int fileh,
int out_w,
int out_h,
int band1,
int band2,
int band3)
Renders the ECW raster as an array of RGB values (one int value for each pixel) |
static byte[] |
getWhiteImage(int w,
int h)
gets the array of bytes (PNG format) representing a white image of the given size. |
static long |
openEcwFile(java.lang.String full_file_path)
Opens ECW file |
static byte[] |
paintArray(int[] bitmap,
int w,
int h,
int offset,
boolean has_transp)
Utility method to convert an array of integers into an array of bytes in the PNG format. |
static void |
setCacheInKBytes(int size)
Sets the cache that Ermapper's DLL is allowed to use. |
static int |
test()
Test method. |
static void |
touch()
Utility method to force the load of the associated DLL. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public EcwReader()
Method Detail |
public static long openEcwFile(java.lang.String full_file_path) throws java.lang.Throwable
full_file_path
- ecw full file path
java.lang.Throwable
public static boolean closeEcwFile(long ptr)
ptr
- handler of the previously opened file
public static int[] getEcwView(long ptr, double geo_min_x, double geo_min_y, double geo_w, double geo_h, double filemingeox, double filemingeoy, double filexcell, double ffileycell, int filew, int fileh, int out_w, int out_h, int band1, int band2, int band3)
ptr
- ECW file handlergeo_min_x
- minimum x in map units of the zone of interestgeo_min_y
- minimum y in map units of the zone of interestgeo_w
- width of the zone of interest in map unitsgeo_h
- height of the zone of interest in map unitsfilemingeox
- minimum x in map units of the rasterfilemingeoy
- minimum y in map units of the rasterfilexcell
- width of each pixels in map unitsffileycell
- height of each pixels in map unitsfilew
- width of the raster in pixelsfileh
- height of the raster in pixelsout_w
- width of the output image in pixelsout_h
- height of the output image in pixelsband1
- first band requestedband2
- second band requestedband3
- third band requested
public static double[] getEcwImageInfo(long ptr)
ptr
- the file handler
public static byte[] paintArray(int[] bitmap, int w, int h, int offset, boolean has_transp)
bitmap
- raster as an array of integersw
- image width in pixelsh
- image height in pixelsoffset
- offset in the array of integershas_transp
- whether the integers include an alpha band
public static int test()
public static void setCacheInKBytes(int size)
size
- cache limits in kilobytespublic static byte[] getWhiteImage(int w, int h)
w
- image widthh
- image height
public static void touch()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |