Lines Matching defs:value
208 /* this value should not be too large because it defines the step size in which */
360 DBG(DBG_inquiry,"CBHS value range..............: %s\n", cbhs_str[dev->inquiry_cbhs]);
2569 /* for some scanners the data is simply sent back, other scanners want 255-value as awnswer */
2587 DBG(DBG_info,"calculating average value for 8 bit shading data!\n");
2608 DBG(DBG_info,"calculating average value for 16 bit shading data (low byte first)!\n");
2629 DBG(DBG_info,"calculating average value for 16 bit shading data (high byte first)!\n");
2664 unsigned int value;
2670 value = shading_data[2*j] + shading_data[2*j+1] * 256;
2671 value = 65535 - value;
2672 shading_data[2*j] = (unsigned char) value/256;
2673 shading_data[2*j+1] = (unsigned char) value & 255;
3270 static void umax_calculate_exposure_time(Umax_Device *dev, int def, int *value)
3275 if ( (*value))
3277 if ( (*value) == -1 ) { (*value) = def; }
3280 level = (*value) / dev->inquiry_exposure_time_step_unit;
3281 (*value) = inrange(dev->use_exposure_time_min, level, dev->inquiry_exposure_time_max);
3575 /* always set calibration lines because we also need this value if the scanner
3963 dev->inquiry_contrast_min = 103; /* minimum value for c */
3964 dev->inquiry_contrast_max = 153; /* maximum value for c */
3965 dev->inquiry_brightness_min = 78; /* minimum value for b */
3966 dev->inquiry_brightness_max = 178; /* maximum value for b */
3967 dev->inquiry_threshold_min = 78; /* minimum value for t */
3968 dev->inquiry_threshold_max = 178; /* maximum value for t */
3969 dev->inquiry_highlight_min = 1; /* minimum value for h */
3970 dev->inquiry_highlight_max = 50; /* maximum value for h */
3971 dev->inquiry_shadow_min = 0; /* minimum value for s */
3972 dev->inquiry_shadow_max = 49; /* maximum value for s */
4172 static int umax_calculate_analog_gamma(double value)
4176 if (value < 1.0)
4177 { value=1.0; }
4179 if (value > 2.0)
4180 { value=2.0; }
4183 while (value>analog_gamma_table[gamma])
4190 if ((analog_gamma_table[gamma-1] + analog_gamma_table[gamma]) /2 > value)
4387 dev->max_value = 255; /* maximum value */
4570 dev->inquiry_contrast_min = 1; /* minimum value for c */
4571 dev->inquiry_contrast_max = 255; /* maximum value for c */
4572 dev->inquiry_brightness_min = 1; /* minimum value for b */
4573 dev->inquiry_brightness_max = 255; /* maximum value for b */
4574 dev->inquiry_threshold_min = 1; /* minimum value for t */
4575 dev->inquiry_threshold_max = 255; /* maximum value for t */
4576 dev->inquiry_highlight_min = 1; /* minimum value for h */
4577 dev->inquiry_highlight_max = 255; /* maximum value for h */
4578 dev->inquiry_shadow_min = 0; /* minimum value for s */
4579 dev->inquiry_shadow_max = 254; /* maximum value for s */
5868 scanner->val[OPT_BATCH_NEXT_TL_Y].w = 0xFFFF; /* mark value as not touched */
5937 int value;
5944 value = strtol(value_str, &end_ptr, 10);
5947 DBG(DBG_error, "ERROR: invalid value \"%s\" for option %s in %s\n", value_str, test_name, UMAX_CONFIG_FILE);
5951 if (value < test_min)
5953 DBG(DBG_error, "ERROR: value \"%d\" is too small for option %s in %s\n", value, test_name, UMAX_CONFIG_FILE);
5954 value = test_min;
5956 else if (value > test_max)
5958 DBG(DBG_error, "ERROR: value \"%d\" is too large for option %s in %s\n", value, test_name, UMAX_CONFIG_FILE);
5959 value = test_max;
5962 *test_value = value;
6590 DBG(DBG_error, "could not set option, invalid value\n");
7628 if (scanner->device->upper_left_x < 0) /* rounding errors may create a negative value */
7837 unsigned int i, dest, color, value;
7852 value = scanner->gamma_table[color][i];
7855 gamma[dest++] = scanner->gamma_table[0][value] / 256;
7857 gamma[dest++] = (scanner->gamma_table[0][value] & 255);
7873 unsigned int i, dest, color, value;
7888 value = scanner->gamma_table[color][i];
7892 gamma[dest++] = scanner->gamma_table[0][value] / 256;
7894 gamma[dest++] = (scanner->gamma_table[0][value] & 255);