jas_icc.h 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407
  1. /*
  2. * Copyright (c) 2002-2003 Michael David Adams.
  3. * All rights reserved.
  4. */
  5. /* __START_OF_JASPER_LICENSE__
  6. *
  7. * JasPer License Version 2.0
  8. *
  9. * Copyright (c) 2001-2006 Michael David Adams
  10. * Copyright (c) 1999-2000 Image Power, Inc.
  11. * Copyright (c) 1999-2000 The University of British Columbia
  12. *
  13. * All rights reserved.
  14. *
  15. * Permission is hereby granted, free of charge, to any person (the
  16. * "User") obtaining a copy of this software and associated documentation
  17. * files (the "Software"), to deal in the Software without restriction,
  18. * including without limitation the rights to use, copy, modify, merge,
  19. * publish, distribute, and/or sell copies of the Software, and to permit
  20. * persons to whom the Software is furnished to do so, subject to the
  21. * following conditions:
  22. *
  23. * 1. The above copyright notices and this permission notice (which
  24. * includes the disclaimer below) shall be included in all copies or
  25. * substantial portions of the Software.
  26. *
  27. * 2. The name of a copyright holder shall not be used to endorse or
  28. * promote products derived from the Software without specific prior
  29. * written permission.
  30. *
  31. * THIS DISCLAIMER OF WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS
  32. * LICENSE. NO USE OF THE SOFTWARE IS AUTHORIZED HEREUNDER EXCEPT UNDER
  33. * THIS DISCLAIMER. THE SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS
  34. * "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
  35. * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
  36. * PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. IN NO
  37. * EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL
  38. * INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING
  39. * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
  40. * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
  41. * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. NO ASSURANCES ARE
  42. * PROVIDED BY THE COPYRIGHT HOLDERS THAT THE SOFTWARE DOES NOT INFRINGE
  43. * THE PATENT OR OTHER INTELLECTUAL PROPERTY RIGHTS OF ANY OTHER ENTITY.
  44. * EACH COPYRIGHT HOLDER DISCLAIMS ANY LIABILITY TO THE USER FOR CLAIMS
  45. * BROUGHT BY ANY OTHER ENTITY BASED ON INFRINGEMENT OF INTELLECTUAL
  46. * PROPERTY RIGHTS OR OTHERWISE. AS A CONDITION TO EXERCISING THE RIGHTS
  47. * GRANTED HEREUNDER, EACH USER HEREBY ASSUMES SOLE RESPONSIBILITY TO SECURE
  48. * ANY OTHER INTELLECTUAL PROPERTY RIGHTS NEEDED, IF ANY. THE SOFTWARE
  49. * IS NOT FAULT-TOLERANT AND IS NOT INTENDED FOR USE IN MISSION-CRITICAL
  50. * SYSTEMS, SUCH AS THOSE USED IN THE OPERATION OF NUCLEAR FACILITIES,
  51. * AIRCRAFT NAVIGATION OR COMMUNICATION SYSTEMS, AIR TRAFFIC CONTROL
  52. * SYSTEMS, DIRECT LIFE SUPPORT MACHINES, OR WEAPONS SYSTEMS, IN WHICH
  53. * THE FAILURE OF THE SOFTWARE OR SYSTEM COULD LEAD DIRECTLY TO DEATH,
  54. * PERSONAL INJURY, OR SEVERE PHYSICAL OR ENVIRONMENTAL DAMAGE ("HIGH
  55. * RISK ACTIVITIES"). THE COPYRIGHT HOLDERS SPECIFICALLY DISCLAIM ANY
  56. * EXPRESS OR IMPLIED WARRANTY OF FITNESS FOR HIGH RISK ACTIVITIES.
  57. *
  58. * __END_OF_JASPER_LICENSE__
  59. */
  60. #ifndef JAS_ICC_H
  61. #define JAS_ICC_H
  62. #include <jasper/jas_config.h>
  63. #include <jasper/jas_types.h>
  64. #include <jasper/jas_stream.h>
  65. #ifdef __cplusplus
  66. extern "C" {
  67. #endif
  68. /* Profile file signature. */
  69. #define JAS_ICC_MAGIC 0x61637370
  70. #define JAS_ICC_HDRLEN 128
  71. /* Profile/device class signatures. */
  72. #define JAS_ICC_CLAS_IN 0x73636e72 /* input device */
  73. #define JAS_ICC_CLAS_DPY 0x6d6e7472 /* display device */
  74. #define JAS_ICC_CLAS_OUT 0x70727472 /* output device */
  75. #define JAS_ICC_CLAS_LNK 0x6c696e6b /* device link */
  76. #define JAS_ICC_CLAS_CNV 0x73706163 /* color space conversion */
  77. #define JAS_ICC_CLAS_ABS 0x61627374 /* abstract */
  78. #define JAS_ICC_CLAS_NAM 0x6e6d636c /* named color */
  79. /* Color space signatures. */
  80. #define JAS_ICC_COLORSPC_XYZ 0x58595a20 /* XYZ */
  81. #define JAS_ICC_COLORSPC_LAB 0x4c616220 /* LAB */
  82. #define JAS_ICC_COLORSPC_LUV 0x4c757620 /* LUV */
  83. #define JAS_ICC_COLORSPC_YCBCR 0x59436272 /* YCbCr */
  84. #define JAS_ICC_COLORSPC_YXY 0x59787920 /* Yxy */
  85. #define JAS_ICC_COLORSPC_RGB 0x52474220 /* RGB */
  86. #define JAS_ICC_COLORSPC_GRAY 0x47524159 /* Gray */
  87. #define JAS_ICC_COLORSPC_HSV 0x48535620 /* HSV */
  88. #define JAS_ICC_COLORSPC_HLS 0x484c5320 /* HLS */
  89. #define JAS_ICC_COLORSPC_CMYK 0x434d594b /* CMYK */
  90. #define JAS_ICC_COLORSPC_CMY 0x434d5920 /* CMY */
  91. #define JAS_ICC_COLORSPC_2 0x32434c52 /* 2 channel color */
  92. #define JAS_ICC_COLORSPC_3 0x33434c52 /* 3 channel color */
  93. #define JAS_ICC_COLORSPC_4 0x34434c52 /* 4 channel color */
  94. #define JAS_ICC_COLORSPC_5 0x35434c52 /* 5 channel color */
  95. #define JAS_ICC_COLORSPC_6 0x36434c52 /* 6 channel color */
  96. #define JAS_ICC_COLORSPC_7 0x37434c52 /* 7 channel color */
  97. #define JAS_ICC_COLORSPC_8 0x38434c52 /* 8 channel color */
  98. #define JAS_ICC_COLORSPC_9 0x39434c52 /* 9 channel color */
  99. #define JAS_ICC_COLORSPC_10 0x41434c52 /* 10 channel color */
  100. #define JAS_ICC_COLORSPC_11 0x42434c52 /* 11 channel color */
  101. #define JAS_ICC_COLORSPC_12 0x43434c52 /* 12 channel color */
  102. #define JAS_ICC_COLORSPC_13 0x44434c52 /* 13 channel color */
  103. #define JAS_ICC_COLORSPC_14 0x45434c52 /* 14 channel color */
  104. #define JAS_ICC_COLORSPC_15 0x46434c52 /* 15 channel color */
  105. /* Profile connection color space (PCS) signatures. */
  106. #define JAS_ICC_REFCOLORSPC_XYZ 0x58595a20 /* CIE XYZ */
  107. #define JAS_ICC_REFCOLORSPC_LAB 0x4c616220 /* CIE Lab */
  108. /* Primary platform signatures. */
  109. #define JAS_ICC_PLATFORM_APPL 0x4150504c /* Apple Computer */
  110. #define JAS_ICC_PLATFORM_MSFT 0x4d534654 /* Microsoft */
  111. #define JAS_ICC_PLATFORM_SGI 0x53474920 /* Silicon Graphics */
  112. #define JAS_ICC_PLATFORM_SUNW 0x53554e57 /* Sun Microsystems */
  113. #define JAS_ICC_PLATFORM_TGNT 0x54474e54 /* Taligent */
  114. /* Profile flags. */
  115. #define JAS_ICC_FLAGS_EMBED 0x01 /* embedded */
  116. #define JAS_ICC_FLAGS_NOSEP 0x02 /* no separate use */
  117. /* Attributes. */
  118. #define JAS_ICC_ATTR_TRANS 0x01 /* transparent */
  119. #define JAS_ICC_ATTR_MATTE 0x02 /* matte */
  120. /* Rendering intents. */
  121. #define JAS_ICC_INTENT_PER 0 /* perceptual */
  122. #define JAS_ICC_INTENT_REL 1 /* relative colorimetric */
  123. #define JAS_ICC_INTENT_SAT 2 /* saturation */
  124. #define JAS_ICC_INTENT_ABS 3 /* absolute colorimetric */
  125. /* Tag signatures. */
  126. #define JAS_ICC_TAG_ATOB0 0x41324230 /* */
  127. #define JAS_ICC_TAG_ATOB1 0x41324231 /* */
  128. #define JAS_ICC_TAG_ATOB2 0x41324232 /* */
  129. #define JAS_ICC_TAG_BLUMATCOL 0x6258595a /* */
  130. #define JAS_ICC_TAG_BLUTRC 0x62545243 /* */
  131. #define JAS_ICC_TAG_BTOA0 0x42324130 /* */
  132. #define JAS_ICC_TAG_BTOA1 0x42324131 /* */
  133. #define JAS_ICC_TAG_BTOA2 0x42324132 /* */
  134. #define JAS_ICC_TAG_CALTIME 0x63616c74 /* */
  135. #define JAS_ICC_TAG_CHARTARGET 0x74617267 /* */
  136. #define JAS_ICC_TAG_CPYRT 0x63707274 /* */
  137. #define JAS_ICC_TAG_CRDINFO 0x63726469 /* */
  138. #define JAS_ICC_TAG_DEVMAKERDESC 0x646d6e64 /* */
  139. #define JAS_ICC_TAG_DEVMODELDESC 0x646d6464 /* */
  140. #define JAS_ICC_TAG_DEVSET 0x64657673 /* */
  141. #define JAS_ICC_TAG_GAMUT 0x67616d74 /* */
  142. #define JAS_ICC_TAG_GRYTRC 0x6b545243 /* */
  143. #define JAS_ICC_TAG_GRNMATCOL 0x6758595a /* */
  144. #define JAS_ICC_TAG_GRNTRC 0x67545243 /* */
  145. #define JAS_ICC_TAG_LUM 0x6c756d69 /* */
  146. #define JAS_ICC_TAG_MEASURE 0x6d656173 /* */
  147. #define JAS_ICC_TAG_MEDIABLKPT 0x626b7074 /* */
  148. #define JAS_ICC_TAG_MEDIAWHIPT 0x77747074 /* */
  149. #define JAS_ICC_TAG_NAMCOLR 0x6e636f6c /* */
  150. #define JAS_ICC_TAG_NAMCOLR2 0x6e636c32 /* */
  151. #define JAS_ICC_TAG_OUTRESP 0x72657370 /* */
  152. #define JAS_ICC_TAG_PREVIEW0 0x70726530 /* */
  153. #define JAS_ICC_TAG_PREVIEW1 0x70726531 /* */
  154. #define JAS_ICC_TAG_PREVIEW2 0x70726532 /* */
  155. #define JAS_ICC_TAG_PROFDESC 0x64657363 /* */
  156. #define JAS_ICC_TAG_PROFSEQDESC 0x70736571 /* */
  157. #define JAS_ICC_TAG_PSDCRD0 0x70736430 /* */
  158. #define JAS_ICC_TAG_PSCRDD1 0x70736431 /* */
  159. #define JAS_ICC_TAG_PSCRDD2 0x70736432 /* */
  160. #define JAS_ICC_TAG_PSCRDD3 0x70736433 /* */
  161. #define JAS_ICC_TAG_PS2CSA 0x70733273 /* */
  162. #define JAS_ICC_TAG_PS2RENINTENT 0x70733269 /* */
  163. #define JAS_ICC_TAG_REDMATCOL 0x7258595a /* */
  164. #define JAS_ICC_TAG_REDTRC 0x72545243 /* */
  165. #define JAS_ICC_TAG_SCRNGDES 0x73637264 /* */
  166. #define JAS_ICC_TAG_SCRNG 0x7363726e /* */
  167. #define JAS_ICC_TAG_TECH 0x74656368 /* */
  168. #define JAS_ICC_TAG_UCRBG 0x62666420 /* */
  169. #define JAS_ICC_TAG_VIEWCONDDESC 0x76756564 /* */
  170. #define JAS_ICC_TAG_VIEWCOND 0x76696577 /* */
  171. /* Type signatures. */
  172. #define JAS_ICC_TYPE_CRDINFO 0x63726469 /* CRD information */
  173. #define JAS_ICC_TYPE_CURV 0x63757276 /* curve */
  174. #define JAS_ICC_TYPE_DATA 0x64617461 /* data */
  175. #define JAS_ICC_TYPE_TIME 0x6474696d /* date/time */
  176. #define JAS_ICC_TYPE_DEVSET 0x64657673 /* device settings */
  177. #define JAS_ICC_TYPE_LUT16 0x6d667432 /* */
  178. #define JAS_ICC_TYPE_LUT8 0x6d667431 /* */
  179. #define JAS_ICC_TYPE_MEASURE 0x6d656173 /* */
  180. #define JAS_ICC_TYPE_NAMCOLR 0x6e636f6c /* */
  181. #define JAS_ICC_TYPE_NAMCOLR2 0x6e636c32 /* */
  182. #define JAS_ICC_TYPE_PROFSEQDESC 0x70736571 /* profile sequence description */
  183. #define JAS_ICC_TYPE_RESPCURVSET16 0x72637332 /* response curve set 16 */
  184. #define JAS_ICC_TYPE_SF32 0x73663332 /* signed 32-bit fixed-point */
  185. #define JAS_ICC_TYPE_SCRNG 0x7363726e /* screening */
  186. #define JAS_ICC_TYPE_SIG 0x73696720 /* signature */
  187. #define JAS_ICC_TYPE_TXTDESC 0x64657363 /* text description */
  188. #define JAS_ICC_TYPE_TXT 0x74657874 /* text */
  189. #define JAS_ICC_TYPE_UF32 0x75663332 /* unsigned 32-bit fixed-point */
  190. #define JAS_ICC_TYPE_UCRBG 0x62666420 /* */
  191. #define JAS_ICC_TYPE_UI16 0x75693136 /* */
  192. #define JAS_ICC_TYPE_UI32 0x75693332 /* */
  193. #define JAS_ICC_TYPE_UI8 0x75693038 /* */
  194. #define JAS_ICC_TYPE_UI64 0x75693634 /* */
  195. #define JAS_ICC_TYPE_VIEWCOND 0x76696577 /* */
  196. #define JAS_ICC_TYPE_XYZ 0x58595a20 /* XYZ */
  197. typedef uint_fast8_t jas_iccuint8_t;
  198. typedef uint_fast16_t jas_iccuint16_t;
  199. typedef uint_fast32_t jas_iccuint32_t;
  200. typedef int_fast32_t jas_iccsint32_t;
  201. typedef int_fast32_t jas_iccs15fixed16_t;
  202. typedef uint_fast32_t jas_iccu16fixed16_t;
  203. typedef uint_fast64_t jas_iccuint64_t;
  204. typedef uint_fast32_t jas_iccsig_t;
  205. typedef jas_iccsig_t jas_icctagsig_t;
  206. typedef jas_iccsig_t jas_icctagtype_t;
  207. typedef jas_iccsig_t jas_iccattrname_t;
  208. /* Date/time type. */
  209. typedef struct {
  210. jas_iccuint16_t year;
  211. jas_iccuint16_t month;
  212. jas_iccuint16_t day;
  213. jas_iccuint16_t hour;
  214. jas_iccuint16_t min;
  215. jas_iccuint16_t sec;
  216. } jas_icctime_t;
  217. /* XYZ type. */
  218. typedef struct {
  219. jas_iccs15fixed16_t x;
  220. jas_iccs15fixed16_t y;
  221. jas_iccs15fixed16_t z;
  222. } jas_iccxyz_t;
  223. /* Curve type. */
  224. typedef struct {
  225. jas_iccuint32_t numents;
  226. jas_iccuint16_t *ents;
  227. } jas_icccurv_t;
  228. /* Text description type. */
  229. typedef struct {
  230. jas_iccuint32_t asclen;
  231. char *ascdata; /* ASCII invariant description */
  232. jas_iccuint32_t uclangcode; /* Unicode language code */
  233. jas_iccuint32_t uclen; /* Unicode localizable description count */
  234. uchar *ucdata; /* Unicode localizable description */
  235. jas_iccuint16_t sccode; /* ScriptCode code */
  236. jas_iccuint8_t maclen; /* Localizable Macintosh description count */
  237. uchar macdata[69]; /* Localizable Macintosh description */
  238. } jas_icctxtdesc_t;
  239. /* Text type. */
  240. typedef struct {
  241. char *string; /* ASCII character string */
  242. } jas_icctxt_t;
  243. typedef struct {
  244. jas_iccuint8_t numinchans;
  245. jas_iccuint8_t numoutchans;
  246. jas_iccsint32_t e[3][3];
  247. jas_iccuint8_t clutlen;
  248. jas_iccuint8_t *clut;
  249. jas_iccuint16_t numintabents;
  250. jas_iccuint8_t **intabs;
  251. jas_iccuint8_t *intabsbuf;
  252. jas_iccuint16_t numouttabents;
  253. jas_iccuint8_t **outtabs;
  254. jas_iccuint8_t *outtabsbuf;
  255. } jas_icclut8_t;
  256. typedef struct {
  257. jas_iccuint8_t numinchans;
  258. jas_iccuint8_t numoutchans;
  259. jas_iccsint32_t e[3][3];
  260. jas_iccuint8_t clutlen;
  261. jas_iccuint16_t *clut;
  262. jas_iccuint16_t numintabents;
  263. jas_iccuint16_t **intabs;
  264. jas_iccuint16_t *intabsbuf;
  265. jas_iccuint16_t numouttabents;
  266. jas_iccuint16_t **outtabs;
  267. jas_iccuint16_t *outtabsbuf;
  268. } jas_icclut16_t;
  269. struct jas_iccattrval_s;
  270. typedef struct {
  271. void (*destroy)(struct jas_iccattrval_s *);
  272. int (*copy)(struct jas_iccattrval_s *, struct jas_iccattrval_s *);
  273. int (*input)(struct jas_iccattrval_s *, jas_stream_t *, int);
  274. int (*output)(struct jas_iccattrval_s *, jas_stream_t *);
  275. int (*getsize)(struct jas_iccattrval_s *);
  276. void (*dump)(struct jas_iccattrval_s *, FILE *);
  277. } jas_iccattrvalops_t;
  278. /* Attribute value type (type and value information). */
  279. typedef struct jas_iccattrval_s {
  280. int refcnt; /* reference count */
  281. jas_iccsig_t type; /* type */
  282. jas_iccattrvalops_t *ops; /* type-dependent operations */
  283. union {
  284. jas_iccxyz_t xyz;
  285. jas_icccurv_t curv;
  286. jas_icctxtdesc_t txtdesc;
  287. jas_icctxt_t txt;
  288. jas_icclut8_t lut8;
  289. jas_icclut16_t lut16;
  290. } data; /* value */
  291. } jas_iccattrval_t;
  292. /* Header type. */
  293. typedef struct {
  294. jas_iccuint32_t size; /* profile size */
  295. jas_iccsig_t cmmtype; /* CMM type signature */
  296. jas_iccuint32_t version; /* profile version */
  297. jas_iccsig_t clas; /* profile/device class signature */
  298. jas_iccsig_t colorspc; /* color space of data */
  299. jas_iccsig_t refcolorspc; /* profile connection space */
  300. jas_icctime_t ctime; /* creation time */
  301. jas_iccsig_t magic; /* profile file signature */
  302. jas_iccsig_t platform; /* primary platform */
  303. jas_iccuint32_t flags; /* profile flags */
  304. jas_iccsig_t maker; /* device manufacturer signature */
  305. jas_iccsig_t model; /* device model signature */
  306. jas_iccuint64_t attr; /* device setup attributes */
  307. jas_iccsig_t intent; /* rendering intent */
  308. jas_iccxyz_t illum; /* illuminant */
  309. jas_iccsig_t creator; /* profile creator signature */
  310. } jas_icchdr_t;
  311. typedef struct {
  312. jas_iccsig_t name;
  313. jas_iccattrval_t *val;
  314. } jas_iccattr_t;
  315. typedef struct {
  316. int numattrs;
  317. int maxattrs;
  318. jas_iccattr_t *attrs;
  319. } jas_iccattrtab_t;
  320. typedef struct jas_icctagtabent_s {
  321. jas_iccuint32_t tag;
  322. jas_iccuint32_t off;
  323. jas_iccuint32_t len;
  324. void *data;
  325. struct jas_icctagtabent_s *first;
  326. } jas_icctagtabent_t;
  327. typedef struct {
  328. jas_iccuint32_t numents;
  329. jas_icctagtabent_t *ents;
  330. } jas_icctagtab_t;
  331. /* ICC profile type. */
  332. typedef struct {
  333. jas_icchdr_t hdr;
  334. jas_icctagtab_t tagtab;
  335. jas_iccattrtab_t *attrtab;
  336. } jas_iccprof_t;
  337. typedef struct {
  338. jas_iccuint32_t type;
  339. jas_iccattrvalops_t ops;
  340. } jas_iccattrvalinfo_t;
  341. jas_iccprof_t *jas_iccprof_load(jas_stream_t *in);
  342. int jas_iccprof_save(jas_iccprof_t *prof, jas_stream_t *out);
  343. void jas_iccprof_destroy(jas_iccprof_t *prof);
  344. jas_iccattrval_t *jas_iccprof_getattr(jas_iccprof_t *prof,
  345. jas_iccattrname_t name);
  346. int jas_iccprof_setattr(jas_iccprof_t *prof, jas_iccattrname_t name,
  347. jas_iccattrval_t *val);
  348. void jas_iccprof_dump(jas_iccprof_t *prof, FILE *out);
  349. jas_iccprof_t *jas_iccprof_copy(jas_iccprof_t *prof);
  350. int jas_iccprof_gethdr(jas_iccprof_t *prof, jas_icchdr_t *hdr);
  351. int jas_iccprof_sethdr(jas_iccprof_t *prof, jas_icchdr_t *hdr);
  352. void jas_iccattrval_destroy(jas_iccattrval_t *attrval);
  353. void jas_iccattrval_dump(jas_iccattrval_t *attrval, FILE *out);
  354. int jas_iccattrval_allowmodify(jas_iccattrval_t **attrval);
  355. jas_iccattrval_t *jas_iccattrval_clone(jas_iccattrval_t *attrval);
  356. jas_iccattrval_t *jas_iccattrval_create(jas_iccuint32_t type);
  357. void jas_iccattrtab_dump(jas_iccattrtab_t *attrtab, FILE *out);
  358. extern uchar jas_iccprofdata_srgb[];
  359. extern int jas_iccprofdata_srgblen;
  360. extern uchar jas_iccprofdata_sgray[];
  361. extern int jas_iccprofdata_sgraylen;
  362. jas_iccprof_t *jas_iccprof_createfrombuf(uchar *buf, int len);
  363. jas_iccprof_t *jas_iccprof_createfromclrspc(int clrspc);
  364. #ifdef __cplusplus
  365. }
  366. #endif
  367. #endif