~ubuntu-branches/ubuntu/gutsy/vnc4/gutsy

« back to all changes in this revision

Viewing changes to unix/xc/lib/XIE/XIElib.h

  • Committer: Bazaar Package Importer
  • Author(s): Ola Lundqvist
  • Date: 2006-05-15 20:35:17 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20060515203517-l4lre1ku942mn26k
Tags: 4.1.1+X4.3.0-10
* Correction of critical security issue. Thanks to Martin Kogler
  <e9925248@student.tuwien.ac.at> that informed me about the issue,
  and provided the patch.
  This flaw was originally found by Steve Wiseman of intelliadmin.com.
* Applied patch from Javier Kohen <jkohen@users.sourceforge.net> that
  inform the user that only 8 first characters of the password will
  actually be used when typing more than 8 characters, closes:
  #355619.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* $Xorg: XIElib.h,v 1.6 2001/02/09 02:03:41 xorgcvs Exp $ */
 
2
 
 
3
/*
 
4
 
 
5
Copyright 1993, 1994, 1998  The Open Group
 
6
 
 
7
Permission to use, copy, modify, distribute, and sell this software and its
 
8
documentation for any purpose is hereby granted without fee, provided that
 
9
the above copyright notice appear in all copies and that both that
 
10
copyright notice and this permission notice appear in supporting
 
11
documentation.
 
12
 
 
13
The above copyright notice and this permission notice shall be included
 
14
in all copies or substantial portions of the Software.
 
15
 
 
16
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 
17
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 
18
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
 
19
IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR
 
20
OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
 
21
ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
 
22
OTHER DEALINGS IN THE SOFTWARE.
 
23
 
 
24
Except as contained in this notice, the name of The Open Group shall
 
25
not be used in advertising or otherwise to promote the sale, use or
 
26
other dealings in this Software without prior written authorization
 
27
from The Open Group.
 
28
 
 
29
*/
 
30
 
 
31
#ifndef _XIELIB_H_
 
32
#define _XIELIB_H_
 
33
 
 
34
#include <X11/Xlib.h>
 
35
#include <X11/extensions/XIE.h>
 
36
 
 
37
/*--------------------------------------------------------------------------*
 
38
 *                              XIE types                                   *
 
39
 *--------------------------------------------------------------------------*/
 
40
 
 
41
typedef float           XieFloat;
 
42
 
 
43
typedef float           XieConstant[3];
 
44
 
 
45
typedef float           XieMatrix[9];
 
46
 
 
47
typedef unsigned        XieAlignment;
 
48
 
 
49
typedef unsigned        XieArithmeticOp;
 
50
 
 
51
typedef unsigned        XieColorAllocTechnique;
 
52
 
 
53
typedef XID             XieColorList;
 
54
 
 
55
typedef unsigned        XieColorspace;
 
56
 
 
57
typedef unsigned        XieCompareOp;
 
58
 
 
59
typedef unsigned        XieConstrainTechnique;
 
60
 
 
61
typedef unsigned        XieConvolveTechnique;
 
62
 
 
63
typedef unsigned        XieDataClass;
 
64
 
 
65
typedef unsigned        XieDataType;
 
66
 
 
67
typedef unsigned        XieDecodeTechnique;
 
68
 
 
69
typedef unsigned        XieDitherTechnique;
 
70
 
 
71
typedef unsigned        XieEncodeTechnique;
 
72
 
 
73
typedef XID             XiePhotospace;
 
74
 
 
75
typedef XID             XiePhotoflo;
 
76
 
 
77
typedef unsigned        XieExportNotify;
 
78
 
 
79
typedef unsigned        XieExportState;
 
80
 
 
81
typedef unsigned        XieGamutTechnique;
 
82
 
 
83
typedef unsigned        XieGeometryTechnique;
 
84
 
 
85
typedef struct {
 
86
    unsigned long       value;
 
87
    unsigned long       count;
 
88
} XieHistogramData;
 
89
 
 
90
typedef unsigned        XieHistogramShape;
 
91
 
 
92
typedef unsigned        XieInterleave;
 
93
 
 
94
typedef unsigned long   XieLevels[3];
 
95
 
 
96
typedef XID             XieLut;
 
97
 
 
98
typedef unsigned        XieMathOp;
 
99
 
 
100
typedef unsigned        XieOrientation;
 
101
 
 
102
typedef unsigned        XiePhotofloOutcome;
 
103
 
 
104
typedef unsigned        XiePhotofloState;
 
105
 
 
106
typedef XID             XiePhotomap;
 
107
 
 
108
typedef unsigned        XiePhototag;
 
109
 
 
110
typedef struct {
 
111
    int                 offset_x;
 
112
    int                 offset_y;
 
113
    XiePhototag         phototag;               
 
114
} XieProcessDomain;
 
115
 
 
116
typedef struct {               /* this is bcopyable on 32 bit machines */
 
117
    long                x;     /* when using PutClientData */
 
118
    long                y;
 
119
    unsigned long       width;
 
120
    unsigned long       height;
 
121
} XieRectangle;
 
122
 
 
123
typedef XID             XieRoi;
 
124
 
 
125
typedef unsigned        XieServiceClass;
 
126
 
 
127
typedef unsigned        XieTechniqueGroup;
 
128
 
 
129
typedef struct {
 
130
    Bool                needs_param;
 
131
    XieTechniqueGroup   group;
 
132
    unsigned int        number;
 
133
    unsigned int        speed;
 
134
    char                *name;
 
135
} XieTechnique;
 
136
 
 
137
typedef struct {
 
138
    XiePhototag         src;
 
139
    int                 dst_x;
 
140
    int                 dst_y;
 
141
} XieTile;
 
142
 
 
143
typedef unsigned long   XieLTriplet[3];
 
144
 
 
145
typedef unsigned        XieWhiteAdjustTechnique;
 
146
 
 
147
#if NeedFunctionPrototypes
 
148
typedef void *XiePointer;
 
149
#else
 
150
typedef char *XiePointer;
 
151
#endif
 
152
 
 
153
 
 
154
/*--------------------------------------------------------------------------*
 
155
 *                        Extension information                             *
 
156
 *--------------------------------------------------------------------------*/
 
157
 
 
158
typedef struct {
 
159
    unsigned            server_major_rev;
 
160
    unsigned            server_minor_rev;
 
161
    XieServiceClass     service_class;
 
162
    XieAlignment        alignment;
 
163
    int                 uncnst_mantissa;
 
164
    int                 uncnst_min_exp;
 
165
    int                 uncnst_max_exp;
 
166
    int                 n_cnst_levels;  /* number of   constrained levels */
 
167
    unsigned long       *cnst_levels;   /* recommended constrained levels */
 
168
    int                 major_opcode;
 
169
    int                 first_event;
 
170
    int                 first_error;
 
171
} XieExtensionInfo;
 
172
 
 
173
 
 
174
/*--------------------------------------------------------------------------*
 
175
 *                         Photoflo element union                           *
 
176
 *--------------------------------------------------------------------------*/
 
