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

Changes to permit group persistence #17795

Conversation

wpferguson
Copy link
Member

@wpferguson wpferguson commented Nov 8, 2024

Partial fix for #16827. Actually, according to the title it's a complete fix, but the meaning is to have a way to maintain image grouping across database instances.

In order to make the grouping information survive between database instances I use darktable| tags. This has the advantage of not cluttering up the tagging UI with lots of grouping tags while allowing the information to be stored. darktable| tags aren't included in the XMP files, but should be IMHO since they contain state information about the image. So, I added the darktable| tags to the XMP.

I added a gen_uuid() function to darktable.util, in the Lua API, to generate a UUID string for each group.

I added a image-group-information-changed Lua event that fires whenever a grouping change is made so the I could create/update the group tags for the image.

The final piece to fix #16827 is a lua-script that monitors grouping changes and tags them, then rebuilds the groups on import.

@wpferguson
Copy link
Member Author

wpferguson commented Nov 8, 2024

@TurboGit it seems I've introduced a new dependency on libuuid. How do I handle that?

EDIT: As a cmake dependency?

@ralfbrown ralfbrown added the scope: DAM managing files, collections, archiving, metadata, etc. label Nov 9, 2024
             build environment (UCRT64) doesn't have a libuuid package.
             I can implement the UUID function in Lua to satisfy the
             requirement.
@wpferguson
Copy link
Member Author

Removed the external dependency on libuuid as no package is available for the windows build environment.

I can implement a UUID function in Lua.

@wpferguson
Copy link
Member Author

wpferguson commented Nov 13, 2024

After conversation with the MSYS2 people, libuuid.a is at /ucrt64/lib/libuuid.a and the header file is at /ucrt64/include/libavutil/uuid.h.

I'll still stick with the decision to implement UUID in Lua. Much less moving parts this close to feature freeze.

EDIT: The /ucrt64/include/libavutil/uuid.h header file is not the equivalent of uuids/uuid.h, so at present there isn't a way to use UUID on windows other than using the WIN32 API and windows API calls.

Copy link
Member

@TurboGit TurboGit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@TurboGit
Copy link
Member

Manually merged by removing superfluous commits (code added and then removed).

@TurboGit TurboGit closed this Nov 14, 2024
@wpferguson wpferguson deleted the changes_to_permit_group_persistence branch November 17, 2024 01:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lua scope: DAM managing files, collections, archiving, metadata, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Store image groupings in sidecar file (XMP)
3 participants