es.gva.cit.jgdal
Class Gdal

java.lang.Object
  extended byJNIBase
      extended byes.gva.cit.jgdal.Gdal

public class Gdal
extends JNIBase

Contiene las funcionalidades necesarias para el acceso a los elementos de un dataset de gdal correspondiente a una imágen

See Also:
Serialized Form

Field Summary
static int GA_ReadOnly
           
static int GA_Update
           
static int GDT_Byte
           
static int GDT_CFloat32
           
static int GDT_CFloat64
           
static int GDT_CInt16
           
static int GDT_CInt32
           
static int GDT_Float32
           
static int GDT_Float64
           
static int GDT_Int16
           
static int GDT_Int32
           
static int GDT_TypeCount
           
static int GDT_UInt16
           
static int GDT_UInt32
           
static int GDT_Unknown
           
 
Constructor Summary
Gdal()
          Constructor generico
Gdal(long cPtr)
          Constructor a partir de la dirección de memoria
 
Method Summary
 void close()
          Cierra el fichero de imágen.
static GdalDriver getDriverByName(java.lang.String name)
          Obtiene un driver a través de su nombre
 int getGCPCount()
          Obtiene el número de bandas de la imágen
 GeoTransform getGeoTransform()
          Obtiene el vector geoTransform de la imágen que contiene los valores Origen y pixelSize
 java.lang.String[] getMetadata()
          Obtiene un array de Strings con los metadatos
 java.lang.String getProjectionRef()
          Obtiene el sistema de coordenadas de referencia de la imágen.
 long getPtro()
          Devuelve la dirección de memoria del objeto dataset en C.
 GdalRasterBand getRasterBand(int hBand)
          Obtiene el número de bandas de la imágen
 int getRasterCount()
          Obtiene el número de bandas de la imágen
 int getRasterXSize()
          Obtiene la dimensión del raster en el eje X.
 int getRasterYSize()
          Obtiene la dimensión del raster en el eje Y.
 void open(java.lang.String pszFilename, int access)
          Abre el fichero de imágen.
 void setGeoTransform(GeoTransform gt)
          Añade el vector geoTransform a la imágen que contiene los valores Origen y pixelSize
 void setProjection(java.lang.String proj)
          Asigna la proyección especificada en la cadena que se le pasa por parámetro.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

GA_ReadOnly

public static int GA_ReadOnly

GA_Update

public static int GA_Update

GDT_Unknown

public static int GDT_Unknown

GDT_Byte

public static int GDT_Byte

GDT_UInt16

public static int GDT_UInt16

GDT_Int16

public static int GDT_Int16

GDT_UInt32

public static int GDT_UInt32

GDT_Int32

public static int GDT_Int32

GDT_Float32

public static int GDT_Float32

GDT_Float64

public static int GDT_Float64

GDT_CInt16

public static int GDT_CInt16

GDT_CInt32

public static int GDT_CInt32

GDT_CFloat32

public static int GDT_CFloat32

GDT_CFloat64

public static int GDT_CFloat64

GDT_TypeCount

public static int GDT_TypeCount
Constructor Detail

Gdal

public Gdal(long cPtr)
Constructor a partir de la dirección de memoria


Gdal

public Gdal()
Constructor generico

Method Detail

getPtro

public long getPtro()
Devuelve la dirección de memoria del objeto dataset en C.


open

public void open(java.lang.String pszFilename,
                 int access)
          throws GdalException,
                 java.io.IOException
Abre el fichero de imágen.

Parameters:
pszFilename - Nombre del fichero.
access - Apertura en solo lectura o escritura.
Throws:
GdalException
java.io.IOException

getMetadata

public java.lang.String[] getMetadata()
                               throws GdalException
Obtiene un array de Strings con los metadatos

Returns:
Array de Strings que corresponden a los metadatos que ofrece la imágen
Throws:
GdalException

getRasterBand

public GdalRasterBand getRasterBand(int hBand)
                             throws GdalException
Obtiene el número de bandas de la imágen

Parameters:
hBand - Entero que corresponde al número de banda que se quiere recuperar
Returns:
Objeto GdalRasterBand que representa la banda recuperada
Throws:
GdalException

getRasterXSize

public int getRasterXSize()
                   throws GdalException
Obtiene la dimensión del raster en el eje X.

Returns:
Devuelve un entero con la longitud de la imágen en el eje X en pixels.
Throws:
GdalException

getRasterYSize

public int getRasterYSize()
                   throws GdalException
Obtiene la dimensión del raster en el eje Y.

Returns:
Devuelve un entero con la longitud de la imágen en el eje Y en pixels.
Throws:
GdalException

getRasterCount

public int getRasterCount()
                   throws GdalException
Obtiene el número de bandas de la imágen

Returns:
Devuelve un entero con el número de bandas que contiene la imágen.
Throws:
GdalException

getGeoTransform

public GeoTransform getGeoTransform()
                             throws GdalException
Obtiene el vector geoTransform de la imágen que contiene los valores Origen y pixelSize

Returns:
Devuelve un vector de doubles que contiene los valores de coordenadas de origen y pixelSize.
Throws:
GdalException

setGeoTransform

public void setGeoTransform(GeoTransform gt)
                     throws GdalException
Añade el vector geoTransform a la imágen que contiene los valores Origen y pixelSize

Returns:
Devuelve un vector de doubles que contiene los valores de coordenadas de origen y pixelSize.
Throws:
GdalException

getProjectionRef

public java.lang.String getProjectionRef()
                                  throws GdalException
Obtiene el sistema de coordenadas de referencia de la imágen.

Returns:
Devuelve un String con los datos del sistema de coordenadas de referencia.
Throws:
GdalException

close

public void close()
           throws GdalException
Cierra el fichero de imágen.

Throws:
GdalException

getDriverByName

public static GdalDriver getDriverByName(java.lang.String name)
                                  throws GdalException
Obtiene un driver a través de su nombre

Parameters:
name - Nombre del driver
Throws:
GdalException

getGCPCount

public int getGCPCount()
                throws GdalException
Obtiene el número de bandas de la imágen

Returns:
Devuelve un entero con el número de bandas que contiene la imágen.
Throws:
GdalException

setProjection

public void setProjection(java.lang.String proj)
                   throws GdalException
Asigna la proyección especificada en la cadena que se le pasa por parámetro.

Parameters:
proj - proyección
Throws:
GdalException