177
 
 
178
typedef struct {
 
179
 
 
180
    int elemType;
 
181
 
 
182
    union {
 
183
 
 
184
        /*
 
185
         * Import Elements
 
186
         */
 
187
        
 
188
        struct {
 
189
            XieDataClass        data_class;
 
190
            XieOrientation      band_order;
 
191
            XieLTriplet         length;
 
192
            XieLevels           levels;
 
193
        } ImportClientLUT;
 
194
        
 
195
        struct {
 
196
            XieDataClass        data_class;
 
197
            XieLTriplet         width;
 
198
            XieLTriplet         height;
 
199
            XieLevels           levels;
 
200
            Bool                notify;
 
201
            XieDecodeTechnique  decode_tech;
 
202
            XiePointer          decode_param;
 
203
        } ImportClientPhoto;
 
204
        
 
205
        struct {
 
206
            unsigned int        rectangles;
 
207
        } ImportClientROI;
 
208
        
 
209
        struct {
 
210
            Drawable            drawable;
 
211
            int                 src_x;
 
212
            int                 src_y;
 
213
            unsigned int        width;
 
214
            unsigned int        height;
 
215
            unsigned long       fill;
 
216
            Bool                notify;
 
217
        } ImportDrawable;
 
218
        
 
219
        struct {
 
220
            Drawable            drawable;
 
221
            int                 src_x;
 
222
            int                 src_y;
 
223
            unsigned int        width;
 
224
            unsigned int        height;
 
225
            unsigned long       fill;
 
226
            unsigned long       bit_plane;
 
227
            Bool                notify;
 
228
        } ImportDrawablePlane;
 
229
        
 
230
        struct {
 
231
            XieLut              lut;
 
232
        } ImportLUT;
 
233
         
 
234
        struct {
 
235
            XiePhotomap         photomap;
 
236
            Bool                notify;
 
237
        } ImportPhotomap;
 
238
        
 
239
        struct {
 
240
            XieRoi              roi;
 
241
        } ImportROI;
 
242
        
 
243
 
 
244
        /*
 
245
         * Process Elements
 
246
         */
 
247
        
 
248
        struct {
 
249
            XiePhototag         src1;
 
250
            XiePhototag         src2;
 
251
            XieProcessDomain    domain;
 
252
            XieConstant         constant;
 
253
#if defined(__cplusplus) || defined(c_plusplus)
 
254
            XieArithmeticOp     c_operator;
 
255
#else
 
256
            XieArithmeticOp     operator;
 
257
#endif
 
258
            unsigned int        band_mask;
 
259
        } Arithmetic;
 
260
        
 
261
        struct {
 
262
            XiePhototag         src1;
 
263
            XiePhototag         src2;
 
264
            XiePhototag         src3;
 
265
        } BandCombine;
 
266
        
 
267
        struct {
 
268
            XiePhototag         src;
 
269
            unsigned int        levels;
 
270
            float               bias;
 
271
            XieConstant         coefficients;
 
272
        } BandExtract;
 
273
        
 
274
        struct {
 
275
            XiePhototag         src;
 
276
            unsigned int        band_number;
 
277
        } BandSelect;
 
278
        
 
279
        struct {
 
280
            XiePhototag         src1;
 
281
            XiePhototag         src2;
 
282
            XieConstant         src_constant;
 
283
            XiePhototag         alpha;
 
284
            float               alpha_constant;
 
285
            XieProcessDomain    domain;
 
286
            unsigned int        band_mask;
 
287
        } Blend;
 
288
        
 
289
        struct {
 
290
            XiePhototag         src1;
 
291
            XiePhototag         src2;
 
292
            XieProcessDomain    domain;
 
293
            XieConstant         constant;
 
294
#if defined(__cplusplus) || defined(c_plusplus)
 
295
            XieCompareOp        c_operator;
 
296
#else
 
297
            XieCompareOp        operator;
 
298
#endif
 
299
            Bool                combine;
 
300
            unsigned int        band_mask;
 
301
        } Compare;
 
302
        
 
303
        struct {
 
304
            XiePhototag                 src;
 
305
            XieLevels                   levels;
 
306
            XieConstrainTechnique       constrain_tech;
 
307
            XiePointer                  constrain_param;
 
308
        } Constrain;
 
309
        
 
310
        struct {
 
311
            XiePhototag         src;
 
312
            Colormap            colormap;
 
313
            XieDataClass        data_class;
 
314
            unsigned int        precision;
 
315
        } ConvertFromIndex;
 
316
        
 
317
        struct {
 
318
            XiePhototag         src;
 
319
            XieColorspace       color_space;
 
320
            XiePointer          color_param;
 
321
        } ConvertFromRGB;
 
322
        
 
323
        struct {
 
324
            XiePhototag                 src;
 
325
            Colormap                    colormap;
 
326
            XieColorList                color_list;
 
327
            Bool                        notify;
 
328
            XieColorAllocTechnique      color_alloc_tech;
 
329
            XiePointer                  color_alloc_param;
 
330
        } ConvertToIndex;
 
331
        
 
332
        struct {
 
333
            XiePhototag         src;
 
334
            XieColorspace       color_space;
 
335
            XiePointer          color_param;
 
336
        } ConvertToRGB;
 
337
        
 
338
        struct {
 
339
            XiePhototag                 src;
 
340
            XieProcessDomain            domain;
 
341
            float                       *kernel;
 
342
            int                         kernel_size;
 
343
            unsigned int                band_mask;
 
344
            XieConvolveTechnique        convolve_tech;
 
345
            XiePointer                  convolve_param;
 
346
        } Convolve;
 
347
        
 
348
        struct {
 
349
            XiePhototag         src;
 
350
            XieLevels           levels;
 
351
            unsigned int        band_mask;
 
352
            XieDitherTechnique  dither_tech;
 
353
            XiePointer          dither_param;
 
354
        } Dither;
 
355
        
 
356
        struct {
 
357
            XiePhototag                 src;
 
358
            unsigned int                width;
 
359
            unsigned int                height;
 
360
            float                       coefficients[6];
 
361
            XieConstant                 constant;
 
362
            unsigned int                band_mask;
 
363
            XieGeometryTechnique        sample_tech;
 
364
            XiePointer                  sample_param;
 
365
        } Geometry;
 
366
        
 
367
        struct {
 
368
            XiePhototag         src1;
 
369
            XiePhototag         src2;
 
370
            XieProcessDomain    domain;
 
371
            XieConstant         constant;
 
372
#if defined(__cplusplus) || defined(c_plusplus)
 
373
            int                 c_operator;
 
374
#else
 
375
            int                 operator;
 
376
#endif
 
377
            unsigned int        band_mask;
 
378
        } Logical;
 
379
        
 
380
        struct {
 
381
            XiePhototag         src;
 
382
            XieProcessDomain    domain;
 
383
            XieHistogramShape   shape;
 
384
            XiePointer          shape_param;
 
385
        } MatchHistogram;
 
386
        
 
387
        struct {
 
388
            XiePhototag         src;
 
389
            XieProcessDomain    domain;
 
390
#if defined(__cplusplus) || defined(c_plusplus)
 
391
            XieMathOp           c_operator;
 
392
#else
 
393
            XieMathOp           operator;
 
394
#endif
 
395
            unsigned int        band_mask;
 
396
        } Math;
 
397
        
 
398
        struct {
 
399
            unsigned int        width;
 
400
            unsigned int        height;
 
401
            XieConstant         constant;
 
402
            XieTile             *tiles;
 
403
            unsigned int        tile_count;
 
404
        } PasteUp;
 
405
        
 
406
        struct {
 
407
            XiePhototag         src;
 
408
            XieProcessDomain    domain;
 
409
            XiePhototag         lut;
 
410
            unsigned int        band_mask;
 
411
        } Point;
 
412
        
 
413
        struct {
 
414
            XiePhototag                 src;
 
415
        } Unconstrain;
 
416
 
 
417
        /*
 
418
         * Export Elements
 
419
         */
 
420
        
 
421
        struct {
 
422
            XiePhototag         src;
 
423
            XieProcessDomain    domain;
 
424
            XieExportNotify     notify;
 
425
        } ExportClientHistogram;
 
426
        
 
427
        struct {
 
428
            XiePhototag         src;
 
429
            XieOrientation      band_order;
 
430
            XieExportNotify     notify;
 
431
            XieLTriplet         start;
 
432
            XieLTriplet         length;
 
433
        } ExportClientLUT;
 
434
        
 
435
        struct {
 
436
            XiePhototag         src;
 
437
            XieExportNotify     notify;
 
438
            XieEncodeTechnique  encode_tech;
 
439
            XiePointer          encode_param;
 
440
        } ExportClientPhoto;
 
441
        
 
442
        struct {
 
443
            XiePhototag         src;
 
444
            XieExportNotify     notify;
 
445
        } ExportClientROI;
 
446
        
 
447
        struct {
 
448
            XiePhototag         src;
 
449
            Drawable            drawable;
 
450
            GC                  gc;
 
451
            int                 dst_x;
 
452
            int                 dst_y;
 
453
        } ExportDrawable;
 
454
        
 
455
        struct {
 
456
            XiePhototag         src;
 
457
            Drawable            drawable;
 
458
            GC                  gc;
 
459
            int                 dst_x;
 
460
            int                 dst_y;
 
461
        } ExportDrawablePlane;
 
462
        
 
463
        struct {
 
464
            XiePhototag         src;
 
465
            XieLut              lut;
 
466
            Bool                merge;
 
467
            XieLTriplet         start;
 
468
        } ExportLUT;
 
469
         
 
470
        struct {
 
471
            XiePhototag         src;
 
472
            XiePhotomap         photomap;
 
473
            XieEncodeTechnique  encode_tech;
 
474
            XiePointer          encode_param;
 
475
        } ExportPhotomap;
 
476
        
 
477
        struct {
 
478
            XiePhototag         src;
 
479
            XieRoi              roi;
 
480
        } ExportROI;
 
481
 
 
482
    } data;
 
483
} XiePhotoElement;
 
484
 
 
485
typedef XiePhotoElement *XiePhotofloGraph;
 
486
 
 
487
 
 
488
/*--------------------------------------------------------------------------*
 
489
 *                           Technique Parameters                           *
 
490
 *--------------------------------------------------------------------------*/
 
491
 
 
492
/* Color Alloc */
 
493
 
 
494
typedef struct {
 
495
    unsigned long       fill;
 
496
} XieColorAllocAllParam;
 
497
 
 
498
typedef struct {
 
499
    float       match_limit;
 
500
    float       gray_limit;
 
501
} XieColorAllocMatchParam;
 
502
 
 
503
typedef struct {
 
504
    unsigned long       max_cells;
 
505
} XieColorAllocRequantizeParam;
 
506
 
 
507
 
 
508
/* Colorspace - conversion from RGB */
 
509
 
 
510
typedef struct {
 
511
    XieMatrix                   matrix;
 
512
    XieWhiteAdjustTechnique     white_adjust_tech;
 
513
    XiePointer                  white_adjust_param;
 
514
} XieRGBToCIELabParam, XieRGBToCIEXYZParam;
 
515
 
 
516
typedef struct {
 
517
    XieLevels   levels;
 
518
    float       luma_red;
 
519
    float       luma_green;
 
520
    float       luma_blue;
 
521
    XieConstant bias;
 
522
} XieRGBToYCbCrParam;
 
523
 
 
524
typedef struct {
 
525
    XieLevels   levels;
 
526
    float       luma_red;
 
527
    float       luma_green;
 
528
    float       luma_blue;
 
529
    float       scale;
 
530
} XieRGBToYCCParam;
 
