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

[ui] Remove intrinsic if not used by any viewpoint #2395

Merged
merged 5 commits into from
May 23, 2024

Conversation

Just-Kiel
Copy link
Contributor

Description

When deleting image from the ImageGallery, if it is the last one using a specific intrinsic, it now removes the intrinsic.

@Just-Kiel Just-Kiel added the UI label Apr 29, 2024
@Just-Kiel Just-Kiel added this to the Meshroom 2024.1.0 milestone Apr 29, 2024
@Just-Kiel Just-Kiel self-assigned this Apr 29, 2024
@@ -292,6 +292,24 @@ Panel {

function sendRemoveRequest() {
if (!readOnly) {
// look if the viewpoint's intrinsic is used by another viewpoint
Copy link
Member

Choose a reason for hiding this comment

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

Should be done after the removeImageRequest, isn't it?

Copy link
Member

Choose a reason for hiding this comment

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

Maybe better to do it on the python side.
Instead of a generic call to reconstruction.removeAttribute(attribute), here:
https://github.com/alicevision/Meshroom/blob/7b691a05dd73c1aa1ee913aa11af84ba81d227b5/meshroom/ui/qml/WorkspaceView.qml#L81C17-L81C80

Add a removeImage and do all the checks in it (including the job done in allViewpointsCleared / removeAllImages).
https://github.com/alicevision/Meshroom/blob/7b691a05dd73c1aa1ee913aa11af84ba81d227b5/meshroom/ui/graph.py#L820C9-L820C24

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I created a removeImage to do checks of intrinsics, is it better ?

meshroom/ui/graph.py Outdated Show resolved Hide resolved
@Just-Kiel Just-Kiel force-pushed the dev/updateIntrinsicsWhileRemovingImages branch from 0e06232 to c50d3cc Compare May 13, 2024 07:48
@fabiencastan fabiencastan merged commit 958f2ed into develop May 23, 2024
4 checks passed
@fabiencastan fabiencastan deleted the dev/updateIntrinsicsWhileRemovingImages branch May 23, 2024 12:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants