2016-03-17 13:48:19 +00:00
|
|
|
/* GSK - The GTK Scene Kit
|
|
|
|
* Copyright 2016 Endless
|
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
|
|
* License as published by the Free Software Foundation; either
|
|
|
|
* version 2 of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Lesser General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
|
|
* License along with this library. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __GSK_ENUMS_H__
|
|
|
|
#define __GSK_ENUMS_H__
|
|
|
|
|
|
|
|
#if !defined (__GSK_H_INSIDE__) && !defined (GSK_COMPILATION)
|
|
|
|
#error "Only <gsk/gsk.h> can be included directly."
|
|
|
|
#endif
|
|
|
|
|
2016-12-10 20:42:01 +00:00
|
|
|
/**
|
|
|
|
* GskRenderNodeType:
|
|
|
|
* @GSK_NOT_A_RENDER_NODE: Error type. No node will ever have this type.
|
|
|
|
* @GSK_CONTAINER_NODE: A node containing a stack of children
|
|
|
|
* @GSK_CAIRO_NODE: A node drawing a #cairo_surface_t
|
2016-12-13 02:35:56 +00:00
|
|
|
* @GSK_COLOR_NODE: A node drawing a single color rectangle
|
2016-12-15 04:42:31 +00:00
|
|
|
* @GSK_LINEAR_GRADIENT_NODE: A node drawing a linear gradient
|
2017-09-21 01:16:45 +00:00
|
|
|
* @GSK_REPEATING_LINEAR_GRADIENT_NODE: A node drawing a repeating linear gradient
|
2016-12-18 17:14:53 +00:00
|
|
|
* @GSK_BORDER_NODE: A node stroking a border around an area
|
2017-11-04 15:03:03 +00:00
|
|
|
* @GSK_TEXTURE_NODE: A node drawing a #GdkTexture
|
2016-12-19 04:13:42 +00:00
|
|
|
* @GSK_INSET_SHADOW_NODE: A node drawing an inset shadow
|
2016-12-19 14:39:43 +00:00
|
|
|
* @GSK_OUTSET_SHADOW_NODE: A node drawing an outset shadow
|
2017-09-21 01:16:45 +00:00
|
|
|
* @GSK_TRANSFORM_NODE: A node that renders its child after applying a matrix transform
|
2016-12-13 04:49:57 +00:00
|
|
|
* @GSK_OPACITY_NODE: A node that changes the opacity of its child
|
2017-01-01 18:52:18 +00:00
|
|
|
* @GSK_COLOR_MATRIX_NODE: A node that applies a color matrix to every pixel
|
|
|
|
* @GSK_REPEAT_NODE: A node that repeats the child's contents
|
2016-12-13 08:37:51 +00:00
|
|
|
* @GSK_CLIP_NODE: A node that clips its child to a rectangular area
|
2016-12-13 18:02:12 +00:00
|
|
|
* @GSK_ROUNDED_CLIP_NODE: A node that clips its child to a rounded rectangle
|
2016-12-18 23:45:35 +00:00
|
|
|
* @GSK_SHADOW_NODE: A node that draws a shadow below its child
|
2017-08-29 22:10:14 +00:00
|
|
|
* @GSK_BLEND_NODE: A node that blends two children together
|
|
|
|
* @GSK_CROSS_FADE_NODE: A node that cross-fades between two children
|
2017-08-29 21:28:10 +00:00
|
|
|
* @GSK_TEXT_NODE: A node containing a glyph string
|
2017-09-03 03:49:34 +00:00
|
|
|
* @GSK_BLUR_NODE: A node that applies a blur
|
2018-03-26 17:41:38 +00:00
|
|
|
* @GSK_OFFSET_NODE: A node that renders its child after applying a 2D translation
|
2016-12-10 20:42:01 +00:00
|
|
|
*
|
|
|
|
* The type of a node determines what the node is rendering.
|
|
|
|
*
|
|
|
|
* Since: 3.90
|
|
|
|
**/
|
|
|
|
typedef enum {
|
|
|
|
GSK_NOT_A_RENDER_NODE = 0,
|
|
|
|
GSK_CONTAINER_NODE,
|
|
|
|
GSK_CAIRO_NODE,
|
2016-12-13 02:35:56 +00:00
|
|
|
GSK_COLOR_NODE,
|
2016-12-15 04:42:31 +00:00
|
|
|
GSK_LINEAR_GRADIENT_NODE,
|
|
|
|
GSK_REPEATING_LINEAR_GRADIENT_NODE,
|
2016-12-18 17:14:53 +00:00
|
|
|
GSK_BORDER_NODE,
|
2017-11-04 15:03:03 +00:00
|
|
|
GSK_TEXTURE_NODE,
|
2016-12-19 04:13:42 +00:00
|
|
|
GSK_INSET_SHADOW_NODE,
|
2016-12-19 14:39:43 +00:00
|
|
|
GSK_OUTSET_SHADOW_NODE,
|
2016-12-13 04:49:57 +00:00
|
|
|
GSK_TRANSFORM_NODE,
|
2016-12-13 08:37:51 +00:00
|
|
|
GSK_OPACITY_NODE,
|
2016-12-31 00:13:19 +00:00
|
|
|
GSK_COLOR_MATRIX_NODE,
|
2017-01-01 18:52:18 +00:00
|
|
|
GSK_REPEAT_NODE,
|
2016-12-13 18:02:12 +00:00
|
|
|
GSK_CLIP_NODE,
|
2016-12-15 03:24:37 +00:00
|
|
|
GSK_ROUNDED_CLIP_NODE,
|
2016-12-18 23:45:35 +00:00
|
|
|
GSK_SHADOW_NODE,
|
2016-12-17 06:44:10 +00:00
|
|
|
GSK_BLEND_NODE,
|
2017-08-29 21:28:10 +00:00
|
|
|
GSK_CROSS_FADE_NODE,
|
2017-09-03 03:49:34 +00:00
|
|
|
GSK_TEXT_NODE,
|
2018-03-26 17:41:38 +00:00
|
|
|
GSK_BLUR_NODE,
|
2018-04-23 22:41:48 +00:00
|
|
|
GSK_OFFSET_NODE,
|
|
|
|
GSK_DEBUG_NODE
|
2016-12-10 20:42:01 +00:00
|
|
|
} GskRenderNodeType;
|
|
|
|
|
2016-03-17 13:48:19 +00:00
|
|
|
/**
|
|
|
|
* GskScalingFilter:
|
|
|
|
* @GSK_SCALING_FILTER_LINEAR: linear interpolation filter
|
|
|
|
* @GSK_SCALING_FILTER_NEAREST: nearest neighbor interpolation filter
|
|
|
|
* @GSK_SCALING_FILTER_TRILINEAR: linear interpolation along each axis,
|
|
|
|
* plus mipmap generation, with linear interpolation along the mipmap
|
|
|
|
* levels
|
|
|
|
*
|
|
|
|
* The filters used when scaling texture data.
|
|
|
|
*
|
|
|
|
* The actual implementation of each filter is deferred to the
|
|
|
|
* rendering pipeline.
|
|
|
|
*
|
2016-10-18 10:37:10 +00:00
|
|
|
* Since: 3.90
|
2016-03-17 13:48:19 +00:00
|
|
|
*/
|
|
|
|
typedef enum {
|
|
|
|
GSK_SCALING_FILTER_LINEAR,
|
|
|
|
GSK_SCALING_FILTER_NEAREST,
|
|
|
|
GSK_SCALING_FILTER_TRILINEAR
|
|
|
|
} GskScalingFilter;
|
|
|
|
|
2016-07-01 11:02:43 +00:00
|
|
|
/**
|
|
|
|
* GskBlendMode:
|
|
|
|
* @GSK_BLEND_MODE_DEFAULT: The default blend mode, which specifies no blending
|
|
|
|
* @GSK_BLEND_MODE_MULTIPLY: The source color is multiplied by the destination
|
|
|
|
* and replaces the destination
|
2016-08-07 03:08:04 +00:00
|
|
|
* @GSK_BLEND_MODE_SCREEN: ...
|
2016-07-01 11:02:43 +00:00
|
|
|
* @GSK_BLEND_MODE_OVERLAY: ...
|
|
|
|
* @GSK_BLEND_MODE_DARKEN: ...
|
|
|
|
* @GSK_BLEND_MODE_LIGHTEN: ...
|
|
|
|
* @GSK_BLEND_MODE_COLOR_DODGE: ...
|
|
|
|
* @GSK_BLEND_MODE_COLOR_BURN: ...
|
|
|
|
* @GSK_BLEND_MODE_HARD_LIGHT: ...
|
|
|
|
* @GSK_BLEND_MODE_SOFT_LIGHT: ...
|
|
|
|
* @GSK_BLEND_MODE_DIFFERENCE: ...
|
|
|
|
* @GSK_BLEND_MODE_EXCLUSION: ...
|
2016-12-15 03:19:03 +00:00
|
|
|
* @GSK_BLEND_MODE_COLOR: ...
|
|
|
|
* @GSK_BLEND_MODE_HUE: ...
|
|
|
|
* @GSK_BLEND_MODE_SATURATION: ...
|
|
|
|
* @GSK_BLEND_MODE_LUMINOSITY: ...
|
2016-07-01 11:02:43 +00:00
|
|
|
*
|
|
|
|
* The blend modes available for render nodes.
|
|
|
|
*
|
|
|
|
* The implementation of each blend mode is deferred to the
|
|
|
|
* rendering pipeline.
|
|
|
|
*
|
2016-10-18 10:37:10 +00:00
|
|
|
* Since: 3.90
|
2016-07-01 11:02:43 +00:00
|
|
|
*/
|
|
|
|
typedef enum {
|
|
|
|
GSK_BLEND_MODE_DEFAULT = 0,
|
|
|
|
|
|
|
|
GSK_BLEND_MODE_MULTIPLY,
|
|
|
|
GSK_BLEND_MODE_SCREEN,
|
|
|
|
GSK_BLEND_MODE_OVERLAY,
|
|
|
|
GSK_BLEND_MODE_DARKEN,
|
|
|
|
GSK_BLEND_MODE_LIGHTEN,
|
|
|
|
GSK_BLEND_MODE_COLOR_DODGE,
|
|
|
|
GSK_BLEND_MODE_COLOR_BURN,
|
|
|
|
GSK_BLEND_MODE_HARD_LIGHT,
|
|
|
|
GSK_BLEND_MODE_SOFT_LIGHT,
|
|
|
|
GSK_BLEND_MODE_DIFFERENCE,
|
2016-12-15 03:19:03 +00:00
|
|
|
GSK_BLEND_MODE_EXCLUSION,
|
|
|
|
GSK_BLEND_MODE_COLOR,
|
|
|
|
GSK_BLEND_MODE_HUE,
|
|
|
|
GSK_BLEND_MODE_SATURATION,
|
|
|
|
GSK_BLEND_MODE_LUMINOSITY
|
2016-07-01 11:02:43 +00:00
|
|
|
} GskBlendMode;
|
|
|
|
|
2016-12-13 18:02:12 +00:00
|
|
|
/**
|
|
|
|
* GskCorner:
|
|
|
|
* @GSK_CORNER_TOP_LEFT: The top left corner
|
|
|
|
* @GSK_CORNER_TOP_RIGHT: The top right corner
|
|
|
|
* @GSK_CORNER_BOTTOM_RIGHT: The bottom right corner
|
|
|
|
* @GSK_CORNER_BOTTOM_LEFT: The bottom left corner
|
|
|
|
*
|
|
|
|
* The corner indices used by #GskRoundedRect.
|
|
|
|
*/
|
|
|
|
typedef enum {
|
|
|
|
GSK_CORNER_TOP_LEFT,
|
|
|
|
GSK_CORNER_TOP_RIGHT,
|
|
|
|
GSK_CORNER_BOTTOM_RIGHT,
|
|
|
|
GSK_CORNER_BOTTOM_LEFT
|
|
|
|
} GskCorner;
|
|
|
|
|
2016-12-23 07:03:36 +00:00
|
|
|
/**
|
|
|
|
* GskSerializationError:
|
|
|
|
* @GSK_SERIALIZATION_UNSUPPORTED_FORMAT: The format can not be
|
|
|
|
* identified
|
|
|
|
* @GSK_SERIALIZATION_UNSUPPORTED_VERSION: The version of the data
|
|
|
|
* is not understood
|
|
|
|
* @GSK_SERIALIZATION_INVALID_DATA: The given data may not exist in
|
|
|
|
* a proper serialization
|
|
|
|
*
|
|
|
|
* Errors that can happen during (de)serialization.
|
|
|
|
*/
|
|
|
|
typedef enum {
|
|
|
|
GSK_SERIALIZATION_UNSUPPORTED_FORMAT,
|
|
|
|
GSK_SERIALIZATION_UNSUPPORTED_VERSION,
|
|
|
|
GSK_SERIALIZATION_INVALID_DATA
|
|
|
|
} GskSerializationError;
|
|
|
|
|
2016-03-17 13:48:19 +00:00
|
|
|
#endif /* __GSK_TYPES_H__ */
|