531
 
 
532
 
 
533
/* Colorspace - conversion to RGB */
 
534
 
 
535
typedef struct {
 
536
    XieMatrix                   matrix;
 
537
    XieWhiteAdjustTechnique     white_adjust_tech;
 
538
    XiePointer                  white_adjust_param;
 
539
    XieGamutTechnique           gamut_tech;
 
540
    XiePointer                  gamut_param;
 
541
} XieCIELabToRGBParam, XieCIEXYZToRGBParam;
 
542
 
 
543
typedef struct {
 
544
    XieLevels           levels;
 
545
    float               luma_red;
 
546
    float               luma_green;
 
547
    float               luma_blue;
 
548
    XieConstant         bias;
 
549
    XieGamutTechnique   gamut_tech;
 
550
    XiePointer          gamut_param;
 
551
} XieYCbCrToRGBParam;
 
552
 
 
553
typedef struct {
 
554
    XieLevels           levels;
 
555
    float               luma_red;
 
556
    float               luma_green;
 
557
    float               luma_blue;
 
558
    float               scale;
 
559
    XieGamutTechnique   gamut_tech;
 
560
    XiePointer          gamut_param;
 
561
} XieYCCToRGBParam;
 
562
 
 
563
/* Constrain */
 
564
 
 
565
typedef struct {
 
566
        XieConstant input_low,input_high;
 
567
        XieLTriplet output_low,output_high;
 
568
} XieClipScaleParam;
 
569
 
 
570
 
 
571
/* Convolve */
 
572
 
 
573
typedef struct {
 
574
    XieConstant constant;
 
575
} XieConvolveConstantParam;
 
576
 
 
577
 
 
578
/* Decode */
 
579
 
 
580
typedef struct {
 
581
    XieOrientation      fill_order;
 
582
    XieOrientation      pixel_order;
 
583
    unsigned int        pixel_stride;
 
584
    unsigned int        left_pad;
 
585
    unsigned int        scanline_pad;
 
586
} XieDecodeUncompressedSingleParam;
 
587
 
 
588
typedef struct {
 
589
    unsigned char       left_pad[3];
 
590
    XieOrientation      fill_order;
 
591
    unsigned char       pixel_stride[3];
 
592
    XieOrientation      pixel_order;
 
593
    unsigned char       scanline_pad[3];
 
594
    XieOrientation      band_order;
 
595
    XieInterleave       interleave;
 
596
} XieDecodeUncompressedTripleParam;
 
597
 
 
598
typedef struct {
 
599
    XieOrientation      encoded_order;
 
600
    Bool                normal;
 
601
    Bool                radiometric;
 
602
} XieDecodeG31DParam, XieDecodeG32DParam, XieDecodeG42DParam,
 
603
  XieDecodeTIFF2Param;
 
604
 
 
605
typedef struct {
 
606
    XieOrientation      encoded_order;
 
607
    Bool                normal;
 
608
} XieDecodeTIFFPackBitsParam;
 
609
 
 
610
typedef struct {
 
611
    XieInterleave       interleave;
 
612
    XieOrientation      band_order;
 
613
    Bool                up_sample;
 
614
} XieDecodeJPEGBaselineParam;
 
615
 
 
616
typedef struct {
 
617
    XieInterleave       interleave;
 
618
    XieOrientation      band_order;
 
619
} XieDecodeJPEGLosslessParam;
 
620
 
 
621
 
 
622
/* Dither */
 
623
 
 
624
typedef struct {
 
625
    unsigned int        threshold_order;
 
626
} XieDitherOrderedParam;
 
627
 
 
628
 
 
629
/* Encode */
 
630
 
 
631
typedef struct {
 
632
    XieOrientation      fill_order;
 
633
    XieOrientation      pixel_order;
 
634
    unsigned int        pixel_stride;
 
635
    unsigned int        scanline_pad;
 
636
} XieEncodeUncompressedSingleParam;
 
637
 
 
638
typedef struct {
 
639
    unsigned char       pixel_stride[3];
 
640
    XieOrientation      pixel_order;
 
641
    unsigned char       scanline_pad[3];
 
642
    XieOrientation      fill_order;
 
643
    XieOrientation      band_order;
 
644
    XieInterleave       interleave;
 
645
} XieEncodeUncompressedTripleParam;
 
646
 
 
647
typedef struct {
 
648
    Bool                align_eol;
 
649
    Bool                radiometric;
 
650
    XieOrientation      encoded_order;
 
651
} XieEncodeG31DParam;
 
652
 
 
653
typedef struct {
 
654
    Bool                uncompressed;
 
655
    Bool                align_eol;
 
656
    Bool                radiometric;
 
657
    XieOrientation      encoded_order;
 
658
    unsigned long       k_factor;
 
659
} XieEncodeG32DParam;
 
660
 
 
661
typedef struct {
 
662
    Bool                uncompressed;
 
663
    Bool                radiometric;
 
664
    XieOrientation      encoded_order;
 
665
} XieEncodeG42DParam;
 
666
 
 
667
typedef struct {
 
668
    unsigned int        preference;
 
669
} XieEncodeServerChoiceParam;
 
670
 
 
671
typedef struct {
 
672
    XieInterleave       interleave;
 
673
    XieOrientation      band_order;
 
674
    unsigned char       horizontal_samples[3];
 
675
    unsigned char       vertical_samples[3];
 
676
    char                *q_table;
 
677
    unsigned int        q_size;
 
678
    char                *ac_table;
 
679
    unsigned int        ac_size;
 
680
    char                *dc_table;
 
681
    unsigned int        dc_size;
 
682
} XieEncodeJPEGBaselineParam;
 
683
 
 
684
typedef struct {
 
685
    XieInterleave       interleave;
 
686
    XieOrientation      band_order;
 
687
    unsigned char       predictor[3];
 
688
    char                *table;
 
689
    unsigned int        table_size;
 
690
} XieEncodeJPEGLosslessParam;
 
691
 
 
692
typedef struct {
 
693
    XieOrientation      encoded_order;
 
694
    Bool                radiometric;
 
695
} XieEncodeTIFF2Param; 
 
696
 
 
697
typedef struct {
 
698
    XieOrientation      encoded_order;
 
699
} XieEncodeTIFFPackBitsParam;
 
700
 
 
701
 
 
702
/* Geometry */
 
703
 
 
704
typedef struct {
 
705
    int simple;
 
706
} XieGeomAntialiasByAreaParam;
 
707
 
 
708
typedef struct {
 
709
    int kernel_size;
 
710
} XieGeomAntialiasByLowpassParam;
 
711
 
 
712
typedef struct {
 
713
    float               sigma;
 
714
    float               normalize;
 
715
    unsigned int        radius;
 
716
    Bool                simple;
 
717
} XieGeomGaussianParam;
 
718
 
 
719
typedef struct {
 
720
    unsigned int        modify;
 
721
} XieGeomNearestNeighborParam;
 
722
 
 
723
 
 
724
/* Histogram */
 
725
 
 
726
typedef struct {
 
727
    float       mean;
 
728
    float       sigma;
 
729
} XieHistogramGaussianParam;
 
730
 
 
731
typedef struct {
 
732
    float       constant;
 
733
    Bool        shape_factor;
 
734
} XieHistogramHyperbolicParam;
 
735
 
 
736
 
 
737
/* White Adjust */
 
738
 
 
739
typedef struct {
 
740
    XieConstant white_point;
 
741
} XieWhiteAdjustCIELabShiftParam;
 
742
 
 
743
 
 
744
/*--------------------------------------------------------------------------*
 
745
 *                                Events                                    *
 
746
 *--------------------------------------------------------------------------*/
 
747
 
 
748
typedef struct {
 
749
    int                         type;
 
750
    unsigned long               serial;
 
751
    Bool                        send_event;
 
752
    Display                     *display;
 
753
    unsigned long               name_space;
 
754
    Time                        time;
 
755
    unsigned long               flo_id;
 
756
    XiePhototag                 src;
 
757
    unsigned int                elem_type;
 
758
    XieColorList                color_list;
 
759
    XieColorAllocTechnique      color_alloc_technique;
 
760
    unsigned long               color_alloc_data;
 
761
} XieColorAllocEvent;
 
762
 
 
763
typedef struct {
 
764
    int                         type;
 
765
    unsigned long               serial;
 
766
    Bool                        send_event;
 
767
    Display                     *display;
 
768
    unsigned long               name_space;
 
769
    Time                        time;
 
770
    unsigned long               flo_id;
 
771
    XiePhototag                 src;
 
772
    unsigned int                elem_type;
 
773
    XieDecodeTechnique          decode_technique;
 
774
    Bool                        aborted;
 
775
    unsigned int                band_number;
 
776
    unsigned long               width;
 
777
    unsigned long               height;
 
778
} XieDecodeNotifyEvent;
 
779
 
 
780
typedef struct {
 
781
    int                         type;
 
782
    unsigned long               serial;
 
783
    Bool                        send_event;
 
784
    Display                     *display;
 
785
    unsigned long               name_space;
 
786
    Time                        time;
 
787
    unsigned long               flo_id;
 
788
    XiePhototag                 src;
 
789
    unsigned int                elem_type;
 
790
    unsigned int                band_number;
 
791
    unsigned long               data[3];
 
792
} XieExportAvailableEvent;
 
