]> git.ipfire.org Git - thirdparty/cups.git/blame - filter/image-sgi.h
Y2k copyright changes.
[thirdparty/cups.git] / filter / image-sgi.h
CommitLineData
1012c8a8 1/*
71fe22b7 2 * "$Id: image-sgi.h,v 1.4 2000/01/04 13:45:45 mike Exp $"
1012c8a8 3 *
ed19bd98 4 * SGI image file format library definitions for the Common UNIX Printing
5 * System (CUPS).
1012c8a8 6 *
71fe22b7 7 * Copyright 1993-2000 by Easy Software Products.
1012c8a8 8 *
ed19bd98 9 * These coded instructions, statements, and computer programs are the
10 * property of Easy Software Products and are protected by Federal
11 * copyright law. Distribution and use rights are outlined in the file
12 * "LICENSE.txt" which should have been included with this file. If this
13 * file is missing or damaged please contact Easy Software Products
14 * at:
1012c8a8 15 *
ed19bd98 16 * Attn: CUPS Licensing Information
17 * Easy Software Products
18 * 44141 Airport View Drive, Suite 204
19 * Hollywood, Maryland 20636-3111 USA
1012c8a8 20 *
ed19bd98 21 * Voice: (301) 373-9603
22 * EMail: cups-info@cups.org
23 * WWW: http://www.cups.org
1012c8a8 24 */
25
26#ifndef _SGI_H_
27# define _SGI_H_
28
29# include <stdio.h>
30# include <stdlib.h>
31# include <string.h>
32
33# ifdef __cplusplus
34extern "C" {
35# endif
36
37
38/*
39 * Constants...
40 */
41
42# define SGI_MAGIC 474 /* Magic number in image file */
43
44# define SGI_READ 0 /* Read from an SGI image file */
45# define SGI_WRITE 1 /* Write to an SGI image file */
46
47# define SGI_COMP_NONE 0 /* No compression */
48# define SGI_COMP_RLE 1 /* Run-length encoding */
49# define SGI_COMP_ARLE 2 /* Agressive run-length encoding */
50
51
52/*
53 * Image structure...
54 */
55
56typedef struct
57{
58 FILE *file; /* Image file */
59 int mode, /* File open mode */
60 bpp, /* Bytes per pixel/channel */
61 comp; /* Compression */
62 unsigned short xsize, /* Width in pixels */
63 ysize, /* Height in pixels */
64 zsize; /* Number of channels */
65 long firstrow, /* File offset for first row */
66 nextrow, /* File offset for next row */
67 **table, /* Offset table for compression */
68 **length; /* Length table for compression */
6de9968b 69 unsigned short *arle_row; /* Advanced RLE compression buffer */
1012c8a8 70 long arle_offset, /* Advanced RLE buffer offset */
71 arle_length; /* Advanced RLE buffer length */
72} sgi_t;
73
74
75/*
76 * Prototypes...
77 */
78
79extern int sgiClose(sgi_t *sgip);
6de9968b 80extern int sgiGetRow(sgi_t *sgip, unsigned short *row, int y, int z);
1012c8a8 81extern sgi_t *sgiOpen(char *filename, int mode, int comp, int bpp,
82 int xsize, int ysize, int zsize);
83extern sgi_t *sgiOpenFile(FILE *file, int mode, int comp, int bpp,
84 int xsize, int ysize, int zsize);
6de9968b 85extern int sgiPutRow(sgi_t *sgip, unsigned short *row, int y, int z);
1012c8a8 86
87# ifdef __cplusplus
88}
89# endif
90#endif /* !_SGI_H_ */
91
92/*
71fe22b7 93 * End of "$Id: image-sgi.h,v 1.4 2000/01/04 13:45:45 mike Exp $".
1012c8a8 94 */