[gimp-gap] applied fix as suggested at bugreport #723818
- From: Wolfgang Hofer <wolfgangh src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp-gap] applied fix as suggested at bugreport #723818
- Date: Sat, 22 Feb 2014 08:41:54 +0000 (UTC)
commit 6aa14c8d12babeafa0e73310b47710dd9bd382d9
Author: Wolfgang Hofer <wolfgangh svn gnome org>
Date: Sat Feb 22 09:41:33 2014 +0100
applied fix as suggested at bugreport #723818
ChangeLog | 14 ++++++++++++++
gap/gap_fg_matting.c | 2 +-
gap/gap_fg_matting_main.c | 2 +-
3 files changed, 16 insertions(+), 2 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index cd09d37..fa40097 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,17 @@
+2014-02-22 Wolfgang Hofer <hof gimp org>
+
+
+- applied fix for the foreground matting feature as suggested at bug #723818
+ The warning "Problem!: final_confidence: %f\n" now shall be printed only in critical case.
+
+ TODO: Note that GAP still uses a copy of the old foreground matting implementation
+ The already available GEGL implementation will be used in future GAP versions
+ targeted for the use with GIMP 2.10.
+
+ * gap/gap_fg_matting.c
+ * gap/gap_fg_matting_main.c
+
+
2014-01-12 Wolfgang Hofer <hof gimp org>
- support for RAW files as "readonly" frame sequences for processing
as high bit depth video source in MovePath operations or Storyboard Clips.
diff --git a/gap/gap_fg_matting.c b/gap/gap_fg_matting.c
index b0c1c65..db4994b 100644
--- a/gap/gap_fg_matting.c
+++ b/gap/gap_fg_matting.c
@@ -897,7 +897,7 @@ local_smoothing (HashEntry* entry, GHashTable* unknown_hash, GappMattingState *s
¤t_alpha);
final_confidence *= exp(-LAMBDA * sqrt(mp));
- if (!(final_confidence <= 1 || final_confidence >= 0))
+ if (!(final_confidence <= 1 && final_confidence >= 0))
g_printf("Problem!: final_confidence: %f\n", final_confidence);
entry->alpha = (final_confidence * current_alpha + (1 - final_confidence) * low_freq_alpha) * 255;
diff --git a/gap/gap_fg_matting_main.c b/gap/gap_fg_matting_main.c
index 25c38d1..4871cd5 100644
--- a/gap/gap_fg_matting_main.c
+++ b/gap/gap_fg_matting_main.c
@@ -35,7 +35,7 @@
/* Revision history
* (2011/10/05) 2.7.0 hof: created
*/
-int gap_debug = 1; /* 1 == print debug infos , 0 dont print debug infos */
+int gap_debug = 0; /* 1 == print debug infos , 0 dont print debug infos */
#define GAP_DEBUG_DECLARED 1
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]