From 7b7b3c3f0cfaa30601beebd1339c92ccd5be178e Mon Sep 17 00:00:00 2001 From: Helvetix Victorinox Date: Sun, 12 Oct 2003 00:10:21 +0000 Subject: [PATCH] app/composite/gimp-composite.h app/composite/gimp-composite-generic.h * app/composite/gimp-composite.h * app/composite/gimp-composite-generic.h * app/composite/gimp-composite-regression.h: Reformatted to include argument names in function prototypes. * app/composite/gimp-composite.c * app/composite/gimp-composite-generic.c * app/composite/gimp-composite-regression.c: Added gtk-doc templates for functions. * app/composite/make-install.py: migrated to new (trimmer) code and removed dead code. Some beautification for generated code. * app/composite/gimp-composite-{mmx,sse,sse2,3dnow,altivec,vis,generic}.{c,h}: All init() functions are also a run-time check and now expected to return TRUE/FALSE if the particular set of compositing functions can be used. * app/composite/gimp-composite.c: No longer has to determine if the particular set of compositing functions can be used. * app/composite/gimp-composite-{mmx,sse,sse2,3dnow,altivec,vis}-{install,test}.c: Regenerated * app/composite/test-composite.c: Deprecated, removed. All tests are automatically generated and the code is in app/composite/gimp-composite-{mmx,sse,sse2,3dnow,altivec,vis}-test.c: * app/composite/Makefile.am: removed unused references to test-composite.c --- ChangeLog | 34 ++- app/composite/gimp-composite-generic.c | 202 +++++++++++++++++- app/composite/gimp-composite-generic.h | 62 +++--- app/composite/gimp-composite-mmx.h | 46 ++-- app/composite/gimp-composite-regression.c | 139 ++++++++++-- app/composite/gimp-composite-regression.h | 62 ++++-- app/composite/gimp-composite-sse.h | 46 ++-- app/composite/gimp-composite-sse2.h | 16 +- app/composite/gimp-composite.c | 55 ++++- app/composite/gimp-composite.h | 28 ++- devel-docs/ChangeLog | 5 + .../libgimpcolor/tmpl/gimpcolorspace.sgml | 2 +- 12 files changed, 552 insertions(+), 145 deletions(-) diff --git a/ChangeLog b/ChangeLog index 10c7a79670..8aee096fca 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,33 @@ +2003-10-11 Helvetix Victorinox + + * app/composite/gimp-composite.h + * app/composite/gimp-composite-generic.h + * app/composite/gimp-composite-regression.h: Reformatted to include + argument names in function prototypes. + + * app/composite/gimp-composite.c + * app/composite/gimp-composite-generic.c + * app/composite/gimp-composite-regression.c: Added gtk-doc templates for functions. + + * app/composite/make-install.py: migrated to new (trimmer) code and + removed dead code. Some beautification for generated code. + + * app/composite/gimp-composite-{mmx,sse,sse2,3dnow,altivec,vis,generic}.{c,h}: + All init() functions are also a run-time check and now expected to + return TRUE/FALSE if the particular set of compositing functions can + be used. + + * app/composite/gimp-composite.c: No longer has to determine if + the particular set of compositing functions can be used. + + * app/composite/gimp-composite-{mmx,sse,sse2,3dnow,altivec,vis}-{install,test}.c: + Regenerated + + * app/composite/test-composite.c: Deprecated, removed. All tests are automatically + generated and the code is in app/composite/gimp-composite-{mmx,sse,sse2,3dnow,altivec,vis}-test.c: + + * app/composite/Makefile.am: removed unused references to test-composite.c + 2003-10-11 Michael Natterer * app/widgets/gimpsessioninfo.[ch]: added utility function @@ -2091,7 +2121,7 @@ target drawable. * app/tools/gimpvectortool.c: Removed status message in - VECTORS_FINISHED mode as requested by Ville Pätsi. + VECTORS_FINISHED mode as requested by Ville Pä´³i. * app/vectors/gimpvectors.c: Determine the stroke parameters from the current context (opacity/color/paint_mode). @@ -2451,7 +2481,7 @@ * app/Makefile.am: special case windows for leading underscores in symbol names. -2003-09-17 Ville PÃtsi +2003-09-17 Ville Pôsi * configure.in: Added AC_SUBST to required version numbers. * gimp.spec.in: Changed the requires to use the version numbers from diff --git a/app/composite/gimp-composite-generic.c b/app/composite/gimp-composite-generic.c index 9635c53392..4800d2aa3c 100644 --- a/app/composite/gimp-composite-generic.c +++ b/app/composite/gimp-composite-generic.c @@ -1,8 +1,7 @@ -/* The GIMP -- an image manipulation program +/* -*- mode: c tab-width: 2; c-basic-indent: 2; indent-tabs-mode: nil -*- + * The GIMP -- an image manipulation program * Copyright (C) 1995 Spencer Kimball and Peter Mattis * - * -*- mode: c tab-width: 2; c-basic-indent: 2; indent-tabs-mode: nil -*- - * * 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 @@ -77,6 +76,12 @@ static gint32 random_table[RANDOM_TABLE_SIZE]; * XXX This implementation will not work for >8 bit colours. * XXX This implementation is totally wrong. */ +/** + * gimp_composite_convert_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_convert_any_any_any_generic (GimpCompositeContext *ctx) { @@ -97,6 +102,15 @@ gimp_composite_convert_any_any_any_generic (GimpCompositeContext *ctx) } } +/** + * gimp_composite_color_any_any_any_generic: + * @dest: + * @color: + * @w: + * @bytes: + * + * + **/ void gimp_composite_color_any_any_any_generic (guchar * dest, const guchar * color, guint w, guint bytes) { @@ -188,6 +202,12 @@ gimp_composite_color_any_any_any_generic (guchar * dest, const guchar * color, g } } +/** + * gimp_composite_blend_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_blend_any_any_any_generic (GimpCompositeContext *ctx) { @@ -234,6 +254,12 @@ gimp_composite_shade_generic (const guchar *src, guchar *dest, const guchar *col } #endif +/** + * gimp_composite_darken_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_darken_any_any_any_generic (GimpCompositeContext * ctx) { @@ -269,6 +295,12 @@ gimp_composite_darken_any_any_any_generic (GimpCompositeContext * ctx) } } +/** + * gimp_composite_lighten_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_lighten_any_any_any_generic (GimpCompositeContext * ctx) { @@ -305,6 +337,12 @@ gimp_composite_lighten_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_hue_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_hue_any_any_any_generic (GimpCompositeContext * ctx) { @@ -352,6 +390,12 @@ gimp_composite_hue_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_saturation_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_saturation_any_any_any_generic (GimpCompositeContext * ctx) { @@ -399,6 +443,12 @@ gimp_composite_saturation_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_value_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_value_any_any_any_generic (GimpCompositeContext * ctx) { @@ -446,6 +496,12 @@ gimp_composite_value_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_color_only_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_color_only_any_any_any_generic (GimpCompositeContext * ctx) { @@ -494,6 +550,12 @@ gimp_composite_color_only_any_any_any_generic (GimpCompositeContext * ctx) } } +/** + * gimp_composite_behind_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_behind_any_any_any_generic (GimpCompositeContext * ctx) { @@ -503,6 +565,12 @@ gimp_composite_behind_any_any_any_generic (GimpCompositeContext * ctx) : NO_COMBINATION; } +/** + * gimp_composite_multiply_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_multiply_any_any_any_generic (GimpCompositeContext * ctx) { @@ -555,6 +623,12 @@ gimp_composite_multiply_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_divide_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_divide_any_any_any_generic (GimpCompositeContext * ctx) { @@ -589,6 +663,12 @@ gimp_composite_divide_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_screen_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_screen_any_any_any_generic (GimpCompositeContext * ctx) { @@ -620,6 +700,12 @@ gimp_composite_screen_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_overlay_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_overlay_any_any_any_generic (GimpCompositeContext * ctx) { @@ -653,6 +739,12 @@ gimp_composite_overlay_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_dodge_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_dodge_any_any_any_generic (GimpCompositeContext * ctx) { @@ -688,6 +780,12 @@ gimp_composite_dodge_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_burn_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_burn_any_any_any_generic (GimpCompositeContext * ctx) { @@ -726,6 +824,12 @@ gimp_composite_burn_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_hardlight_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_hardlight_any_any_any_generic (GimpCompositeContext * ctx) { @@ -768,6 +872,12 @@ gimp_composite_hardlight_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_softlight_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_softlight_any_any_any_generic (GimpCompositeContext * ctx) { @@ -804,6 +914,12 @@ gimp_composite_softlight_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_grain_extract_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_grain_extract_any_any_any_generic (GimpCompositeContext * ctx) { @@ -839,6 +955,12 @@ gimp_composite_grain_extract_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_grain_merge_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_grain_merge_any_any_any_generic (GimpCompositeContext * ctx) { @@ -874,6 +996,12 @@ gimp_composite_grain_merge_any_any_any_generic (GimpCompositeContext * ctx) } } +/** + * gimp_composite_addition_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_addition_any_any_any_generic (GimpCompositeContext * ctx) { @@ -921,6 +1049,12 @@ gimp_composite_addition_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_subtract_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_subtract_any_any_any_generic (GimpCompositeContext * ctx) { @@ -956,6 +1090,12 @@ gimp_composite_subtract_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_difference_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_difference_any_any_any_generic (GimpCompositeContext * ctx) { @@ -991,6 +1131,12 @@ gimp_composite_difference_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_dissolve_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_dissolve_any_any_any_generic (GimpCompositeContext * ctx) { @@ -1064,6 +1210,12 @@ gimp_composite_dissolve_any_any_any_generic (GimpCompositeContext * ctx) ctx->combine = gimp_composite_pixel_alphap[ctx->pixelformat_A] ? COMBINE_INTEN_A_INTEN_A : COMBINE_INTEN_INTEN_A; } +/** + * gimp_composite_replace_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_replace_any_any_any_generic (GimpCompositeContext *ctx) { @@ -1072,6 +1224,12 @@ gimp_composite_replace_any_any_any_generic (GimpCompositeContext *ctx) } +/** + * gimp_composite_swap_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_swap_any_any_any_generic (GimpCompositeContext * ctx) { @@ -1091,6 +1249,12 @@ gimp_composite_swap_any_any_any_generic (GimpCompositeContext * ctx) } } +/** + * gimp_composite_normal_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_normal_any_any_any_generic (GimpCompositeContext * ctx) { @@ -1098,6 +1262,12 @@ gimp_composite_normal_any_any_any_generic (GimpCompositeContext * ctx) } +/** + * gimp_composite_erase_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_erase_any_any_any_generic (GimpCompositeContext *ctx) { @@ -1105,6 +1275,12 @@ gimp_composite_erase_any_any_any_generic (GimpCompositeContext *ctx) ctx->combine = (gimp_composite_pixel_alphap[ctx->pixelformat_A] && gimp_composite_pixel_alphap[ctx->pixelformat_B]) ? ERASE_INTEN : 0; } +/** + * gimp_composite_anti_erase_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_anti_erase_any_any_any_generic (GimpCompositeContext *ctx) { @@ -1112,6 +1288,12 @@ gimp_composite_anti_erase_any_any_any_generic (GimpCompositeContext *ctx) ctx->combine = (gimp_composite_pixel_alphap[ctx->pixelformat_A] && gimp_composite_pixel_alphap[ctx->pixelformat_B]) ? ANTI_ERASE_INTEN : 0; } +/** + * gimp_composite_color_erase_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_color_erase_any_any_any_generic (GimpCompositeContext *ctx) { @@ -1122,6 +1304,12 @@ gimp_composite_color_erase_any_any_any_generic (GimpCompositeContext *ctx) } +/** + * gimp_composite_scale_any_any_any_generic: + * @ctx: + * + * + **/ void gimp_composite_scale_any_any_any_generic (GimpCompositeContext * ctx) { @@ -1142,6 +1330,14 @@ gimp_composite_scale_any_any_any_generic (GimpCompositeContext * ctx) } } +/** + * gimp_composite_generic_init: + * @void: + * + * + * + * Return value: + **/ gboolean gimp_composite_generic_init (void) { diff --git a/app/composite/gimp-composite-generic.h b/app/composite/gimp-composite-generic.h index c035ee03da..14dcef96c5 100644 --- a/app/composite/gimp-composite-generic.h +++ b/app/composite/gimp-composite-generic.h @@ -8,35 +8,35 @@ extern gboolean gimp_composite_generic_init (void); */ extern gboolean gimp_composite_generic_install (void); -void gimp_composite_addition_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_anti_erase_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_blend_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_burn_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_color_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_color_erase_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_color_only_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_convert_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_darken_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_difference_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_dissolve_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_divide_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_dodge_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_erase_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_grain_extract_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_grain_merge_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_hardlight_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_hue_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_lighten_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_multiply_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_normal_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_overlay_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_replace_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_saturation_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_scale_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_screen_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_softlight_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_subtract_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_swap_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_value_any_any_any_generic (GimpCompositeContext *); -void gimp_composite_behind_any_any_any_generic (GimpCompositeContext * ); +void gimp_composite_addition_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_anti_erase_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_blend_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_burn_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_color_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_color_erase_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_color_only_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_convert_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_darken_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_difference_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_dissolve_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_divide_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_dodge_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_erase_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_grain_extract_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_grain_merge_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_hardlight_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_hue_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_lighten_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_multiply_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_normal_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_overlay_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_replace_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_saturation_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_scale_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_screen_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_softlight_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_subtract_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_swap_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_value_any_any_any_generic (GimpCompositeContext *ctx); +void gimp_composite_behind_any_any_any_generic (GimpCompositeContext *ctx); #endif diff --git a/app/composite/gimp-composite-mmx.h b/app/composite/gimp-composite-mmx.h index c6c8f53543..30bab93341 100644 --- a/app/composite/gimp-composite-mmx.h +++ b/app/composite/gimp-composite-mmx.h @@ -14,29 +14,29 @@ extern gboolean gimp_composite_mmx_install (void); /* * */ -extern void gimp_composite_addition_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_burn_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_coloronly_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_darken_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_difference_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_dissolve_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_divide_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_dodge_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_grain_extract_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_grain_merge_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_hardlight_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_hueonly_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_lighten_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_multiply_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_overlay_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_replace_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_saturationonly_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_scale_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_screen_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_softlight_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_subtract_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_swap_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); -extern void gimp_composite_valueonly_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *); +extern void gimp_composite_addition_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_burn_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_coloronly_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_darken_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_difference_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_dissolve_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_divide_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_dodge_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_grain_extract_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_grain_merge_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_hardlight_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_hueonly_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_lighten_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_multiply_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_overlay_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_replace_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_saturationonly_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_scale_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_screen_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_softlight_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_subtract_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_swap_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); +extern void gimp_composite_valueonly_rgba8_rgba8_rgba8_mmx (GimpCompositeContext *ctx); #endif /* __GNUC__ > 3 */ #endif /* USE_MMX */ diff --git a/app/composite/gimp-composite-regression.c b/app/composite/gimp-composite-regression.c index 7f2b566bbb..51b310c908 100644 --- a/app/composite/gimp-composite-regression.c +++ b/app/composite/gimp-composite-regression.c @@ -15,13 +15,25 @@ #include "gimp-composite-util.h" #include "gimp-composite-generic.h" +/** + * gimp_composite_regression_print_rgba8: + * @rgba8: + * + * + **/ void -gimp_composite_regression_print_rgba8 (gimp_rgba8_t *p) +gimp_composite_regression_print_rgba8 (gimp_rgba8_t *rgba8) { - printf ("#%02x%02x%02x,%02X", p->r, p->g, p->b, p->a); + printf ("#%02x%02x%02x,%02X", rgba8->r, rgba8->g, rgba8->b, rgba8->a); fflush (stdout); } +/** + * gimp_composite_regression_print_va8: + * @va8: + * + * + **/ void gimp_composite_regression_print_va8 (gimp_va8_t *va8) { @@ -29,6 +41,16 @@ gimp_composite_regression_print_va8 (gimp_va8_t *va8) fflush (stdout); } +/** + * gimp_composite_regression_compare_contexts: + * @operation: + * @ctx1: + * @ctx2: + * + * + * + * Return value: + **/ int gimp_composite_regression_compare_contexts (char *operation, GimpCompositeContext *ctx1, GimpCompositeContext *ctx2) { @@ -131,8 +153,21 @@ gimp_composite_regression_compare_contexts (char *operation, GimpCompositeContex } +/** + * gimp_composite_regression_comp_rgba8: + * @str: + * @rgba8A: + * @rgba8B: + * @expected: + * @actual: + * @length: + * + * + * + * Return value: + **/ int -gimp_composite_regression_comp_rgba8 (char *str, gimp_rgba8_t *rgba8A, gimp_rgba8_t *rgba8B, gimp_rgba8_t *expected, gimp_rgba8_t *got, u_long length) +gimp_composite_regression_comp_rgba8 (char *str, gimp_rgba8_t *rgba8A, gimp_rgba8_t *rgba8B, gimp_rgba8_t *expected, gimp_rgba8_t *actual, u_long length) { u_long i; int failed; @@ -143,20 +178,20 @@ gimp_composite_regression_comp_rgba8 (char *str, gimp_rgba8_t *rgba8A, gimp_rgba for (i = 0; i < length; i++) { failed = 0; - if (expected[i].r != got[i].r) { failed = 1; } - if (expected[i].g != got[i].g) { failed = 1; } - if (expected[i].b != got[i].b) { failed = 1; } - if (expected[i].a != got[i].a) { failed = 1; } + if (expected[i].r != actual[i].r) { failed = 1; } + if (expected[i].g != actual[i].g) { failed = 1; } + if (expected[i].b != actual[i].b) { failed = 1; } + if (expected[i].a != actual[i].a) { failed = 1; } if (failed) { fail_count++; printf("%s %8lu A=", str, i); gimp_composite_regression_print_rgba8(&rgba8A[i]); if (rgba8B != (gimp_rgba8_t *) 0) { printf(" B="); gimp_composite_regression_print_rgba8(&rgba8B[i]); } - printf(" exp="); + printf(" expected="); gimp_composite_regression_print_rgba8(&expected[i]); - printf(" got="); - gimp_composite_regression_print_rgba8(&got[i]); + printf(" actual="); + gimp_composite_regression_print_rgba8(&actual[i]); printf("\n"); } if (fail_count > 5) @@ -166,8 +201,21 @@ gimp_composite_regression_comp_rgba8 (char *str, gimp_rgba8_t *rgba8A, gimp_rgba return (fail_count); } +/** + * gimp_composite_regression_comp_va8: + * @str: + * @va8A: + * @va8B: + * @expected: + * @actual: + * @length: + * + * + * + * Return value: + **/ int -gimp_composite_regression_comp_va8 (char *str, gimp_va8_t *va8A, gimp_va8_t *va8B, gimp_va8_t *expected, gimp_va8_t *got, u_long length) +gimp_composite_regression_comp_va8 (char *str, gimp_va8_t *va8A, gimp_va8_t *va8B, gimp_va8_t *expected, gimp_va8_t *actual, u_long length) { int i; int failed; @@ -178,17 +226,17 @@ gimp_composite_regression_comp_va8 (char *str, gimp_va8_t *va8A, gimp_va8_t *va8 for (i = 0; i < length; i++) { failed = 0; - if (expected[i].v != got[i].v) { failed = 1; } - if (expected[i].a != got[i].a) { failed = 1; } + if (expected[i].v != actual[i].v) { failed = 1; } + if (expected[i].a != actual[i].a) { failed = 1; } if (failed) { fail_count++; printf("%s %8d A=", str, i); gimp_composite_regression_print_va8(&va8A[i]); if (va8B != (gimp_va8_t *) 0) { printf(" B="); gimp_composite_regression_print_va8(&va8B[i]); } printf(" "); - printf("exp="); + printf("expected="); gimp_composite_regression_print_va8(&expected[i]); - printf(" got="); - gimp_composite_regression_print_va8(&got[i]); + printf(" actual="); + gimp_composite_regression_print_va8(&actual[i]); printf("\n"); } if (fail_count > 5) @@ -198,6 +246,14 @@ gimp_composite_regression_comp_va8 (char *str, gimp_va8_t *va8A, gimp_va8_t *va8 return (fail_count); } +/** + * gimp_composite_regression_dump_rgba8: + * @str: + * @rgba: + * @n_pixels: + * + * + **/ void gimp_composite_regression_dump_rgba8 (char *str, gimp_rgba8_t *rgba, u_long n_pixels) { @@ -216,12 +272,29 @@ gimp_composite_regression_dump_rgba8 (char *str, gimp_rgba8_t *rgba, u_long n_pi #define timer_report(name,t1,t2) printf("%-17s %17.7f %17.7f %17.7f%c\n", name, tv_to_secs(t1), tv_to_secs(t2), tv_to_secs(t1)/tv_to_secs(t2), tv_to_secs(t1)/tv_to_secs(t2) > 1.0 ? ' ' : '*'); +/** + * gimp_composite_regression_timer_report: + * @name: + * @t1: + * @t2: + * + * + **/ void gimp_composite_regression_timer_report (char *name, double t1, double t2) { printf ("%-17s %17.7f %17.7f %17.7f%c\n", name, t1, t2, t1/t2, t1/t2 > 1.0 ? ' ' : '*'); } +/** + * gimp_composite_regression_time_function: + * @iterations: + * @func: + * + * + * + * Return value: + **/ double gimp_composite_regression_time_function (u_long iterations, void (*func)(), GimpCompositeContext *ctx) { @@ -238,6 +311,14 @@ gimp_composite_regression_time_function (u_long iterations, void (*func)(), Gimp return (tv_to_secs(tv_elapsed)); } +/** + * gimp_composite_regression_random_rgba8: + * @n_pixels: + * + * + * + * Return value: + **/ gimp_rgba8_t * gimp_composite_regression_random_rgba8 (u_long n_pixels) { @@ -256,6 +337,14 @@ gimp_composite_regression_random_rgba8 (u_long n_pixels) return (rgba8); } +/** + * gimp_composite_regression_fixed_rgba8: + * @n_pixels: + * + * + * + * Return value: + **/ gimp_rgba8_t * gimp_composite_regression_fixed_rgba8 (u_long n_pixels) { @@ -276,6 +365,24 @@ gimp_composite_regression_fixed_rgba8 (u_long n_pixels) return (rgba8); } +/** + * gimp_composite_context_init: + * @ctx: + * @op: + * @a_format: + * @b_format: + * @d_format: + * @m_format: + * @n_pixels: + * @A: + * @B: + * @M: + * @D: + * + * + * + * Return value: + **/ GimpCompositeContext * gimp_composite_context_init (GimpCompositeContext *ctx, GimpCompositeOperation op, diff --git a/app/composite/gimp-composite-regression.h b/app/composite/gimp-composite-regression.h index af3912d191..62002311b6 100644 --- a/app/composite/gimp-composite-regression.h +++ b/app/composite/gimp-composite-regression.h @@ -5,7 +5,7 @@ */ typedef struct { - guint8 v; + guint8 v; } gimp_v8_t; typedef struct @@ -85,26 +85,44 @@ typedef struct } gimp_rgba32_t; #endif -extern double gimp_composite_regression_time_function (u_long, void (*)(), GimpCompositeContext *); -extern int gimp_composite_regression_comp_rgba8 (char *, gimp_rgba8_t *, gimp_rgba8_t *, gimp_rgba8_t *, gimp_rgba8_t *, u_long); -extern int gimp_composite_regression_comp_va8 (char *, gimp_va8_t *, gimp_va8_t *, gimp_va8_t *, gimp_va8_t *, u_long); -extern int gimp_composite_regression_compare_contexts (char *, GimpCompositeContext *, GimpCompositeContext *); -extern void gimp_composite_regression_dump_rgba8 (char *, gimp_rgba8_t *, u_long); -extern void gimp_composite_regression_print_rgba8 (gimp_rgba8_t *); -extern void gimp_composite_regression_print_va8 (gimp_va8_t *); -extern void gimp_composite_regression_timer_report (char *, double, double); +extern double gimp_composite_regression_time_function (u_long iterations, + void (*func)(), + GimpCompositeContext *ctx); +extern int gimp_composite_regression_comp_rgba8 (char *str, + gimp_rgba8_t *rgba8A, + gimp_rgba8_t *rgba8B, + gimp_rgba8_t *expected, + gimp_rgba8_t *actual, + u_long length); +extern int gimp_composite_regression_comp_va8 (char *str, + gimp_va8_t *va8A, + gimp_va8_t *va8B, + gimp_va8_t *expected, + gimp_va8_t *actual, + u_long length); +extern int gimp_composite_regression_compare_contexts (char *, + GimpCompositeContext *ctx1, + GimpCompositeContext *ctx2); +extern void gimp_composite_regression_dump_rgba8 (char *str, + gimp_rgba8_t *rgba, + u_long n_pixels); +extern void gimp_composite_regression_print_rgba8 (gimp_rgba8_t *rgba8); +extern void gimp_composite_regression_print_va8 (gimp_va8_t *va8); +extern void gimp_composite_regression_timer_report (char *name, + double t1, + double t2); -extern gimp_rgba8_t *gimp_composite_regression_random_rgba8 (u_long); -extern gimp_rgba8_t *gimp_composite_regression_fixed_rgba8 (u_long); -extern GimpCompositeContext *gimp_composite_context_init (GimpCompositeContext *, - GimpCompositeOperation, - GimpPixelFormat, - GimpPixelFormat, - GimpPixelFormat, - GimpPixelFormat, - unsigned long, - unsigned char *, - unsigned char *, - unsigned char *, - unsigned char *); +extern gimp_rgba8_t *gimp_composite_regression_random_rgba8 (u_long n_pixels); +extern gimp_rgba8_t *gimp_composite_regression_fixed_rgba8 (u_long n_pixels); +extern GimpCompositeContext *gimp_composite_context_init (GimpCompositeContext *ctx, + GimpCompositeOperation op, + GimpPixelFormat a_format, + GimpPixelFormat b_format, + GimpPixelFormat d_format, + GimpPixelFormat m_format, + unsigned long n_pixels, + unsigned char *A, + unsigned char *B, + unsigned char *M, + unsigned char *D); #endif diff --git a/app/composite/gimp-composite-sse.h b/app/composite/gimp-composite-sse.h index 732b2c7089..915e35bc46 100644 --- a/app/composite/gimp-composite-sse.h +++ b/app/composite/gimp-composite-sse.h @@ -15,29 +15,29 @@ extern gboolean gimp_composite_sse_install (void); /* * */ -extern void gimp_composite_addition_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_burn_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_coloronly_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_darken_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_difference_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_dissolve_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_divide_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_dodge_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_grain_extract_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_grain_merge_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_hardlight_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_hueonly_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_lighten_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_multiply_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_overlay_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_replace_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_saturationonly_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_screen_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_softlight_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_subtract_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_swap_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_valueonly_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); -extern void gimp_composite_scale_rgba8_rgba8_rgba8_sse (GimpCompositeContext *); +extern void gimp_composite_addition_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_burn_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_coloronly_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_darken_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_difference_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_dissolve_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_divide_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_dodge_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_grain_extract_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_grain_merge_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_hardlight_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_hueonly_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_lighten_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_multiply_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_overlay_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_replace_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_saturationonly_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_screen_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_softlight_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_subtract_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_swap_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_valueonly_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); +extern void gimp_composite_scale_rgba8_rgba8_rgba8_sse (GimpCompositeContext *ctx); #endif /* __GNUC__ > 3 */ #endif /* ARCH_X86 */ diff --git a/app/composite/gimp-composite-sse2.h b/app/composite/gimp-composite-sse2.h index a3ce03a2d1..526e38cd88 100644 --- a/app/composite/gimp-composite-sse2.h +++ b/app/composite/gimp-composite-sse2.h @@ -9,12 +9,12 @@ extern gboolean gimp_composite_sse2_init (void); */ extern gboolean gimp_composite_sse2_install (void); -extern void gimp_composite_addition_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *); -extern void gimp_composite_darken_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *); -extern void gimp_composite_difference_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *); -extern void gimp_composite_grain_extract_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *); -extern void gimp_composite_lighten_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *); -extern void gimp_composite_subtract_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *); -extern void gimp_composite_swap_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *); -extern void gimp_composite_dodge_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *); +extern void gimp_composite_addition_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *ctx); +extern void gimp_composite_darken_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *ctx); +extern void gimp_composite_difference_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *ctx); +extern void gimp_composite_grain_extract_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *ctx); +extern void gimp_composite_lighten_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *ctx); +extern void gimp_composite_subtract_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *ctx); +extern void gimp_composite_swap_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *ctx); +extern void gimp_composite_dodge_rgba8_rgba8_rgba8_sse2 (GimpCompositeContext *ctx); #endif diff --git a/app/composite/gimp-composite.c b/app/composite/gimp-composite.c index f7623d2301..fb73cbc612 100644 --- a/app/composite/gimp-composite.c +++ b/app/composite/gimp-composite.c @@ -181,13 +181,21 @@ struct } gimp_composite_debug; struct GimpCompositeOptions gimp_composite_options = -{ - GIMP_COMPOSITE_OPTION_USE -}; + { + GIMP_COMPOSITE_OPTION_USE + }; gchar * gimp_composite_function_name[GIMP_COMPOSITE_N][GIMP_PIXELFORMAT_N][GIMP_PIXELFORMAT_N][GIMP_PIXELFORMAT_N]; void (*gimp_composite_function[GIMP_COMPOSITE_N][GIMP_PIXELFORMAT_N][GIMP_PIXELFORMAT_N][GIMP_PIXELFORMAT_N])(GimpCompositeContext *); +/** + * gimp_composite_dispatch: + * @ctx: The compositing context + * + * Given a compositing context, perform the compositing function + * dictated by the compositing context operation. There is no return + * value, all results are in the compositing context. + **/ void gimp_composite_dispatch (GimpCompositeContext *ctx) { @@ -219,6 +227,14 @@ gimp_composite_dispatch (GimpCompositeContext *ctx) } } +/** + * gimp_composite_context_print: + * @ctx: The context to print + * + * Print a human readable form of a GimpCompositeContext on stdout. + * + * Return value: void + **/ void gimp_composite_context_print (GimpCompositeContext *ctx) { @@ -232,6 +248,15 @@ gimp_composite_context_print (GimpCompositeContext *ctx) ctx->n_pixels); } +/** + * gimp_composite_mode_astext: + * @op: + * + * Given a GimpCompositeOperatin, return a string representation of the name + * of that operation. + * + * Return value: const gchar * + **/ const gchar * gimp_composite_mode_astext (GimpCompositeOperation op) { @@ -276,10 +301,19 @@ gimp_composite_mode_astext (GimpCompositeOperation op) return ("bad mode"); } +/** + * gimp_composite_pixelformat_astext: + * @format: The format. + * + * Given a GimpPixelFormat, return a string representation of the name + * of that format. + * + * Return value: const gchar * + **/ const gchar * -gimp_composite_pixelformat_astext (GimpPixelFormat f) +gimp_composite_pixelformat_astext (GimpPixelFormat format) { - switch (f) { + switch (format) { case GIMP_PIXELFORMAT_V8: return ("V8"); case GIMP_PIXELFORMAT_VA8: return ("VA8"); case GIMP_PIXELFORMAT_RGB8: return ("RGB8"); @@ -305,6 +339,17 @@ gimp_composite_pixelformat_astext (GimpPixelFormat f) } +/** + * gimp_composite_init: + * @void: + * + * Initialise the Gimp Compositing subsystem. This includes checking + * for user options and environment, installing the generic set of + * compositing operation handlers, followed by overloading those which + * are supported by the current cpu/hardware. + * + * Return value: void + **/ void gimp_composite_init (void) { diff --git a/app/composite/gimp-composite.h b/app/composite/gimp-composite.h index f957bb3ac2..2ab57c87b8 100644 --- a/app/composite/gimp-composite.h +++ b/app/composite/gimp-composite.h @@ -1,4 +1,4 @@ -/* -*- mode: c; tab-width: 2; c-basic-indent: 2; indent-tabs-mode: nil -*- +/* -*- mode: c; c-default-style: "gnu"; tab-width: 2; c-basic-indent: 2; indent-tabs-mode: nil -*- * The GIMP -- an image manipulation program * Copyright (C) 1995 Spencer Kimball and Peter Mattis * @@ -29,21 +29,27 @@ typedef enum GIMP_PIXELFORMAT_VA8, GIMP_PIXELFORMAT_RGB8, GIMP_PIXELFORMAT_RGBA8, -#if GIMP_COMPOSITE_16BIT + GIMP_PIXELFORMAT_ANY, + GIMP_PIXELFORMAT_N +} GimpPixelFormat; + +/* + * gtk-doc is unhappy with these #ifdef's inside the enumeration. + * +#ifdef GIMP_COMPOSITE_16BIT GIMP_PIXELFORMAT_V16, GIMP_PIXELFORMAT_VA16, GIMP_PIXELFORMAT_RGB16, GIMP_PIXELFORMAT_RGBA16, #endif -#if GIMP_COMPOSITE_32BIT +#ifdef GIMP_COMPOSITE_32BIT GIMP_PIXELFORMAT_V32, GIMP_PIXELFORMAT_VA32, GIMP_PIXELFORMAT_RGB32, GIMP_PIXELFORMAT_RGBA32, #endif - GIMP_PIXELFORMAT_ANY, - GIMP_PIXELFORMAT_N -} GimpPixelFormat; + * + */ /* bytes per-pixel for each of the pixel formats */ extern const guchar gimp_composite_pixel_bpp[]; @@ -149,12 +155,12 @@ struct GimpCompositeOptions { extern struct GimpCompositeOptions gimp_composite_options; -void gimp_composite_init (void); -void gimp_composite_dispatch (GimpCompositeContext *); +extern void gimp_composite_init (void); +extern void gimp_composite_dispatch (GimpCompositeContext *ctx); -void gimp_composite_context_print (GimpCompositeContext *); -const gchar * gimp_composite_mode_astext (GimpCompositeOperation); -const gchar * gimp_composite_pixelformat_astext (GimpPixelFormat); +extern void gimp_composite_context_print (GimpCompositeContext *ctx); +extern const gchar * gimp_composite_mode_astext (GimpCompositeOperation op); +extern const gchar * gimp_composite_pixelformat_astext (GimpPixelFormat format); extern gchar *gimp_composite_function_name[GIMP_COMPOSITE_N][GIMP_PIXELFORMAT_N][GIMP_PIXELFORMAT_N][GIMP_PIXELFORMAT_N]; extern void (*gimp_composite_function[GIMP_COMPOSITE_N][GIMP_PIXELFORMAT_N][GIMP_PIXELFORMAT_N][GIMP_PIXELFORMAT_N])(GimpCompositeContext *); diff --git a/devel-docs/ChangeLog b/devel-docs/ChangeLog index a6420dac72..45f19674ba 100644 --- a/devel-docs/ChangeLog +++ b/devel-docs/ChangeLog @@ -1,3 +1,8 @@ +2003-10-11 Helvetix Victorinox + + * devel-docs/libgimpcolor/tmpl/gimpcolorspace.sgml: Fixed typo + "convert" instead of "concert" + 2003-10-11 Sven Neumann * app/app-docs.sgml diff --git a/devel-docs/libgimpcolor/tmpl/gimpcolorspace.sgml b/devel-docs/libgimpcolor/tmpl/gimpcolorspace.sgml index 6c959693ec..9d93f3d57e 100644 --- a/devel-docs/libgimpcolor/tmpl/gimpcolorspace.sgml +++ b/devel-docs/libgimpcolor/tmpl/gimpcolorspace.sgml @@ -8,7 +8,7 @@ Utility functions which convert colors between different color models. When programming pixel data manipulation functions you will often use algorithms operating on a color model different from the one GIMP -uses. This file provides utility functions to concert colors between +uses. This file provides utility functions to convert colors between different color spaces.