793
 
 
794
typedef struct {
 
795
    int                         type;
 
796
    unsigned long               serial;
 
797
    Bool                        send_event;
 
798
    Display                     *display;
 
799
    unsigned long               name_space;
 
800
    Time                        time;
 
801
    unsigned long               flo_id;
 
802
    XiePhototag                 src;
 
803
    unsigned int                elem_type;
 
804
    Window                      window;
 
805
    int                         x;
 
806
    int                         y;
 
807
    unsigned int                width;
 
808
    unsigned int                height;
 
809
} XieImportObscuredEvent;
 
810
 
 
811
typedef struct {
 
812
    int                         type;
 
813
    unsigned long               serial;
 
814
    Bool                        send_event;
 
815
    Display                     *display;
 
816
    unsigned long               name_space;
 
817
    Time                        time;
 
818
    unsigned long               flo_id;
 
819
    XiePhotofloOutcome          outcome;
 
820
} XiePhotofloDoneEvent;
 
821
 
 
822
 
 
823
/*--------------------------------------------------------------------------*
 
824
 *                               Photoflo Errors                            *
 
825
 *--------------------------------------------------------------------------*/
 
826
 
 
827
typedef struct {
 
828
    int                 type;
 
829
    Display             *display;
 
830
    unsigned long       flo_id;
 
831
    unsigned long       serial;
 
832
    unsigned char       error_code;
 
833
    unsigned char       request_code;
 
834
    unsigned char       minor_code;
 
835
    unsigned int        flo_error_code;
 
836
    unsigned long       name_space;
 
837
    XiePhototag         phototag;
 
838
    unsigned int        elem_type;
 
839
} XieFloAccessError, XieFloAllocError, XieFloElementError, XieFloIDError,
 
840
  XieFloLengthError, XieFloMatchError, XieFloSourceError;
 
841
 
 
842
typedef struct {
 
843
    int                 type;
 
844
    Display             *display;
 
845
    unsigned long       flo_id;
 
846
    unsigned long       serial;
 
847
    unsigned char       error_code;
 
848
    unsigned char       request_code;
 
849
    unsigned char       minor_code;
 
850
    unsigned int        flo_error_code;
 
851
    unsigned long       name_space;
 
852
    XiePhototag         phototag;
 
853
    unsigned int        elem_type;
 
854
    XID                 resource_id;
 
855
} XieFloResourceError;
 
856
 
 
857
typedef struct {
 
858
    int                 type;
 
859
    Display             *display;
 
860
    unsigned long       flo_id;
 
861
    unsigned long       serial;
 
862
    unsigned char       error_code;
 
863
    unsigned char       request_code;
 
864
    unsigned char       minor_code;
 
865
    unsigned int        flo_error_code;
 
866
    unsigned long       name_space;
 
867
    XiePhototag         phototag;
 
868
    unsigned int        elem_type;
 
869
    XiePhototag         domain_src;
 
870
} XieFloDomainError;
 
871
 
 
872
typedef struct {
 
873
    int                 type;
 
874
    Display             *display;
 
875
    unsigned long       flo_id;
 
876
    unsigned long       serial;
 
877
    unsigned char       error_code;
 
878
    unsigned char       request_code;
 
879
    unsigned char       minor_code;
 
880
    unsigned int        flo_error_code;
 
881
    unsigned long       name_space;
 
882
    XiePhototag         phototag;
 
883
    unsigned int        elem_type;
 
884
#if defined(__cplusplus) || defined(c_plusplus)
 
885
    unsigned int        c_operator;
 
886
#else
 
887
    unsigned int        operator;
 
888
#endif
 
889
} XieFloOperatorError;
 
890
 
 
891
typedef struct {
 
892
    int                 type;
 
893
    Display             *display;
 
894
    unsigned long       flo_id;
 
895
    unsigned long       serial;
 
896
    unsigned char       error_code;
 
897
    unsigned char       request_code;
 
898
    unsigned char       minor_code;
 
899
    unsigned int        flo_error_code;
 
900
    unsigned long       name_space;
 
901
    XiePhototag         phototag;
 
902
    unsigned int        elem_type;
 
903
    unsigned int        technique_number;
 
904
    unsigned int        num_tech_params;
 
905
    XieTechniqueGroup   tech_group;
 
906
} XieFloTechniqueError;
 
907
 
 
908
typedef struct {
 
909
    int                 type;
 
910
    Display             *display;
 
911
    unsigned long       flo_id;
 
912
    unsigned long       serial;
 
913
    unsigned char       error_code;
 
914
    unsigned char       request_code;
 
915
    unsigned char       minor_code;
 
916
    unsigned int        flo_error_code;
 
917
    unsigned long       name_space;
 
918
    XiePhototag         phototag;
 
919
    unsigned int        elem_type;
 
920
    unsigned long       bad_value;
 
921
} XieFloValueError;
 
922
 
 
923
 
 
924
/*--------------------------------------------------------------------------*
 
925
 *                            Function prototypes                           *
 
926
 *--------------------------------------------------------------------------*/
 
927
 
 
928
/* Startup functions -------------------------------------------------------*/
 
929
 
 
930
extern Status XieInitialize (
 
931
#if NeedFunctionPrototypes
 
932
    Display *           /* display */,
 
933
    XieExtensionInfo ** /* extinfo_ret */
 
934
#endif
 
935
);
 
936
 
 
937
extern Status XieQueryTechniques (
 
938
#if NeedFunctionPrototypes
 
939
    Display *           /* display */,
 
940
    XieTechniqueGroup   /* technique_group */,
 
941
    int *               /* ntechniques_ret */,
 
942
    XieTechnique **     /* techniques_ret */
 
943
#endif
 
944
);
 
945
 
 
946
extern void XieFreeTechniques (
 
947
#if NeedFunctionPrototypes
 
948
    XieTechnique *      /* techs */,
 
949
    unsigned int        /* count */
 
950
#endif
 
951
);
 
952
 
 
953
 
 
954
/* Color List functions ---------------------------------------------------*/
 
955
 
 
956
extern XieColorList XieCreateColorList (
 
957
#if NeedFunctionPrototypes
 
958
    Display *           /* display */
 
959
#endif
 
960
);
 
961
 
 
962
extern void XieDestroyColorList (
 
963
#if NeedFunctionPrototypes
 
964
    Display *           /* display */,
 
965
    XieColorList        /* color_list */
 
966
#endif
 
967
);
 
968
 
 
969
extern void XiePurgeColorList (
 
970
#if NeedFunctionPrototypes
 
971
    Display *           /* display */,
 
972
    XieColorList        /* color_list */
 
973
#endif
 
974
);
 
975
 
 
976
extern Status XieQueryColorList (
 
977
#if NeedFunctionPrototypes
 
978
    Display *           /* display */,
 
979
    XieColorList        /* color_list */,
 
980
    Colormap *          /* colormap_ret */,
 
981
    unsigned *          /* ncolors_ret */,
 
982
    unsigned long **    /* colors_ret */
 
983
#endif
 
984
);
 
985
 
 
986
 
 
987
/* LUT functions -----------------------------------------------------------*/
 
988
 
 
989
extern XieLut XieCreateLUT (
 
990
#if NeedFunctionPrototypes
 
991
    Display *           /* display */
 
992
#endif
 
993
);
 
994
 
 
995
extern void XieDestroyLUT (
 
996
#if NeedFunctionPrototypes
 
997
    Display *           /* display */,
 
998
    XieLut              /* lut */
 
999
#endif
 
1000
);
 
1001
 
 
1002
 
 
1003
/* Photomap functions ------------------------------------------------------*/
 
1004
 
 
1005
extern XiePhotomap XieCreatePhotomap (
 
1006
#if NeedFunctionPrototypes
 
1007
    Display *           /* display */
 
1008
#endif
 
1009
);
 
1010
 
 
1011
extern void XieDestroyPhotomap (
 
1012
#if NeedFunctionPrototypes
 
1013
    Display *           /* display */,
 
1014
    XiePhotomap         /* photomap */
 
1015
#endif
 
1016
);
 
1017
 
 
1018
extern Status XieQueryPhotomap (
 
1019
#if NeedFunctionPrototypes
 
1020
    Display *                   /* display */,
 
1021
    XiePhotomap                 /* photomap */,
 
1022
    Bool *                      /* populated_ret */,
 
1023
    XieDataType *               /* datatype_ret */,
 
1024
    XieDataClass *              /* class_ret */,
 
1025
    XieDecodeTechnique *        /* decode_technique_ret */,
 
1026
    XieLTriplet                 /* width_ret */,
 
1027
    XieLTriplet                 /* height_ret */,
 
1028
    XieLTriplet                 /* levels_ret */
 
1029
#endif
 
1030
);
 
1031
 
 
1032
 
 
1033
/* ROI functions -----------------------------------------------------------*/
 
1034
 
 
1035
extern XieRoi XieCreateROI (
 
1036
#if NeedFunctionPrototypes
 
1037
    Display *           /* display */
 
1038
#endif
 
1039
);
 
1040
 
 
1041
extern void XieDestroyROI (
 
1042
#if NeedFunctionPrototypes
 
1043
    Display *           /* display */,
 
1044
    XieRoi              /* roi */
 
1045
#endif
 
1046
);
 
