svn-gvsig-desktop / tags / v1_0_1_RELEASE / libraries / libjni-gdal / include / bsb_read.h @ 9531
History | View | Annotate | Download (3.71 KB)
1 |
/******************************************************************************
|
---|---|
2 |
* $Id: bsb_read.h 9531 2007-01-03 17:07:37Z $
|
3 |
*
|
4 |
* Project: BSB Reader
|
5 |
* Purpose: non-GDAL BSB API Declarations
|
6 |
* Author: Frank Warmerdam, warmerdam@pobox.com
|
7 |
*
|
8 |
******************************************************************************
|
9 |
* Copyright (c) 2001, Frank Warmerdam
|
10 |
*
|
11 |
* Permission is hereby granted, free of charge, to any person obtaining a
|
12 |
* copy of this software and associated documentation files (the "Software"),
|
13 |
* to deal in the Software without restriction, including without limitation
|
14 |
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
15 |
* and/or sell copies of the Software, and to permit persons to whom the
|
16 |
* Software is furnished to do so, subject to the following conditions:
|
17 |
*
|
18 |
* The above copyright notice and this permission notice shall be included
|
19 |
* in all copies or substantial portions of the Software.
|
20 |
*
|
21 |
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
22 |
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
23 |
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
|
24 |
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
25 |
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
26 |
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
27 |
* DEALINGS IN THE SOFTWARE.
|
28 |
******************************************************************************
|
29 |
*
|
30 |
* $Log$
|
31 |
* Revision 1.2.10.2 2006-11-15 00:08:29 jjdelcerro
|
32 |
* *** empty log message ***
|
33 |
*
|
34 |
* Revision 1.3 2006/10/03 07:04:43 nacho
|
35 |
* Fusi?n lo de las proyecciones con piloto.
|
36 |
*
|
37 |
* Revision 1.1 2006/07/18 16:21:00 nacho
|
38 |
* *** empty log message ***
|
39 |
*
|
40 |
* Revision 1.1 2006/06/29 16:23:27 nacho
|
41 |
* *** empty log message ***
|
42 |
*
|
43 |
* Revision 1.2 2006/01/09 12:50:13 nacho
|
44 |
* *** empty log message ***
|
45 |
*
|
46 |
* Revision 1.1 2005/07/27 08:22:55 igbrotru
|
47 |
* *** empty log message ***
|
48 |
*
|
49 |
* Revision 1.1 2004/12/28 14:06:59 igbrotru
|
50 |
* *** empty log message ***
|
51 |
*
|
52 |
* Revision 1.1 2004/10/28 12:08:47 igbrotru
|
53 |
* *** empty log message ***
|
54 |
*
|
55 |
* Revision 1.1 2004/09/27 08:27:48 igbrotru
|
56 |
* *** empty log message ***
|
57 |
*
|
58 |
* Revision 1.1 2004/09/08 12:39:04 igbrotru
|
59 |
* *** empty log message ***
|
60 |
*
|
61 |
* Revision 1.5 2002/11/04 04:26:45 warmerda
|
62 |
* preliminary work on write support
|
63 |
*
|
64 |
* Revision 1.4 2002/07/19 22:05:15 warmerda
|
65 |
* added support for NO1 (encrypted) files
|
66 |
*
|
67 |
* Revision 1.3 2002/07/19 20:32:57 warmerda
|
68 |
* added nVersion to structure.
|
69 |
*
|
70 |
* Revision 1.2 2001/12/08 21:58:32 warmerda
|
71 |
* save header
|
72 |
*
|
73 |
* Revision 1.1 2001/12/08 04:35:16 warmerda
|
74 |
* New
|
75 |
*
|
76 |
*/
|
77 |
|
78 |
#ifndef _BSBREAD_H_INCLUDED
|
79 |
#define _BSBREAD_H_INCLUDED
|
80 |
|
81 |
#include "cpl_port.h" |
82 |
|
83 |
CPL_C_START |
84 |
|
85 |
typedef struct { |
86 |
FILE *fp; |
87 |
|
88 |
int nXSize;
|
89 |
int nYSize;
|
90 |
|
91 |
int nPCTSize;
|
92 |
unsigned char *pabyPCT; |
93 |
|
94 |
char **papszHeader;
|
95 |
|
96 |
int *panLineOffset;
|
97 |
|
98 |
int nColorSize;
|
99 |
|
100 |
int nVersion; /* times 100 */ |
101 |
|
102 |
int bNO1;
|
103 |
|
104 |
int bNewFile;
|
105 |
int nLastLineWritten;
|
106 |
} BSBInfo; |
107 |
|
108 |
BSBInfo CPL_DLL *BSBOpen( const char *pszFilename ); |
109 |
int CPL_DLL BSBReadScanline( BSBInfo *psInfo, int nScanline, |
110 |
unsigned char *pabyScanlineBuf ); |
111 |
void CPL_DLL BSBClose( BSBInfo *psInfo );
|
112 |
|
113 |
BSBInfo CPL_DLL *BSBCreate( const char *pszFilename, int nCreationFlags, |
114 |
int nVersion, int nXSize, int nYSize ); |
115 |
int CPL_DLL BSBWritePCT( BSBInfo *psInfo,
|
116 |
int nPCTSize, unsigned char *pabyPCT ); |
117 |
int CPL_DLL BSBWriteScanline( BSBInfo *psInfo,
|
118 |
unsigned char *pabyScanlineBuf ); |
119 |
|
120 |
CPL_C_END |
121 |
|
122 |
|
123 |
#endif /* ndef _BSBREAD_H_INCLUDED */ |