Lines Matching defs:settings

428     unsigned channels = dev->settings.get_channels();
777 session.params.contrast_adjustment = dev.settings.contrast;
778 session.params.brightness_adjustment = dev.settings.brightness;
901 dev.settings.scan_method == ScanMethod::TRANSPARENCY ||
902 dev.settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED) &&
940 session.params.scan_method = dev.settings.scan_method;
943 session.params.contrast_adjustment = dev.settings.contrast;
944 session.params.brightness_adjustment = dev.settings.brightness;
1086 session.params.contrast_adjustment = dev.settings.contrast;
1087 session.params.brightness_adjustment = dev.settings.brightness;
1158 const auto& resolution_settings = dev.model->get_resolution_settings(dev.settings.scan_method);
1162 auto& sensor = sanei_genesys_find_sensor(&dev, dpi, channels, dev.settings.scan_method);
1195 session.params.scan_method = dev.settings.scan_method;
1198 session.params.contrast_adjustment = dev.settings.contrast;
1199 session.params.brightness_adjustment = dev.settings.brightness;
1366 const Genesys_Settings& settings)
1368 if (settings.scan_method == ScanMethod::TRANSPARENCY ||
1369 settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED)
1371 if (dev.model->model_id == ModelId::CANON_4400F && settings.xres >= 4800) {
1374 if (dev.model->model_id == ModelId::CANON_8600F && settings.xres == 4800) {
1435 const auto& dpihw_sensor = sanei_genesys_find_sensor(&dev, dev.settings.xres, channels,
1436 dev.settings.scan_method);
1441 dev.settings.scan_method);
1446 if (should_calibrate_only_active_area(dev, dev.settings)) {
1455 dev.settings.scan_method == ScanMethod::FLATBED)
1468 dev.settings.scan_method);
1477 if (dev.settings.scan_method == ScanMethod::TRANSPARENCY ||
1478 dev.settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED)
1492 session.params.scan_method = dev.settings.scan_method;
1495 : dev.settings.color_filter;
1496 session.params.contrast_adjustment = dev.settings.contrast;
1497 session.params.brightness_adjustment = dev.settings.brightness;
1519 // scan with bottom AFE settings
1741 const auto& dpihw_sensor = sanei_genesys_find_sensor(&dev, dev.settings.xres, channels,
1742 dev.settings.scan_method);
1750 dev.settings.scan_method);
1763 if (dev.settings.xres < sensor.full_resolution) {
1780 dev.settings.scan_method);
1789 if (dev.settings.scan_method == ScanMethod::TRANSPARENCY ||
1790 dev.settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED)
1797 session.params.yres = dev.model->asic_type == AsicType::GL841 ? dev.settings.yres : resolution;
1804 session.params.scan_method = dev.settings.scan_method;
1806 session.params.color_filter = dev.settings.color_filter;
1807 session.params.contrast_adjustment = dev.settings.contrast;
1808 session.params.brightness_adjustment = dev.settings.brightness;
1979 dev.settings.scan_method);
1999 session.params.scan_method = dev.settings.scan_method;
2001 session.params.color_filter = dev.settings.color_filter;
2002 session.params.contrast_adjustment = dev.settings.contrast;
2003 session.params.brightness_adjustment = dev.settings.brightness;
2261 if (is_dark && dev->settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED) {
2382 if (dev->settings.xres <= sensor.full_resolution / 2) {
2444 if (dev->settings.scan_method == ScanMethod::TRANSPARENCY ||
2445 dev->settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED)
2467 if (is_dark && dev.settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED) {
2824 res = dev->settings.xres;
3112 x = dev->settings.xres;
3270 if (dev->settings.xres > sensor.full_resolution) {
3273 factor = sensor.full_resolution / dev->settings.xres;
3283 * will handle these settings instead of having this switch growing up */
3322 if (dev->settings.xres <= sensor.full_resolution / 2) {
3337 if(dev->settings.xres<=sensor.full_resolution/2)
3356 if(dev->settings.xres<=300)
3360 else if(dev->settings.xres<=600)
3502 auto session = dev->cmd_set->calculate_scan_session(dev, sensor, dev->settings);
3539 auto session = dev->cmd_set->calculate_scan_session(dev, sensor, dev->settings);
3582 if (dev->settings.yres <= sensor.full_resolution / 2) {
3643 pixels_per_line = static_cast<std::uint32_t>((dev->model->x_size * dev->settings.xres) /
3646 pixels_per_line = static_cast<std::uint32_t>((dev->model->x_size_calib_mm * dev->settings.xres)
3654 if (dev->settings.scan_method == ScanMethod::TRANSPARENCY ||
3655 dev->settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED)
3810 // restore settings
3811 dev->settings.xres = sensor.full_resolution;
3925 debug_dump(DBG_info, dev.settings);
3927 auto session = dev.cmd_set->calculate_scan_session(&dev, sensor, dev.settings);
3941 if (dev.settings.get_channels() * dev.settings.yres >= 600 && session.params.starty > 700) {
3972 (dev->settings.scan_method != ScanMethod::TRANSPARENCY_INFRARED))
3974 if (dev->settings.scan_method == ScanMethod::TRANSPARENCY ||
3975 dev->settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED)
3991 if (dev->settings.scan_method == ScanMethod::TRANSPARENCY ||
3992 dev->settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED)
4002 auto& sensor = sanei_genesys_find_sensor_for_write(dev, dev->settings.xres,
4003 dev->settings.get_channels(),
4004 dev->settings.scan_method);
4033 if (dev->settings.scan_method == ScanMethod::TRANSPARENCY ||
4034 dev->settings.scan_method == ScanMethod::TRANSPARENCY_INFRARED)
4218 Genesys_Settings settings;
4219 settings.scan_method = s->scan_method;
4220 settings.scan_mode = option_string_to_scan_color_mode(s->mode);
4222 settings.depth = s->bit_depth;
4224 if (settings.depth > 8) {
4225 settings.depth = 16;
4226 } else if (settings.depth < 8) {
4227 settings.depth = 1;
4230 const auto& resolutions = dev->model->get_resolution_settings(settings.scan_method);
4232 settings.xres = pick_resolution(resolutions.resolutions_x, s->resolution, "X");
4233 settings.yres = pick_resolution(resolutions.resolutions_y, s->resolution, "Y");
4235 settings.tl_x = fixed_to_float(s->pos_top_left_x);
4236 settings.tl_y = fixed_to_float(s->pos_top_left_y);
4240 settings.lines = static_cast<unsigned>(((br_y - settings.tl_y) * settings.yres) /
4244 unsigned pixels_per_line = static_cast<unsigned>(((br_x - settings.tl_x) * settings.xres) /
4247 const auto& sensor = sanei_genesys_find_sensor(dev, settings.xres, settings.get_channels(),
4248 settings.scan_method);
4251 settings.xres, settings.yres, true);
4253 unsigned xres_factor = s->resolution / settings.xres;
4254 settings.pixels = pixels_per_line;
4255 settings.requested_pixels = pixels_per_line * xres_factor;
4258 settings.color_filter = ColorFilter::RED;
4260 settings.color_filter = ColorFilter::GREEN;
4262 settings.color_filter = ColorFilter::BLUE;
4264 settings.color_filter = ColorFilter::NONE;
4269 settings.contrast = (s->contrast * 127) / 100;
4270 settings.brightness = (s->brightness * 127) / 100;
4272 settings.contrast = 0;
4273 settings.brightness = 0;
4276 settings.expiration_time = s->expiration_time;
4278 return settings;
4282 const Genesys_Settings& settings)
4286 auto sensor = sanei_genesys_find_sensor(&dev, settings.xres, settings.get_channels(),
4287 settings.scan_method);
4288 auto session = dev.cmd_set->calculate_scan_session(&dev, sensor, settings);
4292 if (settings.scan_mode == ScanColorMode::GRAY) {
4299 params.depth = settings.depth;
4311 s->dev->settings = calculate_scan_settings(s);
4312 s->params = calculate_scan_parameters(*s->dev, s->dev->settings);
4961 s->opt[OPT_NEED_CALIBRATION_SW].desc = SANE_I18N ("The scanner needs calibration for the current settings");
5635 if (sanei_genesys_has_sensor(dev, dev->settings.xres, dev->settings.get_channels(),
5636 dev->settings.scan_method))
5638 sensor = &sanei_genesys_find_sensor(dev, dev->settings.xres,
5639 dev->settings.get_channels(),
5640 dev->settings.scan_method);
5795 auto session = dev->cmd_set->calculate_scan_session(dev, *sensor, dev->settings);
6059 auto& sensor = sanei_genesys_find_sensor_for_write(dev, dev->settings.xres,
6060 dev->settings.get_channels(),
6061 dev->settings.scan_method);