[ui] Don't load a node's output in the 3DViewer if it has no 3D output #2230
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Prior to this PR and following #2208, any file whose extension is
.json
,.sfm
or.abc
could be loaded in the 3D viewer. Double-clicking on a node that had an output with one of these extensions, even if it was not a 3D output, led to the node being loaded in the 3D viewer.For example, double-clicking the
CameraInit
node, which has.sfm
outputs but no 3D output, resulted in it being added to the list of entries of the Inspector3D.This PR ensures that no node will be loaded in the 3D viewer upon being double-clicked unless it has a 3D output, which is indicated by an icon next to the node's name in the Graph Editor. Only
.abc
outputs are considered to be valid 3D outputs.Any
.json
,.sfm
and.abc
can still be dropped in the 3D viewer, and theSfmDataLoader
will load it if it is valid.This relates to alicevision/QtAliceVision#49.