svn-gvsig-desktop / tags / v1_0_2_Build_904 / libraries / libjni-ecw / include / NCSJPCMarker.h @ 43469
History | View | Annotate | Download (2.68 KB)
1 | 3538 | nacho | /********************************************************
|
---|---|---|---|
2 | ** Copyright 2002 Earth Resource Mapping Ltd.
|
||
3 | ** This document contains proprietary source code of
|
||
4 | ** Earth Resource Mapping Ltd, and can only be used under
|
||
5 | ** one of the three licenses as described in the
|
||
6 | ** license.txt file supplied with this distribution.
|
||
7 | ** See separate license.txt file for license details
|
||
8 | ** and conditions.
|
||
9 | **
|
||
10 | ** This software is covered by US patent #6,442,298,
|
||
11 | ** #6,102,897 and #6,633,688. Rights to use these patents
|
||
12 | ** is included in the license agreements.
|
||
13 | **
|
||
14 | ** FILE: $Archive: /NCS/Source/include/NCSJPCMarker.h $
|
||
15 | ** CREATED: 11/12/2002 3:27:34 PM
|
||
16 | ** AUTHOR: Simon Cope
|
||
17 | ** PURPOSE: CNCSJPCMarker class header
|
||
18 | ** EDITS: [xx] ddMmmyy NAME COMMENTS
|
||
19 | *******************************************************/
|
||
20 | |||
21 | #ifndef NCSJPCMARKER_H
|
||
22 | #define NCSJPCMARKER_H
|
||
23 | |||
24 | // Our own 64bit IOSTREAM class
|
||
25 | #ifndef NCSJPCIOSTREAM_H
|
||
26 | #include "NCSJPCIOStream.h" |
||
27 | #endif // NCSJPCIOSTREAM_H |
||
28 | |||
29 | |||
30 | |||
31 | /**
|
||
32 | * CNCSJPCMarker class - the base JPC codestream marker.
|
||
33 | *
|
||
34 | * @author Simon Cope
|
||
35 | * @version $Revision$ $Author$ $Date$
|
||
36 | */
|
||
37 | class NCSJPC_EXPORT_ALL CNCSJPCMarker { |
||
38 | public:
|
||
39 | typedef enum { |
||
40 | UNKNOWN = 0x0000,
|
||
41 | SOC = 0xFF4F,
|
||
42 | SIZ = 0xFF51,
|
||
43 | COD = 0xFF52,
|
||
44 | COC = 0xFF53,
|
||
45 | TLM = 0xFF55,
|
||
46 | PLM = 0xFF57,
|
||
47 | PLT = 0xFF58,
|
||
48 | QCD = 0xFF5C,
|
||
49 | QCC = 0xFF5D,
|
||
50 | RGN = 0xFF5E,
|
||
51 | POC = 0xFF5F,
|
||
52 | PPM = 0xFF60,
|
||
53 | PPT = 0xFF61,
|
||
54 | CRG = 0xFF63,
|
||
55 | COM = 0xFF64,
|
||
56 | SOT = 0xFF90,
|
||
57 | SOP = 0xFF91,
|
||
58 | EPH = 0xFF92,
|
||
59 | SOD = 0xFF93,
|
||
60 | EOC = 0xFFD9
|
||
61 | } Type; |
||
62 | |||
63 | /** Marker type */
|
||
64 | Type m_eMarker; |
||
65 | |||
66 | /** Marker Offset into stream */
|
||
67 | UINT64 m_nOffset; |
||
68 | /** Marker Length */
|
||
69 | UINT16 m_nLength; |
||
70 | /** Do we have this marker */
|
||
71 | bool m_bHaveMarker;
|
||
72 | /** Is this marker valid */
|
||
73 | bool m_bValid;
|
||
74 | |||
75 | /** Default constructor, initialises members */
|
||
76 | CNCSJPCMarker(); |
||
77 | /** Virtual destructor */
|
||
78 | virtual ~CNCSJPCMarker(); |
||
79 | |||
80 | /**
|
||
81 | * Parse the marker from the JPC codestream.
|
||
82 | * @param JPC CNCSJPC to use to parse file.
|
||
83 | * @param Stream IOStream to use to parse file.
|
||
84 | * @return CNCSError NCS_SUCCESS, or Error code on failure.
|
||
85 | */
|
||
86 | virtual CNCSError Parse(class CNCSJPC &JPC, CNCSJPCIOStream &Stream); |
||
87 | /**
|
||
88 | * UnParse the marker to the JPC codestream.
|
||
89 | * @param Stream IOStream to use to parse file.
|
||
90 | * @param JPC CNCSJPC to use to parse file.
|
||
91 | * @return CNCSError NCS_SUCCESS, or Error code on failure.
|
||
92 | */
|
||
93 | virtual CNCSError UnParse(class CNCSJPC &JPC, CNCSJPCIOStream &Stream); |
||
94 | |||
95 | |||
96 | /**
|
||
97 | * Get length of a packet in the file.
|
||
98 | * @param src Copy source
|
||
99 | * @return void
|
||
100 | */
|
||
101 | void CNCSJPCMarker::operator=( const class CNCSJPCMarker& src ); |
||
102 | }; |
||
103 | |||
104 | #endif // !NCSJPCMARKER_H |