Hoyt's FORK of DemoIccMAX 2.1.17.hoyt
Documentation for Hoyt's FORK of DemoIccMAX
Loading...
Searching...
No Matches
IccTagXmlFactory.cpp
Go to the documentation of this file.
1/** @file
2File: IccTagXMLFactory.cpp
3
4Contains: Implementation of the CIccTag class and creation factories
5
6Version: V1
7
8Copyright: (c) see ICC Software License
9*/
10
11/*
12 * The ICC Software License, Version 0.2
13 *
14 *
15 * Copyright (c) 2003-2012 The International Color Consortium. All rights
16 * reserved.
17 *
18 * Redistribution and use in source and binary forms, with or without
19 * modification, are permitted provided that the following conditions
20 * are met:
21 *
22 * 1. Redistributions of source code must retain the above copyright
23 * notice, this list of conditions and the following disclaimer.
24 *
25 * 2. Redistributions in binary form must reproduce the above copyright
26 * notice, this list of conditions and the following disclaimer in
27 * the documentation and/or other materials provided with the
28 * distribution.
29 *
30 * 3. In the absence of prior written permission, the names "ICC" and "The
31 * International Color Consortium" must not be used to imply that the
32 * ICC organization endorses or promotes products derived from this
33 * software.
34 *
35 *
36 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
37 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
38 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
39 * DISCLAIMED. IN NO EVENT SHALL THE INTERNATIONAL COLOR CONSORTIUM OR
40 * ITS CONTRIBUTING MEMBERS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
41 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
42 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
43 * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
44 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
45 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
46 * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
47 * SUCH DAMAGE.
48 * ====================================================================
49 *
50 * This software consists of voluntary contributions made by many
51 * individuals on behalf of the The International Color Consortium.
52 *
53 *
54 * Membership in the ICC is encouraged when this software is used for
55 * commercial purposes.
56 *
57 *
58 * For more information on The International Color Consortium, please
59 * see <http://www.color.org/>.
60 *
61 *
62 */
63
64#include "IccTagXml.h"
65#include "IccTagXmlFactory.h"
66#include "IccUtil.h"
67#include "IccProfile.h"
68
69#ifdef USEREFICCMAXNAMESPACE
70namespace refIccMAX {
71#endif
72
74{
75 switch(tagSig) {
77 return new CIccTagXmlSignature;
78
79 case icSigTextType:
80 return new CIccTagXmlText;
81
83 return new CIccTagXmlXYZ;
84
85 case icSigCicpType:
86 return new CIccTagXmlCicp;
87
89 return new CIccTagXmlUInt8;
90
92 return new CIccTagXmlUInt16;
93
95 return new CIccTagXmlUInt32;
96
98 return new CIccTagXmlUInt64;
99
101 return new CIccTagXmlS15Fixed16;
102
104 return new CIccTagXmlU16Fixed16;
105
107 return new CIccTagXmlFloat16;
108
110 return new CIccTagXmlFloat32;
111
113 return new CIccTagXmlFloat64;
114
117
118 case icSigCurveType:
119 return new CIccTagXmlCurve;
120
122 return new CIccTagXmlSegmentedCurve;
123
125 return new CIccTagXmlMeasurement;
126
129
132
134 return new CIccTagXmlParametricCurve;
135
136 case icSigLutAtoBType:
137 return new CIccTagXmlLutAtoB;
138
139 case icSigLutBtoAType:
140 return new CIccTagXmlLutBtoA;
141
142 case icSigLut16Type:
143 return new CIccTagXmlLut16;
144
145 case icSigLut8Type:
146 return new CIccTagXmlLut8;
147
149 return new CIccTagXmlTextDescription;
150
152 return new CIccTagXmlNamedColor2;
153
155 return new CIccTagXmlChromaticity;
156
157 case icSigDataType:
158 return new CIccTagXmlTagData;
159
161 return new CIccTagXmlDateTime;
162
164 return new CIccTagXmlColorantOrder;
165
167 return new CIccTagXmlColorantTable;
168
171
174
177
180
182 return new CIccTagXmlProfileSeqDesc;
183
186
189
190 case icSigDictType:
191 return new CIccTagXmlDict;
192
194 return new CIccTagXmlStruct;
195
197 return new CIccTagXmlArray;
198
200 return new CIccTagXmlUtf8Text;
201
203 return new CIccTagXmlZipUtf8Text;
204
205 case icSigZipXmlType:
206 return new CIccTagXmlZipXml;
207
209 return new CIccTagXmlUtf16Text;
210
212 return new CIccTagXmlEmbeddedProfile;
213
216
219
221 case icSigUcrBgType:
222 case icSigCrdInfoType:
223
224 default:
225 return new CIccTagXmlUnknown(tagSig);
226 }
227}
228
230{
231 return NULL;
232}
233
238
240{
241 return NULL;
242}
243
248
249#ifdef USEREFICCMAXNAMESPACE
250}
251#endif
252
char icChar
Definition IccDefs.h:109
File: IccProfile.h.
const icChar * szName
File: IccTagXml.h.
CIccTagXmlFloatNum< icFloat32Number, CIccXmlArrayType< icFloat32Number, icSigFloat32ArrayType >, icSigFloat32ArrayType > CIccTagXmlFloat32
Definition IccTagXml.h:337
CIccTagXmlNum< icUInt16Number, CIccXmlArrayType< icUInt16Number, icSigUInt16ArrayType >, icSigUInt16ArrayType > CIccTagXmlUInt16
Definition IccTagXml.h:318
CIccTagXmlFloatNum< icFloat64Number, CIccXmlArrayType< icFloat64Number, icSigFloat64ArrayType >, icSigFloat64ArrayType > CIccTagXmlFloat64
Definition IccTagXml.h:338
CIccTagXmlNum< icUInt32Number, CIccXmlArrayType< icUInt32Number, icSigUInt32ArrayType >, icSigUInt32ArrayType > CIccTagXmlUInt32
Definition IccTagXml.h:319
CIccTagFixedNum< icU16Fixed16Number, icSigU16Fixed16ArrayType > CIccTagXmlU16Fixed16
Definition IccTagXml.h:297
CIccTagXmlNum< icUInt8Number, CIccXmlArrayType< icUInt8Number, icSigUInt8ArrayType >, icSigUInt8ArrayType > CIccTagXmlUInt8
Definition IccTagXml.h:317
CIccTagXmlFixedNum< icS15Fixed16Number, icSigS15Fixed16ArrayType > CIccTagXmlS15Fixed16
Definition IccTagXml.h:296
CIccTagXmlFloatNum< icFloat32Number, CIccXmlArrayType< icFloat32Number, icSigFloat32ArrayType >, icSigFloat16ArrayType > CIccTagXmlFloat16
Definition IccTagXml.h:336
CIccTagXmlNum< icUInt64Number, CIccXmlArrayType< icUInt64Number, icSigUInt64ArrayType >, icSigUInt64ArrayType > CIccTagXmlUInt64
Definition IccTagXml.h:320
File: IccTagXmlFactory.h.
File: IccUtil.h.
icTagTypeSignature
@ icSigUInt16ArrayType
Class: CIccTag.
virtual const icChar * GetTagTypeSigName(icTagTypeSignature tagTypeSig)
Function: GetTagTypeSigName(tagTypeSig) Get display name of tagTypeSig.
virtual icTagTypeSignature GetTagTypeNameSig(const icChar *szTypeName)
Function: GetTagTypeNameSig(szTypeName) Get signature based on display name of tag type.
virtual CIccTag * CreateTag(icTagTypeSignature tagSig)
Function: CreateTag(tagTypeSig) Create a tag of type tagTypeSig.
virtual icTagSignature GetTagNameSig(const icChar *szTagName)
Function: GetTagNameSig(szTagName) Get signature from tag display name.
virtual const icChar * GetTagSigName(icTagSignature tagSig)
Function: GetTagSigName(tagSig) Get display name of tagSig.
#define icSigUnknownType
Convenience Enum Definitions - Not defined in ICC specification.
@ icSigSegmentedCurveType
@ icSigCicpType
@ icSigSpectralDataInfoType
@ icSigUInt8ArrayType
@ icSigDataType
@ icSigUtf8TextType
@ icSigProfileSequceIdType
@ icSigProfileSequenceDescType
@ icSigEmbeddedProfileType
@ icSigTagArrayType
@ icSigMultiProcessElementType
@ icSigXYZArrayType
@ icSigMeasurementType
@ icSigTagStructType
@ icSigSparseMatrixArrayType
@ icSigEmbeddedHeightImageType
@ icSigFloat16ArrayType
@ icSigParametricCurveType
@ icSigLut8Type
@ icSigMultiLocalizedUnicodeType
@ icSigLutBtoAType
@ icSigResponseCurveSet16Type
@ icSigS15Fixed16ArrayType
@ icSigUtf16TextType
@ icSigColorantTableType
@ icSigViewingConditionsType
@ icSigTextDescriptionType
@ icSigEmbeddedNormalImageType
@ icSigCurveType
@ icSigColorantOrderType
@ icSigDateTimeType
@ icSigFloat64ArrayType
@ icSigLut16Type
@ icSigScreeningType
@ icSigUInt64ArrayType
@ icSigTextType
@ icSigSpectralViewingConditionsType
@ icSigZipXmlType
@ icSigNamedColor2Type
@ icSigU16Fixed16ArrayType
@ icSigChromaticityType
@ icSigSignatureType
@ icSigZipUtf8TextType
@ icSigFloat32ArrayType
@ icSigUcrBgType
@ icSigCrdInfoType
@ icSigLutAtoBType
@ icSigDictType
@ icSigUInt32ArrayType
@ icSigGamutBoundaryDescType
#define icSigUnknownTag
Convenience Enum Definitions - Not defined in ICC specification.
icTagSignature
public tags and sizes