1047
 
 
1048
 
 
1049
/* Photospace functions ----------------------------------------------------*/
 
1050
 
 
1051
extern XiePhotospace XieCreatePhotospace (
 
1052
#if NeedFunctionPrototypes
 
1053
    Display *           /* display */
 
1054
#endif
 
1055
);
 
1056
 
 
1057
extern void XieDestroyPhotospace (
 
1058
#if NeedFunctionPrototypes
 
1059
    Display *           /* display */,
 
1060
    XiePhotospace       /* photospace */
 
1061
#endif
 
1062
);
 
1063
 
 
1064
extern void XieExecuteImmediate (
 
1065
#if NeedFunctionPrototypes
 
1066
    Display *           /* display */,
 
1067
    XiePhotospace       /* photospace */,
 
1068
    unsigned long       /* flo_id */,
 
1069
    Bool                /* notify */,
 
1070
    XiePhotoElement *   /* elem_list */,
 
1071
    int                 /* elem_count */
 
1072
#endif
 
1073
);
 
1074
 
 
1075
 
 
1076
/* Photoflo functions ------------------------------------------------------*/
 
1077
 
 
1078
extern XiePhotoElement *XieAllocatePhotofloGraph (
 
1079
#if NeedFunctionPrototypes
 
1080
    unsigned int        /* count */
 
1081
#endif
 
1082
);
 
1083
 
 
1084
extern void XieFreePhotofloGraph (
 
1085
#if NeedFunctionPrototypes
 
1086
    XiePhotoElement *   /* elements */,
 
1087
    unsigned int        /* count */
 
1088
#endif
 
1089
);
 
1090
 
 
1091
extern XiePhotoflo XieCreatePhotoflo (
 
1092
#if NeedFunctionPrototypes
 
1093
    Display *           /* display */,
 
1094
    XiePhotoElement *   /* elem_list */,
 
1095
    int                 /* elem_count */
 
1096
#endif
 
1097
);
 
1098
 
 
1099
extern void XieDestroyPhotoflo (
 
1100
#if NeedFunctionPrototypes
 
1101
    Display *           /* display */,
 
1102
    XiePhotoflo         /* photoflo */
 
1103
#endif
 
1104
);
 
1105
 
 
1106
extern void XieExecutePhotoflo (
 
1107
#if NeedFunctionPrototypes
 
1108
    Display *           /* display */,
 
1109
    XiePhotoflo         /* photoflo */,
 
1110
    Bool                /* notify */
 
1111
#endif
 
1112
);
 
1113
 
 
1114
extern void XieModifyPhotoflo (
 
1115
#if NeedFunctionPrototypes
 
1116
    Display *           /* display */,
 
1117
    XiePhotoflo         /* photoflo */,
 
1118
    int                 /* start */,
 
1119
    XiePhotoElement *   /* elem_list */,
 
1120
    int                 /* elem_count */
 
1121
#endif
 
1122
);
 
1123
 
 
1124
extern void XieRedefinePhotoflo (
 
1125
#if NeedFunctionPrototypes
 
1126
    Display *           /* display */,
 
1127
    XiePhotoflo         /* photoflo */,
 
1128
    XiePhotoElement *   /* elem_list */,
 
1129
    int                 /* elem_count */
 
1130
#endif
 
1131
);
 
1132
 
 
1133
extern Status XieQueryPhotoflo (
 
1134
#if NeedFunctionPrototypes
 
1135
    Display *           /* display */,
 
1136
    unsigned long       /* name_space */,
 
1137
    unsigned long       /* flo_id */,
 
1138
    XiePhotofloState *  /* state_ret */,
 
1139
    XiePhototag **      /* data_expected_ret */,
 
1140
    unsigned int *      /* nexpected_ret */,
 
1141
    XiePhototag **      /* data_available_ret */,
 
1142
    unsigned int *      /* navailable_ret */
 
1143
#endif
 
1144
);
 
1145
 
 
1146
 
 
1147
/* Client Data functions ---------------------------------------------------*/
 
1148
 
 
1149
extern void XiePutClientData (
 
1150
#if NeedFunctionPrototypes
 
1151
    Display *           /* display */,
 
1152
    unsigned long       /* name_space */,
 
1153
    unsigned long       /* flo_id */,
 
1154
    XiePhototag         /* element */,
 
1155
    Bool                /* final */,
 
1156
    unsigned            /* band_number */,
 
1157
    unsigned char *     /* data */,
 
1158
    unsigned            /* nbytes */
 
1159
#endif
 
1160
);
 
1161
 
 
1162
extern Status XieGetClientData (
 
1163
#if NeedFunctionPrototypes
 
1164
    Display *           /* display */,
 
1165
    unsigned long       /* name_space */,
 
1166
    unsigned long       /* flo_id */,
 
1167
    XiePhototag         /* element */,
 
1168
    unsigned            /* max_bytes */,
 
1169
    Bool                /* terminate */,
 
1170
    unsigned            /* band_number */,
 
1171
    XieExportState *    /* new_state_ret */,
 
1172
    unsigned char **    /* data_ret */,
 
1173
    unsigned *          /* nbytes_ret */
 
1174
#endif
 
1175
);
 
1176
 
 
1177
 
 
1178
/* Abort and Await functions -----------------------------------------------*/
 
1179
 
 
1180
extern void XieAbort (
 
1181
#if NeedFunctionPrototypes
 
1182
    Display *           /* display */,
 
1183
    unsigned long       /* name_space */,
 
1184
    unsigned long       /* flo_id */
 
1185
#endif
 
1186
);
 
1187
 
 
1188
extern void XieAwait (
 
1189
#if NeedFunctionPrototypes
 
1190
   Display *            /* display */,
 
1191
   unsigned long        /* name_space */,
 
1192
   unsigned long        /* flo_id */
 
1193
#endif
 
1194
);
 
1195
 
 
1196
 
 
1197
/* Photoflo element functions ----------------------------------------------*/
 
1198
 
 
1199
extern void XieFloImportClientLUT (
 
1200
#if NeedFunctionPrototypes
 
1201
    XiePhotoElement *   /* element */,
 
1202
    XieDataClass        /* data_class */,
 
1203
    XieOrientation      /* band_order */,
 
1204
    XieLTriplet         /* length */,
 
1205
    XieLevels           /* levels */
 
1206
#endif
 
1207
);
 
1208
 
 
1209
extern void XieFloImportClientPhoto (
 
1210
#if NeedFunctionPrototypes
 
1211
    XiePhotoElement *   /* element */,
 
1212
    XieDataClass        /* data_class */,
 
1213
    XieLTriplet         /* width */,
 
1214
    XieLTriplet         /* height */,
 
1215
    XieLevels           /* levels */,
 
1216
    Bool                /* notify */,
 
1217
    XieDecodeTechnique  /* decode_tech */,
 
1218
    XiePointer          /* decode_param */
 
1219
#endif
 
1220
);
 
1221
 
 
1222
extern void XieFloImportClientROI (
 
1223
#if NeedFunctionPrototypes
 
1224
    XiePhotoElement *   /* element */,
 
1225
    unsigned int        /* rectangles */
 
1226
#endif
 
1227
);
 
1228
 
 
1229
extern void XieFloImportDrawable (
 
1230
#if NeedFunctionPrototypes
 
1231
    XiePhotoElement *   /* element */,
 
1232
    Drawable            /* drawable */,
 
1233
    int                 /* src_x */,
 
1234
    int                 /* src_y */,
 
1235
    unsigned int        /* width */,
 
1236
    unsigned int        /* height */,
 
1237
    unsigned long       /* fill */,
 
1238
    Bool                /* notify */
 
1239
#endif
 
1240
);
 
1241
 
 
1242
extern void XieFloImportDrawablePlane (
 
1243
#if NeedFunctionPrototypes
 
1244
    XiePhotoElement *   /* element */,
 
1245
    Drawable            /* drawable */,
 
1246
    int                 /* src_x */,
 
1247
    int                 /* src_y */,
 
1248
    unsigned int        /* width */,
 
1249
    unsigned int        /* height */,
 
1250
    unsigned long       /* fill */,
 
1251
    unsigned long       /* bit_plane */,
 
1252
    Bool                /* notify */
 
1253
#endif
 
1254
);
 
1255
 
 
1256
extern void XieFloImportLUT (
 
1257
#if NeedFunctionPrototypes
 
1258
    XiePhotoElement *   /* element */,
 
1259
    XieLut              /* lut */
 
1260
#endif
 
1261
);
 
1262
 
 
1263
extern void XieFloImportPhotomap (
 
1264
#if NeedFunctionPrototypes
 
1265
    XiePhotoElement *   /* element */,
 
1266
    XiePhotomap         /* photomap */,
 
1267
    Bool                /* notify */
 
1268
#endif
 
1269
);
 
1270
 
 
1271
extern void XieFloImportROI (
 
1272
#if NeedFunctionPrototypes
 
1273
    XiePhotoElement *   /* element */,
 
1274
    XieRoi              /* roi */
 
1275
#endif
 
1276
);
 
