-
-
Notifications
You must be signed in to change notification settings - Fork 66
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 zoom-format #227
base: master
Are you sure you want to change the base?
Add zoom-format #227
Conversation
@@ -116,6 +116,9 @@ pub struct Arguments { | |||
/// retrying partially failed downloads, or stitching the tiles with an external program. | |||
#[arg(short = 'c', long = "tile-cache")] | |||
pub tile_storage_folder: Option<PathBuf>, | |||
/// A zoom_level image format suffix eg.default.png or default.jpg | |||
#[arg(short = 'f', long = "zoom-format", default_value = "auto")] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The type probably shouldn't be String if not all strings are valid. The documentation should explain precisely what this does.
) -> Result<Tile, TileDownloadError> { | ||
if !"auto".eq(&self.zoom_format) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is probably not the right place to handle that. This option is specific to the iiif dezoomer, isn't it? If it is, then it should be handled in the dezoomer.
@@ -116,6 +116,9 @@ pub struct Arguments { | |||
/// retrying partially failed downloads, or stitching the tiles with an external program. | |||
#[arg(short = 'c', long = "tile-cache")] | |||
pub tile_storage_folder: Option<PathBuf>, | |||
/// A zoom_level image format suffix eg.default.png or default.jpg | |||
#[arg(short = 'f', long = "zoom-format", default_value = "auto")] | |||
pub zoom_format: String, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the option is specific to IIIF, then its name should probably reference it.
Maybe something like --iiif-tile-format=jpg
Add zoom-format for #226