2001-05-15 19:25:25 +08:00
|
|
|
/* The GIMP -- an image manipulation program
|
|
|
|
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program 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 General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __BASE_TYPES_H__
|
|
|
|
#define __BASE_TYPES_H__
|
|
|
|
|
|
|
|
|
include the new "paint-funcs/paint-funcs-types.h".
2001-11-28 Michael Natterer <mitch@gimp.org>
* app/base/base-types.h: include the new
"paint-funcs/paint-funcs-types.h".
* app/paint-funcs/Makefile.am
* app/paint-funcs/paint-funcs-types.h: new file. Includes
"base/base-types.h".
* app/paint-funcs/paint-funcs.[ch]: removed the enums here,
include "paint-funcs-types.h".
* app/widgets/widgets-types.h: include "display/display-types.h"
* app/display/display-types.h: include "widgets/widgets-types.h".
* app/tools/tools-types.h: include "display/display-types.h"
* app/gui/gui-types.h: include "tools/tools-types.h".
The order of namespaces/dependencies should be (but is not):
(base, paint-funcs) -> (core, file, xcf, pdb) ->
(widgets, display) -> tools -> gui
* app/path.c: include "tools/tools-types.h".
* app/core/Makefile.am
* app/core/gimpimage-guides.[ch]
* app/core/gimpimage-merge.[ch]
* app/core/gimpimage-resize.[ch]
* app/core/gimpimage-scale.[ch]: new files.
* app/core/gimpimage.[ch]: removed the stuff which is in the new
files. Reordered all functions in both the .h and .c files,
commented the groups of functions.
* app/core/gimpcontainer.c: create the handler_id using a counter,
not the address of a pointer, because the address *may* be the
same twice, added debugging output.
* app/core/gimpviewable.[ch]: added primitive support for getting
a preview GdkPixbuf.
* app/nav_window.c
* app/undo.c
* app/undo_history.c
* app/core/gimpimage-duplicate.c
* app/core/gimpimage-mask.[ch]
* app/display/gimpdisplay.c
* app/display/gimpdisplayshell-callbacks.c
* app/display/gimpdisplayshell-dnd.c
* app/display/gimpdisplayshell-render.c
* app/display/gimpdisplayshell-scale.c
* app/display/gimpdisplayshell-scroll.c
* app/gui/image-commands.c
* app/gui/info-window.c
* app/gui/layers-commands.c
* app/gui/palette-import-dialog.c
* app/tools/gimpbycolorselecttool.c
* app/tools/gimpeditselectiontool.c
* app/tools/gimpmeasuretool.c
* app/tools/gimpmovetool.c
* app/widgets/gimpcontainerview-utils.c
* app/xcf/xcf-load.c: changed accordingly, some cleanup.
* tools/pdbgen/pdb/guides.pdb
* tools/pdbgen/pdb/image.pdb: changed accordingly, reordered functions.
* app/plug_in.c: set the labels of the "Repeat" and "Re-Show" menu
items to the name of the last plug-in (Fixes #50986).
* app/display/gimpdisplayshell.[ch]: set the labels of "Undo" and
"Redo" to the resp. undo names. Much simplified the WM icon stuff
by removing most code and using gimp_viewable_get_new_preview_pixbuf().
* app/widgets/gimpbrushfactoryview.c: forgot to assign the GQuark
returned by gimp_container_add_handler().
* app/pdb/guides_cmds.c
* app/pdb/image_cmds.c
* libgimp/gimpimage_pdb.[ch]: regenerated.
2001-11-29 01:51:06 +08:00
|
|
|
#include "paint-funcs/paint-funcs-types.h"
|
|
|
|
|
|
|
|
|
2001-05-15 19:25:25 +08:00
|
|
|
/* magic constants */
|
2001-12-02 22:59:30 +08:00
|
|
|
/* FIXME: Remove magic constants! */
|
2001-05-15 19:25:25 +08:00
|
|
|
#define MAX_CHANNELS 4
|
|
|
|
|
|
|
|
#define GRAY_PIX 0
|
|
|
|
#define ALPHA_G_PIX 1
|
|
|
|
#define RED_PIX 0
|
|
|
|
#define GREEN_PIX 1
|
|
|
|
#define BLUE_PIX 2
|
|
|
|
#define ALPHA_PIX 3
|
|
|
|
#define INDEXED_PIX 0
|
|
|
|
#define ALPHA_I_PIX 1
|
|
|
|
|
|
|
|
|
|
|
|
/* enums */
|
|
|
|
|
|
|
|
/* Layer modes */
|
|
|
|
typedef enum
|
|
|
|
{
|
|
|
|
NORMAL_MODE,
|
|
|
|
DISSOLVE_MODE,
|
|
|
|
BEHIND_MODE,
|
|
|
|
MULTIPLY_MODE,
|
|
|
|
SCREEN_MODE,
|
|
|
|
OVERLAY_MODE,
|
|
|
|
DIFFERENCE_MODE,
|
|
|
|
ADDITION_MODE,
|
|
|
|
SUBTRACT_MODE,
|
|
|
|
DARKEN_ONLY_MODE,
|
|
|
|
LIGHTEN_ONLY_MODE,
|
|
|
|
HUE_MODE,
|
|
|
|
SATURATION_MODE,
|
|
|
|
COLOR_MODE,
|
|
|
|
VALUE_MODE,
|
|
|
|
DIVIDE_MODE,
|
|
|
|
DODGE_MODE,
|
|
|
|
BURN_MODE,
|
|
|
|
HARDLIGHT_MODE,
|
2001-11-25 03:58:46 +08:00
|
|
|
COLOR_ERASE_MODE,
|
2001-05-15 19:25:25 +08:00
|
|
|
ERASE_MODE, /*< skip >*/
|
|
|
|
REPLACE_MODE, /*< skip >*/
|
|
|
|
ANTI_ERASE_MODE /*< skip >*/
|
|
|
|
} LayerModeEffects;
|
|
|
|
|
|
|
|
/* Types of convolutions */
|
|
|
|
typedef enum
|
|
|
|
{
|
|
|
|
NORMAL_CONVOL, /* Negative numbers truncated */
|
|
|
|
ABSOLUTE_CONVOL, /* Absolute value */
|
|
|
|
NEGATIVE_CONVOL /* add 127 to values */
|
|
|
|
} ConvolutionType;
|
|
|
|
|
|
|
|
typedef enum
|
|
|
|
{
|
|
|
|
LINEAR_INTERPOLATION,
|
|
|
|
CUBIC_INTERPOLATION,
|
|
|
|
NEAREST_NEIGHBOR_INTERPOLATION
|
|
|
|
} InterpolationType;
|
|
|
|
|
2001-05-23 07:05:35 +08:00
|
|
|
typedef enum
|
|
|
|
{
|
|
|
|
VALUE_LUT,
|
|
|
|
RED_LUT,
|
|
|
|
GREEN_LUT,
|
|
|
|
BLUE_LUT,
|
|
|
|
ALPHA_LUT,
|
|
|
|
GRAY_LUT = 0 /*< skip >*/
|
|
|
|
} ChannelLutType;
|
|
|
|
|
2001-05-15 19:25:25 +08:00
|
|
|
/* Transparency representation */
|
|
|
|
typedef enum /*< skip >*/
|
|
|
|
{
|
|
|
|
LIGHT_CHECKS = 0,
|
|
|
|
GRAY_CHECKS = 1,
|
|
|
|
DARK_CHECKS = 2,
|
|
|
|
WHITE_ONLY = 3,
|
|
|
|
GRAY_ONLY = 4,
|
|
|
|
BLACK_ONLY = 5
|
|
|
|
} GimpCheckType;
|
|
|
|
|
|
|
|
typedef enum /*< skip >*/
|
|
|
|
{
|
|
|
|
SMALL_CHECKS = 0,
|
|
|
|
MEDIUM_CHECKS = 1,
|
|
|
|
LARGE_CHECKS = 2
|
|
|
|
} GimpCheckSize;
|
|
|
|
|
2001-05-23 07:05:35 +08:00
|
|
|
typedef enum /*< skip >*/
|
|
|
|
{
|
|
|
|
GIMP_HISTOGRAM_VALUE = 0,
|
|
|
|
GIMP_HISTOGRAM_RED = 1,
|
|
|
|
GIMP_HISTOGRAM_GREEN = 2,
|
|
|
|
GIMP_HISTOGRAM_BLUE = 3,
|
|
|
|
GIMP_HISTOGRAM_ALPHA = 4
|
|
|
|
} GimpHistogramChannel;
|
|
|
|
|
2001-05-15 19:25:25 +08:00
|
|
|
|
|
|
|
/* types */
|
|
|
|
|
|
|
|
typedef struct _BoundSeg BoundSeg;
|
|
|
|
|
2001-05-23 07:05:35 +08:00
|
|
|
typedef struct _GimpHistogram GimpHistogram;
|
2001-05-15 19:25:25 +08:00
|
|
|
typedef struct _GimpLut GimpLut;
|
|
|
|
|
|
|
|
typedef struct _PixelRegionIterator PixelRegionIterator;
|
|
|
|
typedef struct _PixelRegion PixelRegion;
|
|
|
|
typedef struct _PixelRegionHolder PixelRegionHolder;
|
|
|
|
|
|
|
|
typedef struct _TempBuf TempBuf;
|
|
|
|
typedef struct _TempBuf MaskBuf;
|
|
|
|
|
|
|
|
typedef struct _Tile Tile;
|
|
|
|
typedef struct _TileManager TileManager;
|
|
|
|
|
2001-11-29 09:06:44 +08:00
|
|
|
typedef struct _PixelDataHandle PixelDataHandle;
|
2001-05-15 19:25:25 +08:00
|
|
|
|
|
|
|
/* functions */
|
|
|
|
|
|
|
|
typedef void (* TileValidateProc) (TileManager *tm,
|
|
|
|
Tile *tile);
|
|
|
|
|
|
|
|
|
|
|
|
#endif /* __BASE_TYPES_H__ */
|