1277
 
 
1278
extern void XieFloArithmetic (
 
1279
#if NeedFunctionPrototypes
 
1280
    XiePhotoElement *   /* element */,
 
1281
    XiePhototag         /* src1 */,
 
1282
    XiePhototag         /* src2 */,
 
1283
    XieProcessDomain *  /* domain */,
 
1284
    XieConstant         /* constant */,
 
1285
    XieArithmeticOp     /* operator */,
 
1286
    unsigned int        /* band_mask */
 
1287
#endif
 
1288
);
 
1289
 
 
1290
extern void XieFloBandCombine (
 
1291
#if NeedFunctionPrototypes
 
1292
    XiePhotoElement *   /* element */,
 
1293
    XiePhototag         /* src1 */,
 
1294
    XiePhototag         /* src2 */,
 
1295
    XiePhototag         /* src3 */
 
1296
#endif
 
1297
);
 
1298
 
 
1299
extern void XieFloBandExtract (
 
1300
#if NeedFunctionPrototypes
 
1301
    XiePhotoElement *   /* element */,
 
1302
    XiePhototag         /* src */,
 
1303
    unsigned int        /* levels */,
 
1304
    double              /* bias */,
 
1305
    XieConstant         /* coefficients */
 
1306
#endif
 
1307
);
 
1308
 
 
1309
extern void XieFloBandSelect (
 
1310
#if NeedFunctionPrototypes
 
1311
    XiePhotoElement *   /* element */,
 
1312
    XiePhototag         /* src */,
 
1313
    unsigned int        /* band_number */
 
1314
#endif
 
1315
);
 
1316
 
 
1317
extern void XieFloBlend (
 
1318
#if NeedFunctionPrototypes
 
1319
    XiePhotoElement *   /* element */,
 
1320
    XiePhototag         /* src1 */,
 
1321
    XiePhototag         /* src2 */,
 
1322
    XieConstant         /* src_constant */,
 
1323
    XiePhototag         /* alpha */,
 
1324
    double              /* alpha_const */,
 
1325
    XieProcessDomain *  /* domain */,
 
1326
    unsigned int        /* band_mask */
 
1327
#endif
 
1328
);
 
1329
 
 
1330
extern void XieFloCompare (
 
1331
#if NeedFunctionPrototypes
 
1332
    XiePhotoElement *   /* element */,
 
1333
    XiePhototag         /* src1 */,
 
1334
    XiePhototag         /* src2 */,
 
1335
    XieProcessDomain *  /* domain */,
 
1336
    XieConstant         /* constant */,
 
1337
    XieCompareOp        /* operator */,
 
1338
    Bool                /* combine */,
 
1339
    unsigned int        /* band_mask */
 
1340
#endif
 
1341
);
 
1342
 
 
1343
extern void XieFloConstrain (
 
1344
#if NeedFunctionPrototypes
 
1345
    XiePhotoElement *           /* element */,
 
1346
    XiePhototag                 /* src */,
 
1347
    XieLevels                   /* levels */,
 
1348
    XieConstrainTechnique       /* constrain_tech */,
 
1349
    XiePointer                  /* constrain_param */
 
1350
#endif
 
1351
);
 
1352
 
 
1353
extern void XieFloConvertFromIndex (
 
1354
#if NeedFunctionPrototypes
 
1355
    XiePhotoElement *   /* element */,
 
1356
    XiePhototag         /* src */,
 
1357
    Colormap            /* colormap */,
 
1358
    XieDataClass        /* data_class */,
 
1359
    unsigned int        /* precision */
 
1360
#endif
 
1361
);
 
1362
 
 
1363
extern void XieFloConvertFromRGB (
 
1364
#if NeedFunctionPrototypes
 
1365
    XiePhotoElement *   /* element */,
 
1366
    XiePhototag         /* src */,
 
1367
    XieColorspace       /* color_space */,
 
1368
    XiePointer          /* color_param */
 
1369
#endif
 
1370
);
 
1371
 
 
1372
extern void XieFloConvertToIndex (
 
1373
#if NeedFunctionPrototypes
 
1374
    XiePhotoElement *           /* element */,
 
1375
    XiePhototag                 /* src */,
 
1376
    Colormap                    /* colormap */,
 
1377
    XieColorList                /* color_list */,
 
1378
    Bool                        /* notify */,
 
1379
    XieColorAllocTechnique      /* color_alloc_tech */,
 
1380
    XiePointer                  /* color_alloc_param */
 
1381
#endif
 
1382
);
 
1383
 
 
1384
extern void XieFloConvertToRGB (
 
1385
#if NeedFunctionPrototypes
 
1386
    XiePhotoElement *   /* element */,
 
1387
    XiePhototag         /* src */,
 
1388
    XieColorspace       /* color_space */,
 
1389
    XiePointer          /* color_param */
 
1390
#endif
 
1391
);
 
1392
 
 
1393
extern void XieFloConvolve (
 
1394
#if NeedFunctionPrototypes
 
1395
    XiePhotoElement *           /* element */,
 
1396
    XiePhototag                 /* src */,
 
1397
    XieProcessDomain *          /* domain */,
 
1398
    float *                     /* kernel */,
 
1399
    int                         /* kernel_size */,
 
1400
    unsigned int                /* band_mask */,
 
1401
    XieConvolveTechnique        /* convolve_tech */,
 
1402
    XiePointer                  /* convolve_param */
 
1403
#endif
 
1404
);
 
1405
 
 
1406
extern void XieFloDither (
 
1407
#if NeedFunctionPrototypes
 
1408
    XiePhotoElement *           /* element */,
 
1409
    XiePhototag                 /* src */,
 
1410
    unsigned int                /* band_mask */,
 
1411
    XieLevels                   /* levels */,
 
1412
    XieDitherTechnique          /* dither_tech */,
 
1413
    XiePointer                  /* dither_param */
 
1414
#endif
 
1415
);
 
1416
 
 
1417
extern void XieFloGeometry (
 
1418
#if NeedFunctionPrototypes
 
1419
    XiePhotoElement *           /* element */,
 
1420
    XiePhototag                 /* src */,
 
1421
    unsigned int                /* width */,
 
1422
    unsigned int                /* height */,
 
1423
    float[6]                    /* coefficients[6] */,
 
1424
    XieConstant                 /* constant */,
 
1425
    unsigned int                /* band_mask */,
 
1426
    XieGeometryTechnique        /* sample_tech */,
 
1427
    XiePointer                  /* sample_param */
 
1428
#endif
 
1429
);
 
1430
 
 
1431
extern void XieFloLogical (
 
1432
#if NeedFunctionPrototypes
 
1433
    XiePhotoElement *   /* element */,
 
1434
    XiePhototag         /* src1 */,
 
1435
    XiePhototag         /* src2 */,
 
1436
    XieProcessDomain *  /* domain */,
 
1437
    XieConstant         /* constant */,
 
1438
    unsigned long       /* operator */,
 
1439
    unsigned int        /* band_mask */
 
1440
#endif
 
1441
);
 
1442
 
 
1443
extern void XieFloMatchHistogram (
 
1444
#if NeedFunctionPrototypes
 
1445
    XiePhotoElement *   /* element */,
 
1446
    XiePhototag         /* src */,
 
1447
    XieProcessDomain *  /* domain */,
 
1448
    XieHistogramShape   /* shape */,
 
1449
    XiePointer          /* shape_param */
 
1450
#endif
 
1451
);
 
1452
 
 
1453
extern void XieFloMath (
 
1454
#if NeedFunctionPrototypes
 
1455
    XiePhotoElement *   /* element */,
 
1456
    XiePhototag         /* src */,
 
1457
    XieProcessDomain *  /* domain */,
 
1458
    XieMathOp           /* operator */,
 
1459
    unsigned int        /* band_mask */
 
1460
#endif
 
1461
);
 
1462
 
 
1463
extern void XieFloPasteUp (
 
1464
#if NeedFunctionPrototypes
 
1465
    XiePhotoElement *   /* element */,
 
1466
    unsigned int        /* width */,
 
1467
    unsigned int        /* height */,
 
1468
    XieConstant         /* constant */,
 
1469
    XieTile *           /* tiles */,
 
1470
    unsigned int        /* tile_count */
 
1471
#endif
 
1472
);
 
1473
 
 
1474
extern void XieFloPoint (
 
1475
#if NeedFunctionPrototypes
 
1476
    XiePhotoElement *   /* element */,
 
1477
    XiePhototag         /* src */,
 
1478
    XieProcessDomain *  /* domain */,
 
1479
    XiePhototag         /* lut */,
 
1480
    unsigned int        /* band_mask */
 
1481
#endif
 
1482
);
 
1483
 
 
1484
extern void XieFloUnconstrain (
 
1485
#if NeedFunctionPrototypes
 
1486
    XiePhotoElement *   /* element */,
 
1487
    XiePhototag         /* src */
 
1488
#endif
 
1489
);
 
1490
 
 
1491
extern void XieFloExportClientHistogram (
 
1492
#if NeedFunctionPrototypes
 
1493
    XiePhotoElement *   /* element */,
 
1494
    XiePhototag         /* src */,
 
1495
    XieProcessDomain *  /* domain */,
 
1496
    XieExportNotify     /* notify */
 
1497
#endif
 
1498
);
 
1499
 
 
1500
extern void XieFloExportClientLUT (
 
1501
#if NeedFunctionPrototypes
 
1502
    XiePhotoElement *   /* element */,
 
1503
    XiePhototag         /* src */,
 
1504
    XieOrientation      /* band_order */,
 
1505
    XieExportNotify     /* notify */,
 
1506
    XieLTriplet         /* start */,
 
1507
    XieLTriplet         /* length */
 
1508
#endif
 
1509
);
 
