2 |
- |
1 |
/* Copyright (C) 1997 Aladdin Enterprises. All rights reserved.
|
|
|
2 |
|
|
|
3 |
This software is provided AS-IS with no warranty, either express or
|
|
|
4 |
implied.
|
|
|
5 |
|
|
|
6 |
This software is distributed under license and may not be copied,
|
|
|
7 |
modified or distributed except as expressly authorized under the terms
|
|
|
8 |
of the license contained in the file LICENSE in this distribution.
|
|
|
9 |
|
|
|
10 |
For more information about licensing, please refer to
|
|
|
11 |
http://www.ghostscript.com/licensing/. For information on
|
|
|
12 |
commercial licensing, go to http://www.artifex.com/licensing/ or
|
|
|
13 |
contact Artifex Software, Inc., 101 Lucas Valley Road #110,
|
|
|
14 |
San Rafael, CA 94903, U.S.A., +1(415)492-9861.
|
|
|
15 |
*/
|
|
|
16 |
|
|
|
17 |
/* $Id: gsalphac.h,v 1.5 2002/06/16 08:45:42 lpd Exp $ */
|
|
|
18 |
/* Alpha-compositing interface */
|
|
|
19 |
|
|
|
20 |
#ifndef gsalphac_INCLUDED
|
|
|
21 |
# define gsalphac_INCLUDED
|
|
|
22 |
|
|
|
23 |
#include "gscompt.h"
|
|
|
24 |
|
|
|
25 |
/*
|
|
|
26 |
* Define the compositing operations. These values must match the ones in
|
|
|
27 |
* dpsNeXT.h.
|
|
|
28 |
*/
|
|
|
29 |
typedef enum {
|
|
|
30 |
composite_Clear = 0,
|
|
|
31 |
composite_Copy,
|
|
|
32 |
composite_Sover,
|
|
|
33 |
composite_Sin,
|
|
|
34 |
composite_Sout,
|
|
|
35 |
composite_Satop,
|
|
|
36 |
composite_Dover,
|
|
|
37 |
composite_Din,
|
|
|
38 |
composite_Dout,
|
|
|
39 |
composite_Datop,
|
|
|
40 |
composite_Xor,
|
|
|
41 |
composite_PlusD,
|
|
|
42 |
composite_PlusL,
|
|
|
43 |
#define composite_last composite_PlusL
|
|
|
44 |
composite_Highlight, /* (only for compositerect) */
|
|
|
45 |
#define compositerect_last composite_Highlight
|
|
|
46 |
composite_Dissolve /* (not for PostScript composite operators) */
|
|
|
47 |
#define composite_op_last composite_Dissolve
|
|
|
48 |
} gs_composite_op_t;
|
|
|
49 |
|
|
|
50 |
/*
|
|
|
51 |
* Define parameters for alpha-compositing.
|
|
|
52 |
*/
|
|
|
53 |
typedef struct gs_composite_alpha_params_s {
|
|
|
54 |
gs_composite_op_t op;
|
|
|
55 |
float delta; /* only for Dissolve */
|
|
|
56 |
} gs_composite_alpha_params_t;
|
|
|
57 |
|
|
|
58 |
/* Create an alpha-compositing object. */
|
|
|
59 |
int gs_create_composite_alpha(gs_composite_t ** ppcte,
|
|
|
60 |
const gs_composite_alpha_params_t * params,
|
|
|
61 |
gs_memory_t * mem);
|
|
|
62 |
|
|
|
63 |
#endif /* gsalphac_INCLUDED */
|