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 a simplified saving API for common use cases #135

Open
tlnagy opened this issue Nov 28, 2023 · 0 comments
Open

Add a simplified saving API for common use cases #135

tlnagy opened this issue Nov 28, 2023 · 0 comments
Labels
enhancement New feature or request help wanted Extra attention is needed
Milestone

Comments

@tlnagy
Copy link
Owner

tlnagy commented Nov 28, 2023

Currently, the saving API is extremely limited. Users can add tags to the IFDs to save a description or change the compression, etc. This is clunky and hard to use. It would be better to expose keywords for common properties such that you do the following:

img = rand(Gray{N0f8}, 10, 10)
TiffImages.save("img.tif", img; description = "test image", compression = :lzw)

Naturally, if the user is supplying a subtype of AbstractTIFF we would need a way to merge the provided tag values with the tags already present in the IFD of the image.

Some properties that I can imagine being useful to set this way are:

  • bigtiff
  • description
  • compression
  • orientation
  • X/Y resolution

Basically the API used in the ImageJ demo: https://tamasnagy.com/TiffImages.jl/dev/demos/common/imagej/#Writing-ImageJ-compatible-metadata should be easier to use/discover. We should still allow for the nitty gritty fine grained control of that example, but have a simpler option for folks too.

Thoughts @chrstphrbrns with regards to compression?

@tlnagy tlnagy added enhancement New feature or request help wanted Extra attention is needed labels Nov 28, 2023
@tlnagy tlnagy added this to the v1.0 milestone Apr 3, 2024
@tlnagy tlnagy mentioned this issue Apr 3, 2024
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant