[sane-devel] patch for include/sane/saneopts.h

gerard klaver gklaver@wanadoo.nl
Thu, 08 Jan 2004 20:14:21 -0100

Content-Type: text/plain
Content-Transfer-Encoding: 7bit


For the teco2 backend i use at the moment the white_level option for
manual changing the calibration value downloaded to the scanner.

To improve the calibration part i made a patch to add the white_value_r,
white_value_g and white_value_b to the saneopts.h file.

With this when for example the red calibration is not correct the user
can change this by changing the value of the white_level_r used as a
advanced option.

See the attached file for the patch.

Before adding the patch to the saneopts.h file in cvs i like to know
if there are any comments about it.

Gerard Klaver

Content-Disposition: attachment; filename=saneopts-08122004.diff
Content-Type: text/x-patch; name=saneopts-08122004.diff; charset=ISO-8859-15
Content-Transfer-Encoding: 7bit

--- saneopts.orig.h	2003-10-05 10:00:10.000000000 -0100
+++ saneopts.h	2004-01-06 20:25:24.000000000 -0100
@@ -89,6 +89,9 @@
 #define SANE_NAME_HALFTONE		"halftoning"
 #define SANE_NAME_BLACK_LEVEL           "black-level"
 #define SANE_NAME_WHITE_LEVEL           "white-level"
+#define SANE_NAME_WHITE_LEVEL_R         "white-level-r"
+#define SANE_NAME_WHITE_LEVEL_G         "white-level-g"
+#define SANE_NAME_WHITE_LEVEL_B         "white-level-b"
 #define SANE_NAME_SHADOW		"shadow"
 #define SANE_NAME_SHADOW_R		"shadow-r"
 #define SANE_NAME_SHADOW_G		"shadow-g"
@@ -153,6 +156,9 @@
 #define SANE_TITLE_HALFTONE		SANE_I18N("Halftoning")
 #define SANE_TITLE_BLACK_LEVEL          SANE_I18N("Black level")
 #define SANE_TITLE_WHITE_LEVEL          SANE_I18N("White level")
+#define SANE_TITLE_WHITE_LEVEL_R        SANE_I18N("White level for red")
+#define SANE_TITLE_WHITE_LEVEL_G        SANE_I18N("White level for green")
+#define SANE_TITLE_WHITE_LEVEL_B        SANE_I18N("White level for blue")
 #define SANE_TITLE_SHADOW		SANE_I18N("Shadow")
 #define SANE_TITLE_SHADOW_R		SANE_I18N("Shadow for red")
 #define SANE_TITLE_SHADOW_G		SANE_I18N("Shadow for green")
@@ -281,6 +287,15 @@
 SANE_I18N("Selects what radiance level should be considered \"white\".")
+SANE_I18N("Selects what red radiance level should be considered \"white\".")
+SANE_I18N("Selects what green radiance level should be considered \"white\".")
+SANE_I18N("Selects what blue radiance level should be considered \"white\".")
 SANE_I18N("Selects what radiance level should be considered \"black\".")