1510
 
 
1511
extern void XieFloExportClientPhoto (
 
1512
#if NeedFunctionPrototypes
 
1513
    XiePhotoElement *   /* element */,
 
1514
    XiePhototag         /* src */,
 
1515
    XieExportNotify     /* notify */,
 
1516
    XieEncodeTechnique  /* encode_tech */,
 
1517
    XiePointer          /* encode_param */
 
1518
#endif
 
1519
);
 
1520
 
 
1521
extern void XieFloExportClientROI (
 
1522
#if NeedFunctionPrototypes
 
1523
    XiePhotoElement *   /* element */,
 
1524
    XiePhototag         /* src */,
 
1525
    XieExportNotify     /* notify */
 
1526
#endif
 
1527
);
 
1528
 
 
1529
extern void XieFloExportDrawable (
 
1530
#if NeedFunctionPrototypes
 
1531
    XiePhotoElement *   /* element */,
 
1532
    XiePhototag         /* src */,
 
1533
    Drawable            /* drawable */,
 
1534
    GC                  /* gc */,
 
1535
    int                 /* dst_x */,
 
1536
    int                 /* dst_y */
 
1537
#endif
 
1538
);
 
1539
 
 
1540
extern void XieFloExportDrawablePlane (
 
1541
#if NeedFunctionPrototypes
 
1542
    XiePhotoElement *   /* element */,
 
1543
    XiePhototag         /* src */,
 
1544
    Drawable            /* drawable */,
 
1545
    GC                  /* gc */,
 
1546
    int                 /* dst_x */,
 
1547
    int                 /* dst_y */
 
1548
#endif
 
1549
);
 
1550
 
 
1551
extern void XieFloExportLUT (
 
1552
#if NeedFunctionPrototypes
 
1553
    XiePhotoElement *   /* element */,
 
1554
    XiePhototag         /* src */,
 
1555
    XieLut              /* lut */,
 
1556
    Bool                /* merge */,
 
1557
    XieLTriplet         /* start */
 
1558
#endif
 
1559
);
 
1560
 
 
1561
extern void XieFloExportPhotomap (
 
1562
#if NeedFunctionPrototypes
 
1563
    XiePhotoElement *   /* element */,
 
1564
    XiePhototag         /* src */,
 
1565
    XiePhotomap         /* photomap */,
 
1566
    XieEncodeTechnique  /* encode_tech */,
 
1567
    XiePointer          /* encode_param */
 
1568
#endif
 
1569
);
 
1570
 
 
1571
extern void XieFloExportROI (
 
1572
#if NeedFunctionPrototypes
 
1573
    XiePhotoElement *   /* element */,
 
1574
    XiePhototag         /* src */,
 
1575
    XieRoi              /* roi */
 
1576
#endif
 
1577
);
 
1578
 
 
1579
 
 
1580
/* Technique functions -----------------------------------------------------*/
 
1581
 
 
1582
extern XieColorAllocAllParam *XieTecColorAllocAll (
 
1583
#if NeedFunctionPrototypes
 
1584
    unsigned long       /* fill */
 
1585
#endif
 
1586
);
 
1587
 
 
1588
extern XieColorAllocMatchParam *XieTecColorAllocMatch (
 
1589
#if NeedFunctionPrototypes
 
1590
    double              /* match_limit */,
 
1591
    double              /* gray_limit */
 
1592
#endif
 
1593
);
 
1594
 
 
1595
extern XieColorAllocRequantizeParam *XieTecColorAllocRequantize (
 
1596
#if NeedFunctionPrototypes
 
1597
    unsigned long       /* max_cells */
 
1598
#endif
 
1599
);
 
1600
 
 
1601
extern XieRGBToCIELabParam *XieTecRGBToCIELab (
 
1602
#if NeedFunctionPrototypes
 
1603
    XieMatrix                   /* matrix */,
 
1604
    XieWhiteAdjustTechnique     /* white_adjust_tech */,
 
1605
    XiePointer                  /* white_adjust_param */
 
1606
#endif
 
1607
);
 
1608
 
 
1609
extern XieRGBToCIEXYZParam *XieTecRGBToCIEXYZ (
 
1610
#if NeedFunctionPrototypes
 
1611
    XieMatrix                   /* matrix */,
 
1612
    XieWhiteAdjustTechnique     /* white_adjust_tech */,
 
1613
    XiePointer                  /* white_adjust_param */
 
1614
#endif
 
1615
);
 
1616
 
 
1617
extern XieRGBToYCbCrParam *XieTecRGBToYCbCr (
 
1618
#if NeedFunctionPrototypes
 
1619
    XieLevels           /* levels */,
 
1620
    double              /* luma_red */,
 
1621
    double              /* luma_green */,
 
1622
    double              /* luma_blue */,
 
1623
    XieConstant         /* bias */
 
1624
#endif
 
1625
);
 
1626
 
 
1627
extern XieRGBToYCCParam *XieTecRGBToYCC (
 
1628
#if NeedFunctionPrototypes
 
1629
    XieLevels           /* levels */,
 
1630
    double              /* luma_red */,
 
1631
    double              /* luma_green */,
 
1632
    double              /* luma_blue */,
 
1633
    double              /* scale */
 
1634
#endif
 
1635
);
 
1636
 
 
1637
extern XieCIELabToRGBParam *XieTecCIELabToRGB (
 
1638
#if NeedFunctionPrototypes
 
1639
    XieMatrix                   /* matrix */,
 
1640
    XieWhiteAdjustTechnique     /* white_adjust_tech */,
 
1641
    XiePointer                  /* white_adjust_param */,
 
1642
    XieGamutTechnique           /* gamut_tech */,
 
1643
    XiePointer                  /* gamut_param */
 
1644
#endif
 
1645
);
 
1646
 
 
1647
extern XieCIEXYZToRGBParam *XieTecCIEXYZToRGB (
 
1648
#if NeedFunctionPrototypes
 
1649
    XieMatrix                   /* matrix */,
 
1650
    XieWhiteAdjustTechnique     /* white_adjust_tech */,
 
1651
    XiePointer                  /* white_adjust_param */,
 
1652
    XieGamutTechnique           /* gamut_tech */,
 
1653
    XiePointer                  /* gamut_param */
 
1654
#endif
 
1655
);
 
1656
 
 
1657
extern XieYCbCrToRGBParam *XieTecYCbCrToRGB (
 
1658
#if NeedFunctionPrototypes
 
1659
    XieLevels           /* levels */,
 
1660
    double              /* luma_red */,
 
1661
    double              /* luma_green */,
 
1662
    double              /* luma_blue */,
 
1663
    XieConstant         /* bias */,
 
1664
    XieGamutTechnique   /* gamut_tech */,
 
1665
    XiePointer          /* gamut_param */
 
1666
#endif
 
1667
);
 
1668
 
 
1669
extern XieYCCToRGBParam *XieTecYCCToRGB (
 
1670
#if NeedFunctionPrototypes
 
1671
    XieLevels           /* levels */,
 
1672
    double              /* luma_red */,
 
1673
    double              /* luma_green */,
 
1674
    double              /* luma_blue */,
 
1675
    double              /* scale */,
 
1676
    XieGamutTechnique   /* gamut_tech */,
 
1677
    XiePointer          /* gamut_param */
 
1678
#endif
 
1679
);
 
1680
 
 
1681
extern XieClipScaleParam *XieTecClipScale (
 
1682
#if NeedFunctionPrototypes
 
1683
    XieConstant         /* in_low */,
 
1684
    XieConstant         /* in_high */,
 
1685
    XieLTriplet         /* out_low */,
 
1686
    XieLTriplet         /* out_high */
 
1687
#endif
 
1688
);
 
1689
 
 
1690
extern XieConvolveConstantParam *XieTecConvolveConstant (
 
1691
#if NeedFunctionPrototypes
 
1692
    XieConstant         /* constant */
 
1693
#endif
 
1694
);
 
1695
 
 
1696
extern XieDecodeUncompressedSingleParam *XieTecDecodeUncompressedSingle (
 
1697
#if NeedFunctionPrototypes
 
1698
    XieOrientation      /* fill_order */,
 
1699
    XieOrientation      /* pixel_order */,
 
1700
    unsigned int        /* pixel_stride */,
 
1701
    unsigned int        /* left_pad */,
 
1702
    unsigned int        /* scanline_pad */
 
1703
#endif
 
1704
);
 
1705
 
 
1706
extern XieDecodeUncompressedTripleParam *XieTecDecodeUncompressedTriple (
 
1707
#if NeedFunctionPrototypes
 
1708
    XieOrientation      /* fill_order */,
 
1709
    XieOrientation      /* pixel_order */,
 
1710
    XieOrientation      /* band_order */,
 
1711
    XieInterleave       /* interleave */,
 
1712
    unsigned char[3]    /* pixel_stride[3] */,
 
1713
    unsigned char[3]    /* left_pad[3] */,
 
1714
    unsigned char[3]    /* scanline_pad[3] */
 
1715
#endif
 
1716
);
 
