Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add scanning presets #7

Open
dvkch opened this issue Apr 7, 2023 · 0 comments
Open

Add scanning presets #7

dvkch opened this issue Apr 7, 2023 · 0 comments
Assignees

Comments

@dvkch
Copy link
Owner

dvkch commented Apr 7, 2023

We could define per device presets, shared across iCloud devices.

The main issue with this task is that it would require to find the simplest way to represent selected device options, keeping in mind that some options may not be available up until another one is set to the proper value, or that adjusting an option's value could reset the value of another one.

A "best effort" way to do that would be to :

  • save a simple hash of Option # -> Option Value
  • restore by setting each option whose value isn't the saved one to the saved value. if by the end of the loop the snapshots don't match, we redo a pass or two. a maximum number of passes could be set to prevent infinitely looping if we cannot recreate the proper settings.

A more precise version of it could be :

  • save the list of setting changes that happened, as an array of (Option #, Option Value). optionally this list might be trimable under certain circumstances to prevent it from being extremely long
  • restore by reapplying one by one the settings

Notes :

  • it could also have the added benefit that we could close a device while not specifically using it for scanning or previewing, using an unnamed preset. we need to figure out the cost of always saving and restoring options in between scans though
  • some options could be ignored, for instance the crop settings
@dvkch dvkch self-assigned this Apr 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant