8000 Feature fileselection by skinkie · Pull Request #867 · alicevision/Meshroom · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Feature fileselection #867

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

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

skinkie
Copy link
@skinkie skinkie commented Apr 25, 2020

Description

https://github.com/alicevision/meshroom/wiki/Good-first-contributions point that Add file picker to add images would be a good start for development. This would Fix #461 and Fix #825

Features list

Implementation remarks

I would like to put down in this pull request has been my first contribution, and first QML work, which I found challenging. The first commit updates the Python interface, which splits the drag and drop slot to a drag and drop, and a more generic list of URLs.

The second commit adds the ability to be able to click on both the icon as the drop label. I choose this approach to prevent issues when clicking on any image later, this allowing the most obvious place a user would be able to click first. I added the new signal in because the different object type QObject vs QList. I used FileDialog from QtQuick.Dialogs to allow a multifile selection. I wonder if the other Platform.FileDialog's should be updated in the future.

The third commit adds two menu entries, in order to add images dragless. As programmer I would have liked to reuse the same FileDialog, I don't know if this would be an anti-pattern in QML. I found it very hard to just reuse the FileDialog from one of the files. I would love to hear if it this is possible at all.

skinkie added 3 commits April 25, 2020 17:03
When clicking on Drop Images Files / Folders (or the icon above) the user has now the option to do a multiselection of files to be added for reconstruction.
@natowi
Copy link
Member
natowi commented Apr 25, 2020

Thank you for the contribution. (I attached a screenshot for other users to illustrate your commits)

screen

I noted one thing that is not directly related to your commit:

When using the new HDRI pipeline there is no SfM node, so "Augment Reconstruction" is without use. Maybe we could disable the Augment Reconstruction drop field/File Menu as long as there is no SfM node in the node graph to improve usability. @fabiencastan what do you think?

@skinkie
Copy link
Author
skinkie commented Apr 25, 2020

Thank you for the contribution. (I attached a screenshot for other users to illustrate your commits)

You missed to highlight the extra menu separator ;)

I noted one thing that is not directly related to your commit:

When using the new HDRI pipeline there is no SfM node, so "Augment Reconstruction" is without use. Maybe we could disable the Augment Reconstruction drop field/File Menu as long as there is no SfM node in the node graph to improve usability. @fabiencastan what do you think?

When I start the application I get a full Photogrammetry pipeline. The augment menu entry is explicitly disabled, it is not common to hide menu entries in applications. What I did find out is that the augment droparea is enabled when there is a single image (images > 0), while it should actually be at least two (images >= 2).

@natowi
Copy link
Member
natowi commented Apr 25, 2020

You missed to highlight the extra menu separator

Yes, the black lines on dark grey background are hard to see

hide menu entries in applications.

No, not hide, disable when using File->New pipeline->HDRI or when no SfM node is being used in the graph

What I did find out is that the augment droparea is enabled when there is a single image (images > 0), while it should actually be at least two (images >= 2).

Yes, that could be fixed, too.

8000
@skinkie
Copy link
Author
skinkie commented Apr 25, 2020

hide menu entries in applications.

No, not hide, disable when using File->New pipeline->HDRI or when no SfM node is being used in the graph

I see what you mean now, but it should also disable the drop area :-) Maybe open a new ticket? This sounds like a "good first issue" as well.

@natowi
Copy link
Member
natowi commented Apr 25, 2020

I have added this to the Good-first-contributions list for now.

@skinkie
Copy link
Author
skinkie commented Apr 25, 2020

@natowi it was easier than expected. What do you think about it? :-)

@natowi
Copy link
Member
natowi commented Apr 25, 2020

@skinkie It works :-)

@natowi natowi added feature new feature (proposed as PR or issue planned by dev) type:enhancement type:pr pull request issue UI labels Apr 25, 2020
@natowi
Copy link
Member
natowi commented Apr 25, 2020

About file types:
It is good to enable the image formats with best support by default, but it would be better to have the ability to add #.* and the other https://github.com/alicevision/meshroom/wiki/Supported-image-formats. I also remembered that Meshroom supports .mp4 video files, so it would be good to add this to the file type menu.

I noted, that adding folders via the add images menu is not possible.

@skinkie
Copy link
Author
skinkie commented Apr 25, 2020

I took the image fileformat list from the Python code. https://github.com/alicevision/meshroom/blob/develop/meshroom/multiview.py#L9

I have tried MP4 before, but it does not yet work.

And you would be surprised that adding folders via dragging only works if the folder actually contains images, it does not work recursive. In addition QML does not allow both a multiple file selection and a folder selection. https://doc.qt.io/qt-5/qml-qtquick-dialogs-filedialog.html#selectFolder-prop

@natowi
Copy link
Member
natowi commented Apr 25, 2020

I have tried MP4 before, but it does not yet work.

When you drag and drop a mp4 file in Meshroom a new "KeyframeSelection" node is being created.
(At the moment you need to manually add the output folder as input once you have processed the node, but that is another issue https://github.com/alicevision/meshroom/wiki/Good-first-contributions#better-handling-of-video-files-keyframeselection)

In addition QML does not allow both a multiple file selection and a folder selection

I see...

@skinkie
Copy link
Author
skinkie commented Apr 25, 2020

What if we create a new menu "Assets" with:

  • Add Images...
  • Add Image Folder...
  • Add Images (augment)...
  • Add Image Folder (augment)...

Surely I want this to work recursively as well. But I think a good UI design should be made.

@natowi
Copy link
Member
natowi commented Apr 25, 2020

But I think a good UI design should be made

I agree. Maybe we can take a look on how this is solved in other applications. But now it is enough for today I think :)

@ChemicalXandco
Copy link
Contributor
ChemicalXandco commented Apr 25, 2020

I believe this feature was already added in this commit on #808

(Though I don't think it allows for augmentation currently)

@skinkie
Copy link
Author
skinkie commented Apr 25, 2020

I believe this feature was already added in this commit on #808

(Though I don't think it allows for augmentation currently)

Would have been nice if that commit or pull request actually marked the issues.

@natowi
Copy link
Member
natowi commented Apr 26, 2020

@ChemicalXandco thank you for the hint, I did not see this, too.
@skinkie Your PR is more advanced. f9477ea only adds a simple add Images menu entry

How about this menu structure?

Import Files (or Import...)
-- Images
-- Folders (Images)
-- *Videos (extract image sequence from mp4 #232 (comment), can be added later)

Augment Reconstruction (could directly open the add images window as long as adding folders for augmentation is not supported)
-- Images
-- *Folders (Images) (does not work at the moment in the drop area)
-- *(Videos)

@stale
Copy link
stale bot commented Jun 18, 2023

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale for issues that becomes stale (no solution) label Jun 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature new feature (proposed as PR or issue planned by dev) stale for issues that becomes stale (no solution) type:enhancement type:pr pull request issue UI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Image selection, without drag and drop [Improvement] Add file picker to add images
3 participants
0