1717
 
 
1718
extern XieDecodeG31DParam *XieTecDecodeG31D (
 
1719
#if NeedFunctionPrototypes
 
1720
    XieOrientation      /* encoded_order */,
 
1721
    Bool                /* normal */,
 
1722
    Bool                /* radiometric */
 
1723
#endif
 
1724
);
 
1725
 
 
1726
extern XieDecodeG32DParam *XieTecDecodeG32D (
 
1727
#if NeedFunctionPrototypes
 
1728
    XieOrientation      /* encoded_order */,
 
1729
    Bool                /* normal */,
 
1730
    Bool                /* radiometric */
 
1731
#endif
 
1732
);
 
1733
 
 
1734
extern XieDecodeG42DParam *XieTecDecodeG42D (
 
1735
#if NeedFunctionPrototypes
 
1736
    XieOrientation      /* encoded_order */,
 
1737
    Bool                /* normal */,
 
1738
    Bool                /* radiometric */
 
1739
#endif
 
1740
);
 
1741
 
 
1742
extern XieDecodeTIFF2Param *XieTecDecodeTIFF2 (
 
1743
#if NeedFunctionPrototypes
 
1744
    XieOrientation      /* encoded_order */,
 
1745
    Bool                /* normal */,
 
1746
    Bool                /* radiometric */
 
1747
#endif
 
1748
);
 
1749
 
 
1750
extern XieDecodeTIFFPackBitsParam *XieTecDecodeTIFFPackBits (
 
1751
#if NeedFunctionPrototypes
 
1752
    XieOrientation      /* encoded_order */,
 
1753
    Bool                /* normal */
 
1754
#endif
 
1755
);
 
1756
 
 
1757
extern XieDecodeJPEGBaselineParam *XieTecDecodeJPEGBaseline (
 
1758
#if NeedFunctionPrototypes
 
1759
    XieInterleave       /* interleave */,
 
1760
    XieOrientation      /* band_order */,
 
1761
    Bool                /* up_sample  */
 
1762
#endif
 
1763
);
 
1764
 
 
1765
extern XieDecodeJPEGLosslessParam *XieTecDecodeJPEGLossless (
 
1766
#if NeedFunctionPrototypes
 
1767
    XieInterleave       /* interleave */,
 
1768
    XieOrientation      /* band_order */
 
1769
#endif
 
1770
);
 
1771
 
 
1772
extern XieDitherOrderedParam *XieTecDitherOrderedParam (
 
1773
#if NeedFunctionPrototypes
 
1774
    unsigned int        /* threshold_order */
 
1775
#endif
 
1776
);
 
1777
 
 
1778
extern XieEncodeUncompressedSingleParam *XieTecEncodeUncompressedSingle (
 
1779
#if NeedFunctionPrototypes
 
1780
    XieOrientation      /* fill_order */,
 
1781
    XieOrientation      /* pixel_order */,
 
1782
    unsigned int        /* pixel_stride */,
 
1783
    unsigned int        /* scanline_pad */
 
1784
#endif
 
1785
);
 
1786
 
 
1787
extern XieEncodeUncompressedTripleParam *XieTecEncodeUncompressedTriple (
 
1788
#if NeedFunctionPrototypes
 
1789
    XieOrientation      /* fill_order */,
 
1790
    XieOrientation      /* pixel_order */,
 
1791
    XieOrientation      /* band_order */,
 
1792
    XieInterleave       /* interleave */,
 
1793
    unsigned char[3]    /* pixel_stride[3] */,
 
1794
    unsigned char[3]    /* scanline_pad[3] */
 
1795
#endif
 
1796
);
 
1797
 
 
1798
extern XieEncodeG31DParam *XieTecEncodeG31D (
 
1799
#if NeedFunctionPrototypes
 
1800
    Bool                /* align_eol */,
 
1801
    Bool                /* radiometric */,
 
1802
    XieOrientation      /* encoded_order */
 
1803
#endif
 
1804
);
 
1805
 
 
1806
extern XieEncodeG32DParam *XieTecEncodeG32D (
 
1807
#if NeedFunctionPrototypes
 
1808
    Bool                /* uncompressed */,
 
1809
    Bool                /* align_eol */,
 
1810
    Bool                /* radiometric */,
 
1811
    XieOrientation      /* encoded_order */,
 
1812
    unsigned long       /* k_factor */
 
1813
#endif
 
1814
);
 
1815
 
 
1816
extern XieEncodeG42DParam *XieTecEncodeG42D (
 
1817
#if NeedFunctionPrototypes
 
1818
    Bool                /* uncompressed */,
 
1819
    Bool                /* radiometric */,
 
1820
    XieOrientation      /* encoded_order */
 
1821
#endif
 
1822
);
 
1823
 
 
1824
extern XieEncodeServerChoiceParam *XieTecEncodeServerChoice (
 
1825
#if NeedFunctionPrototypes
 
1826
    unsigned int        /* preference */
 
1827
#endif
 
1828
);
 
1829
 
 
1830
extern XieEncodeJPEGBaselineParam *XieTecEncodeJPEGBaseline (
 
1831
#if NeedFunctionPrototypes
 
1832
    XieInterleave       /* interleave */,
 
1833
    XieOrientation      /* band_order */,
 
1834
    unsigned char[3]    /* horizontal_samples[3] */,
 
1835
    unsigned char[3]    /* vertical_samples[3] */,
 
1836
    char *              /* q_table */,
 
1837
    unsigned int        /* q_size */,
 
1838
    char *              /* ac_table */,
 
1839
    unsigned int        /* ac_size */,
 
1840
    char *              /* dc_table */,
 
1841
    unsigned int        /* dc_size */
 
1842
#endif
 
1843
);
 
1844
 
 
1845
extern void XieFreeEncodeJPEGBaseline (
 
1846
#if NeedFunctionPrototypes
 
1847
    XieEncodeJPEGBaselineParam *        /* param */
 
1848
#endif
 
1849
);
 
1850
 
 
1851
extern XieEncodeJPEGLosslessParam *XieTecEncodeJPEGLossless (
 
1852
#if NeedFunctionPrototypes
 
1853
    XieInterleave       /* interleave */,
 
1854
    XieOrientation      /* band_order */,
 
1855
    unsigned char[3]    /* predictor[3] */,
 
1856
    char *              /* table */,
 
1857
    unsigned int        /* table_size */
 
1858
#endif
 
1859
);
 
1860
 
 
1861
extern void XieFreeEncodeJPEGLossless (
 
1862
#if NeedFunctionPrototypes
 
1863
    XieEncodeJPEGLosslessParam *        /* param */
 
1864
#endif
 
1865
);
 
1866
 
 
1867
extern void XieFreePasteUpTiles (
 
1868
#if NeedFunctionPrototypes
 
1869
    XiePhotoElement *   /* element */
 
1870
#endif
 
1871
);
 
1872
 
 
1873
extern XieEncodeTIFF2Param *XieTecEncodeTIFF2 (
 
1874
#if NeedFunctionPrototypes
 
1875
    XieOrientation      /* encoded_order */,
 
1876
    Bool                /* radiometric */
 
1877
#endif
 
1878
);
 
1879
 
 
1880
extern XieEncodeTIFFPackBitsParam *XieTecEncodeTIFFPackBits (
 
1881
#if NeedFunctionPrototypes
 
1882
    XieOrientation      /* encoded_order */
 
1883
#endif
 
1884
);
 
1885
 
 
1886
extern XieGeomAntialiasByAreaParam *XieTecGeomAntialiasByArea (
 
1887
#if NeedFunctionPrototypes
 
1888
    int                 /* simple */
 
1889
#endif
 
1890
);
 
1891
 
 
1892
extern XieGeomAntialiasByLowpassParam *XieTecGeomAntialiasByLowpass (
 
1893
#if NeedFunctionPrototypes
 
1894
    int                 /* kernel_size */
 
1895
#endif
 
1896
);
 
1897
 
 
1898
extern XieGeomGaussianParam *XieTecGeomGaussian (
 
1899
#if NeedFunctionPrototypes
 
1900
    double              /* sigma */,
 
1901
    double              /* normalize */,
 
1902
    unsigned int        /* radius */,
 
1903
    Bool                /* simple */
 
1904
#endif
 
1905
);
 
1906
 
 
1907
extern XieGeomNearestNeighborParam *XieTecGeomNearestNeighbor (
 
1908
#if NeedFunctionPrototypes
 
1909
    unsigned int        /* modify */
 
1910
#endif
 
1911
);
 
1912
 
 
1913
extern XieHistogramGaussianParam *XieTecHistogramGaussian (
 
1914
#if NeedFunctionPrototypes
 
1915
    double              /* mean */,
 
1916
    double              /* sigma */
 
1917
#endif
 
1918
);
 
1919
 
 
1920
extern XieHistogramHyperbolicParam *XieTecHistogramHyperbolic (
 
1921
#if NeedFunctionPrototypes
 
1922
    double              /* constant */,
 
1923
    Bool                /* shape_factor */
 
1924
#endif
 
1925
);
 
1926
 
 
1927
extern XieWhiteAdjustCIELabShiftParam *XieTecWhiteAdjustCIELabShift (
 
1928
#if NeedFunctionPrototypes
 
1929
    XieConstant         /* white_point */
 
1930
#endif
 
1931
);
 
1932
 
 
1933
 
 
1934
#endif /* _XIELIB_H_ */