1 /* This file is part of GEGL
2  *
3  * GEGL is free software; you can redistribute it and/or
4  * modify it under the terms of the GNU Lesser General Public
5  * License as published by the Free Software Foundation; either
6  * version 3 of the License, or (at your option) any later version.
7  *
8  * GEGL is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11  * Lesser General Public License for more details.
12  *
13  * You should have received a copy of the GNU Lesser General Public
14  * License along with GEGL; if not, see <https://www.gnu.org/licenses/>.
15  *
16  * Copyright 2011 Michael Muré <batolettre@gmail.com>
17  *
18  */
19 
20 /* This file holds public enums from GEGL
21  *
22  * !!!!!!!!!!!! NOTE !!!!!!!!!!!!!!
23  *
24  * Normally, gegl-enums.c file would be be generated my glib-mkenums,
25  * but we use the enum values' registered names for translatable,
26  * human readable labels for the GUI, so gegl-enums.c is maintained
27  * manually.
28  *
29  * DON'T FORGET TO UPDATE gegl-enums.c AFTER CHANGING THIS HEADER
30  *
31  * !!!!!!!!!!!! NOTE !!!!!!!!!!!!!!
32  */
33 
34 #ifndef __GEGL_BUFFER_ENUMS_H__
35 #define __GEGL_BUFFER_ENUMS_H__
36 
37 G_BEGIN_DECLS
38 
39 typedef enum {
40   /* this enum should be renamed GeglBufferFlags, since it contains
41    * multiple flags - and possibly more in the future
42    */
43 
44   /* XXX: API tidying of the following would be to make them be
45    *      GEGL_BUFFER_EDGE_NONE or GEGL_BUFFER_REPEAT_NONE instead.
46   */
47   GEGL_ABYSS_NONE  = 0,
48   GEGL_ABYSS_CLAMP = 1,
49   GEGL_ABYSS_LOOP  = 2,
50   GEGL_ABYSS_BLACK = 3,
51   GEGL_ABYSS_WHITE = 4,
52 
53   GEGL_BUFFER_FILTER_AUTO     = 0,
54   /* auto gives bilinear for scales <1.0 box for <2.0 and nearest above */
55   GEGL_BUFFER_FILTER_BILINEAR = 16,
56   GEGL_BUFFER_FILTER_NEAREST  = 32,
57   GEGL_BUFFER_FILTER_BOX      = 48,
58   GEGL_BUFFER_FILTER_ALL      = (GEGL_BUFFER_FILTER_BILINEAR|
59                                  GEGL_BUFFER_FILTER_NEAREST|
60                                  GEGL_BUFFER_FILTER_BOX),
61 } GeglAbyssPolicy;
62 
63 GType gegl_abyss_policy_get_type (void) G_GNUC_CONST;
64 
65 #define GEGL_TYPE_ABYSS_POLICY (gegl_abyss_policy_get_type ())
66 
67 
68 typedef enum {
69   GEGL_ACCESS_READ      = 1 << 0,
70   GEGL_ACCESS_WRITE     = 1 << 1,
71   GEGL_ACCESS_READWRITE = (GEGL_ACCESS_READ | GEGL_ACCESS_WRITE)
72 } GeglAccessMode;
73 
74 GType gegl_access_mode_get_type (void) G_GNUC_CONST;
75 
76 #define GEGL_TYPE_ACCESS_MODE (gegl_access_mode_get_type ())
77 
78 typedef enum {
79   GEGL_SAMPLER_NEAREST,
80   GEGL_SAMPLER_LINEAR,
81   GEGL_SAMPLER_CUBIC,
82   GEGL_SAMPLER_NOHALO,
83   GEGL_SAMPLER_LOHALO
84 } GeglSamplerType;
85 
86 GType gegl_sampler_type_get_type (void) G_GNUC_CONST;
87 
88 #define GEGL_TYPE_SAMPLER_TYPE (gegl_sampler_type_get_type ())
89 
90 typedef enum {
91   GEGL_RECTANGLE_ALIGNMENT_SUBSET,
92   GEGL_RECTANGLE_ALIGNMENT_SUPERSET,
93   GEGL_RECTANGLE_ALIGNMENT_NEAREST
94 } GeglRectangleAlignment;
95 
96 GType gegl_rectangle_alignment_get_type (void) G_GNUC_CONST;
97 
98 #define GEGL_TYPE_RECTANGLE_ALIGNMENT (gegl_rectangle_alignment_get_type ())
99 
100 G_END_DECLS
101 
102 #endif /* __GEGL_ENUMS_H__ */
103