[gimp/goat-invasion: 302/325] app: remove gimp_image_get_color()
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/goat-invasion: 302/325] app: remove gimp_image_get_color()
- Date: Fri, 30 Mar 2012 09:59:38 +0000 (UTC)
commit a801cc116ef6632a4091b071d71a742e65423073
Author: Michael Natterer <mitch gimp org>
Date: Thu Mar 29 01:54:00 2012 +0200
app: remove gimp_image_get_color()
app/core/gimpimage.c | 54 --------------------------------------------------
app/core/gimpimage.h | 5 ----
2 files changed, 0 insertions(+), 59 deletions(-)
---
diff --git a/app/core/gimpimage.c b/app/core/gimpimage.c
index 40ad834..c90ee3c 100644
--- a/app/core/gimpimage.c
+++ b/app/core/gimpimage.c
@@ -2625,60 +2625,6 @@ gimp_image_inc_instance_count (GimpImage *image)
/* color transforms / utilities */
void
-gimp_image_get_color (const GimpImage *src_image,
- GimpImageType src_type,
- const guchar *src,
- guchar *rgba)
-{
- gboolean has_alpha = FALSE;
-
- g_return_if_fail (GIMP_IS_IMAGE (src_image));
-
- switch (src_type)
- {
- case GIMP_RGBA_IMAGE:
- has_alpha = TRUE;
-
- case GIMP_RGB_IMAGE:
- /* Straight copy */
- *rgba++ = *src++;
- *rgba++ = *src++;
- *rgba++ = *src++;
- break;
-
- case GIMP_GRAYA_IMAGE:
- has_alpha = TRUE;
-
- case GIMP_GRAY_IMAGE:
- /* Gray to RG&B */
- *rgba++ = *src;
- *rgba++ = *src;
- *rgba++ = *src++;
- break;
-
- case GIMP_INDEXEDA_IMAGE:
- has_alpha = TRUE;
-
- case GIMP_INDEXED_IMAGE:
- /* Indexed palette lookup */
- {
- GimpImagePrivate *src_private = GIMP_IMAGE_GET_PRIVATE (src_image);
- gint index = *src++ * 3;
-
- *rgba++ = src_private->colormap[index++];
- *rgba++ = src_private->colormap[index++];
- *rgba++ = src_private->colormap[index++];
- }
- break;
- }
-
- if (has_alpha)
- *rgba = *src;
- else
- *rgba = OPAQUE_OPACITY;
-}
-
-void
gimp_image_get_foreground (const GimpImage *image,
GimpContext *context,
GimpImageType dest_type,
diff --git a/app/core/gimpimage.h b/app/core/gimpimage.h
index fd85324..ceaf775 100644
--- a/app/core/gimpimage.h
+++ b/app/core/gimpimage.h
@@ -332,11 +332,6 @@ void gimp_image_inc_instance_count (GimpImage *image);
/* color transforms / utilities */
-void gimp_image_get_color (const GimpImage *src_image,
- GimpImageType src_type,
- const guchar *src,
- guchar *rgba);
-
void gimp_image_get_foreground (const GimpImage *image,
GimpContext *context,
GimpImageType dest_type,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]