OSSIM - Open Source Software Image Map
Version 1.9.0 (20180803)
include
ossim
support_data
ossimAigHeader.h
Go to the documentation of this file.
1
//*******************************************************************
2
//
3
// License: See top level LICENSE.txt file.
4
//
5
// Author: Garrett Potts (gpotts@imagelinks.com)
6
//
7
//*******************************************************************
8
// $Id: ossimAigHeader.h 9968 2006-11-29 14:01:53Z gpotts $
9
10
#ifndef ossimAigHeader_HEADER
11
#define ossimAigHeader_HEADER
12
#include <iostream>
13
#include <
ossim/base/ossimConstants.h
>
14
#include "string.h"
15
16
class
ossimAigHeader
17
{
18
public
:
19
friend
std::ostream
&
operator <<
(
std::ostream
& out,
const
ossimAigHeader
& header)
20
{
21
out <<
"Magic number: "
<< header.
theMagic
<< std::endl
22
<<
"Coverage: "
<< (header.
theCellType
==1?
"Integer"
:
"float"
) << std::endl
23
<<
"Pixel size x: "
<< header.
thePixelSizeX
<< std::endl
24
<<
"Pixel size y: "
<< header.
thePixelSizeY
<< std::endl
25
<<
"Tiles per row: "
<< header.
theNumberOfTilesPerRow
<< std::endl
26
<<
"Tiles per col: "
<< header.
theNumberOfTilesPerColumn
<< std::endl
27
<<
"Tile width: "
<< header.
theWidthOfTileInPixels
<< std::endl
28
<<
"Tile height: "
<< header.
theHeightOfTileInPixels
;
29
30
return
out;
31
}
32
ossimAigHeader
()
33
{
34
reset
();
35
}
36
37
void
reset
()
38
{
39
memset(
theMagic
,
'\0'
, 8);
40
strcpy(
theMagic
,
"GRID1.2"
);
41
memset(
theUnknownData
,
'\0'
, 8);
42
setIntCoverage
();
43
memset(
theUnknownAssortedData
,
'\0'
, 236);
44
thePixelSizeX
= 1.0;
45
thePixelSizeY
= 1.0;
46
theUnknownGeoReferencingValues
[0] = 0.0;
47
theUnknownGeoReferencingValues
[1] = 0.0;
48
theNumberOfTilesPerRow
= 0;
49
theNumberOfTilesPerColumn
= 0;
50
theWidthOfTileInPixels
= 0;
51
theUnknownValue
= 1;
52
theHeightOfTileInPixels
= 0;
53
}
54
55
bool
writeStream
(
std::ostream
& out);
56
57
void
setFloatCoverage
()
58
{
59
theCellType
= 2;
60
}
61
void
setIntCoverage
()
62
{
63
theCellType
= 1;
64
}
65
char
theMagic
[8];
66
char
theUnknownData
[8];
67
71
ossim_int32
theCellType
;
72
73
char
theUnknownAssortedData
[236];
74
79
double
thePixelSizeX
;
80
85
double
thePixelSizeY
;
86
87
double
theUnknownGeoReferencingValues
[2];
88
92
int
theNumberOfTilesPerRow
;
93
97
int
theNumberOfTilesPerColumn
;
98
103
int
theWidthOfTileInPixels
;
104
105
int
theUnknownValue
;
106
111
int
theHeightOfTileInPixels
;
112
};
113
114
#endif
ossimAigHeader::theUnknownValue
int theUnknownValue
Definition:
ossimAigHeader.h:105
ossimAigHeader::reset
void reset()
Definition:
ossimAigHeader.h:37
ossimAigHeader::operator<<
friend std::ostream & operator<<(std::ostream &out, const ossimAigHeader &header)
Definition:
ossimAigHeader.h:19
ossimConstants.h
ossimAigHeader::theNumberOfTilesPerColumn
int theNumberOfTilesPerColumn
Definition:
ossimAigHeader.h:97
ossimAigHeader::writeStream
bool writeStream(std::ostream &out)
Definition:
ossimAigHeader.cpp:12
ossimAigHeader::ossimAigHeader
ossimAigHeader()
Definition:
ossimAigHeader.h:32
ossimAigHeader::setIntCoverage
void setIntCoverage()
Definition:
ossimAigHeader.h:61
ossimAigHeader::theNumberOfTilesPerRow
int theNumberOfTilesPerRow
Definition:
ossimAigHeader.h:92
ossimAigHeader::theWidthOfTileInPixels
int theWidthOfTileInPixels
Definition:
ossimAigHeader.h:103
ossimAigHeader::theUnknownGeoReferencingValues
double theUnknownGeoReferencingValues[2]
Definition:
ossimAigHeader.h:87
ossimAigHeader::theHeightOfTileInPixels
int theHeightOfTileInPixels
Definition:
ossimAigHeader.h:111
ossimAigHeader::thePixelSizeX
double thePixelSizeX
Definition:
ossimAigHeader.h:79
ossimAigHeader::theUnknownAssortedData
char theUnknownAssortedData[236]
Definition:
ossimAigHeader.h:73
ossimAigHeader::thePixelSizeY
double thePixelSizeY
Definition:
ossimAigHeader.h:85
ossimAigHeader::setFloatCoverage
void setFloatCoverage()
Definition:
ossimAigHeader.h:57
ossimAigHeader::theMagic
char theMagic[8]
Definition:
ossimAigHeader.h:65
ossimAigHeader
Definition:
ossimAigHeader.h:16
ossimAigHeader::theUnknownData
char theUnknownData[8]
Definition:
ossimAigHeader.h:66
ossim::ostream
std::basic_ostream< char > ostream
Base class for char output streams.
Definition:
ossimIosFwd.h:23
ossimAigHeader::theCellType
ossim_int32 theCellType
Definition:
ossimAigHeader.h:71
ossim_int32
int ossim_int32
Definition:
ossimConstants.h:234
Generated on Fri Aug 3 2018 08:46:45 for OSSIM - Open Source Software Image Map by
1.8.14