gvsig-raster / org.gvsig.raster.gdal / tags / pre-remove-jgdal / org.gvsig.raster.gdal / org.gvsig.raster.gdal.io / src / main / java / org / gvsig / jgdal / JNIBase.java @ 3497
History | View | Annotate | Download (3.13 KB)
1 |
/* gvSIG. Geographic Information System of the Valencian Government
|
---|---|
2 |
*
|
3 |
* Copyright (C) 2007-2008 Infrastructures and Transports Department
|
4 |
* of the Valencian Government (CIT)
|
5 |
*
|
6 |
* This program is free software; you can redistribute it and/or
|
7 |
* modify it under the terms of the GNU General Public License
|
8 |
* as published by the Free Software Foundation; either version 2
|
9 |
* of the License, or (at your option) any later version.
|
10 |
*
|
11 |
* This program is distributed in the hope that it will be useful,
|
12 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14 |
* GNU General Public License for more details.
|
15 |
*
|
16 |
* You should have received a copy of the GNU General Public License
|
17 |
* along with this program; if not, write to the Free Software
|
18 |
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
|
19 |
* MA 02110-1301, USA.
|
20 |
*
|
21 |
*/
|
22 |
|
23 |
|
24 |
/**
|
25 |
* @author Nacho Brodin <nachobrodin@gmail.com>.<BR> Equipo de desarrollo gvSIG.<BR> http://www.gvsig.gva.es
|
26 |
* @version 0.0
|
27 |
* @link http://www.gvsig.gva.es
|
28 |
*/
|
29 |
|
30 |
package org.gvsig.jgdal; |
31 |
|
32 |
import org.gdal.gdal.gdalJNI; |
33 |
|
34 |
public class JNIBase extends gdalJNI{ |
35 |
//
|
36 |
protected long cPtr; |
37 |
//
|
38 |
//// private native int getRasterBandXSizeNat(long cPtr);
|
39 |
//// private native int getRasterBandYSizeNat(long cPtr);
|
40 |
//// private native int getOverviewCountNat(long cPtr);
|
41 |
//// private native int getBlockXSizeNat(long cPtr);
|
42 |
//// private native int getBlockYSizeNat(long cPtr);
|
43 |
//// private native int getRasterXSizeNat(long cPtr);
|
44 |
//// private native int getRasterYSizeNat(long cPtr);
|
45 |
//// private native int getRasterCountNat(long cPtr);
|
46 |
//// private native int getGCPCountNat(long cPtr);
|
47 |
//// private native int getRasterDataTypeNat(long cPtr);
|
48 |
//// private native int getDriverCountNat(long cPtr);
|
49 |
//// private native int getLayerCountNat(long cPtr);
|
50 |
//
|
51 |
//
|
52 |
// /**
|
53 |
// * Funci?n que sirve como base para funcionalidades de gdal que admiten como par?metro un entero y devuelven un entero.
|
54 |
// *
|
55 |
// * @throws GdalException.
|
56 |
// * @param msg1 Mensaje de error que se muestra cuando el puntero a objeto pasado es vacio.
|
57 |
// * @param msg2 Mensaje de error que se muestra cuando el resultado de la llamada a la funci?n de gdal es menor o igual que 0.
|
58 |
// */
|
59 |
//
|
60 |
//
|
61 |
// protected int baseSimpleFunctions(int n,String msg1,String msg2)throws GdalException{
|
62 |
//
|
63 |
// int res = 0;
|
64 |
//
|
65 |
// switch(n){
|
66 |
// case 0: res = getRasterBandXSizeNat(cPtr);break;
|
67 |
// case 1: res = getRasterBandYSizeNat(cPtr);break;
|
68 |
// case 2: res = getOverviewCountNat(cPtr);break;
|
69 |
// case 3: res = getBlockXSizeNat(cPtr);break;
|
70 |
// case 4: res = getBlockYSizeNat(cPtr);break;
|
71 |
// case 5: res = getRasterXSizeNat(cPtr);break;
|
72 |
// case 6: res = getRasterYSizeNat(cPtr);break;
|
73 |
// case 7: res = getRasterCountNat(cPtr);break;
|
74 |
// case 8: res = getGCPCountNat(cPtr);break;
|
75 |
// case 9: res = getRasterDataTypeNat(cPtr);break;
|
76 |
// }
|
77 |
//
|
78 |
// if (res < 0)
|
79 |
// throw new GdalException(msg2);
|
80 |
// else
|
81 |
// return res;
|
82 |
// }
|
83 |
//
|
84 |
// static {
|
85 |
// /*String os = System.getProperty("os.name");
|
86 |
// if (os.toLowerCase().startsWith("windows"))
|
87 |
// System.loadLibrary("jgdal201");
|
88 |
// else*/
|
89 |
// System.loadLibrary("jgdal2.0.4");
|
90 |
// }
|
91 |
} |