mirror of
https://github.com/alicevision/Meshroom.git
synced 2025-08-06 10:18:42 +02:00
[ui] bug fix in features viewer
This commit is contained in:
parent
2bf1a5f809
commit
5b9d37c836
2 changed files with 8 additions and 76 deletions
|
@ -266,11 +266,11 @@ FloatingPane {
|
||||||
Label {
|
Label {
|
||||||
property string descType: featureType.viewer.describerType
|
property string descType: featureType.viewer.describerType
|
||||||
property int viewId: root.featuresViewer.currentViewId
|
property int viewId: root.featuresViewer.currentViewId
|
||||||
text: descType + ": " + ((root.mfeatures.status === MFeatures.Ready) ? root.mfeatures.nbFeatures(descType, viewId) : " - ") + " / " + ((root.mtracks.status === MTracks.Ready) ? root.mtracks.nbMatches(descType, viewId) : " - ") + " / " + ((root.msfmdata.status === MSfMData.Ready) ? root.msfmdata.nbLandmarks(descType, viewId) : " - ")
|
text: descType + ": " + ((root.mfeatures && root.mfeatures.status === MFeatures.Ready) ? root.mfeatures.nbFeatures(descType, viewId) : " - ") + " / " + ((root.mtracks && root.mtracks.status === MTracks.Ready) ? root.mtracks.nbMatches(descType, viewId) : " - ") + " / " + ((root.msfmdata && root.msfmdata.status === MSfMData.Ready) ? root.msfmdata.nbLandmarks(descType, viewId) : " - ")
|
||||||
}
|
}
|
||||||
// Feature loading status
|
// Feature loading status
|
||||||
Loader {
|
Loader {
|
||||||
active: (root.mfeatures.status === MFeatures.Loading)
|
active: (root.mfeatures && root.mfeatures.status === MFeatures.Loading)
|
||||||
sourceComponent: BusyIndicator {
|
sourceComponent: BusyIndicator {
|
||||||
padding: 0
|
padding: 0
|
||||||
implicitWidth: 12
|
implicitWidth: 12
|
||||||
|
|
|
@ -524,7 +524,7 @@ FocusScope {
|
||||||
ExifOrientedViewer {
|
ExifOrientedViewer {
|
||||||
id: featuresViewerLoader
|
id: featuresViewerLoader
|
||||||
active: displayFeatures.checked
|
active: displayFeatures.checked
|
||||||
property var activeNode: _reconstruction ? _reconstruction.activeNodes.get("FeatureExtraction").node : null
|
property var activeNode: _reconstruction ? _reconstruction.activeNodes.get("featureProvider").node : null
|
||||||
width: imgContainer.width
|
width: imgContainer.width
|
||||||
height: imgContainer.height
|
height: imgContainer.height
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
|
@ -706,17 +706,7 @@ FocusScope {
|
||||||
return _reconstruction ? _reconstruction.activeNodes.get("featureProvider").node : null;
|
return _reconstruction ? _reconstruction.activeNodes.get("featureProvider").node : null;
|
||||||
}
|
}
|
||||||
property bool isComputed: activeNode && activeNode.isComputed
|
property bool isComputed: activeNode && activeNode.isComputed
|
||||||
active: false
|
active: isUsed && isComputed
|
||||||
|
|
||||||
onIsUsedChanged: {
|
|
||||||
active = (!active && isUsed && isComputed);
|
|
||||||
}
|
|
||||||
onIsComputedChanged: {
|
|
||||||
active = (!active && isUsed && isComputed);
|
|
||||||
}
|
|
||||||
onActiveNodeChanged: {
|
|
||||||
active = (!active && isUsed && isComputed);
|
|
||||||
}
|
|
||||||
|
|
||||||
onActiveChanged: {
|
onActiveChanged: {
|
||||||
if(active) {
|
if(active) {
|
||||||
|
@ -731,7 +721,7 @@ FocusScope {
|
||||||
if (activeNode) {
|
if (activeNode) {
|
||||||
if (activeNode.nodeType == "FeatureExtraction" && isComputed) {
|
if (activeNode.nodeType == "FeatureExtraction" && isComputed) {
|
||||||
result.push(activeNode.attribute("output").value);
|
result.push(activeNode.attribute("output").value);
|
||||||
} else {
|
} else if (activeNode.hasAttribute("featuresFolders")) {
|
||||||
for (let i = 0; i < activeNode.attribute("featuresFolders").value.count; i++) {
|
for (let i = 0; i < activeNode.attribute("featuresFolders").value.count; i++) {
|
||||||
let attr = activeNode.attribute("featuresFolders").value.at(i);
|
let attr = activeNode.attribute("featuresFolders").value.at(i);
|
||||||
result.push(attr.value);
|
result.push(attr.value);
|
||||||
|
@ -791,39 +781,7 @@ FocusScope {
|
||||||
return Filepath.stringToUrl(sfmValue);
|
return Filepath.stringToUrl(sfmValue);
|
||||||
}
|
}
|
||||||
|
|
||||||
active: false
|
active: isUsed && isComputed
|
||||||
// It takes time to load tracks, so keep them looaded, if we may use it again.
|
|
||||||
// If we load another node, we can trash them (to eventually load the new node data).
|
|
||||||
onIsUsedChanged: {
|
|
||||||
if(!active && isUsed && isComputed)
|
|
||||||
{
|
|
||||||
active = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
onIsComputedChanged: {
|
|
||||||
if(!isComputed)
|
|
||||||
{
|
|
||||||
active = false;
|
|
||||||
}
|
|
||||||
else if(!active && isUsed)
|
|
||||||
{
|
|
||||||
active = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
onActiveNodeChanged: {
|
|
||||||
if(!isUsed)
|
|
||||||
{
|
|
||||||
active = false;
|
|
||||||
}
|
|
||||||
else if(!isComputed)
|
|
||||||
{
|
|
||||||
active = false;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
active = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
onActiveChanged: {
|
onActiveChanged: {
|
||||||
if(active) {
|
if(active) {
|
||||||
|
@ -850,33 +808,7 @@ FocusScope {
|
||||||
}
|
}
|
||||||
property bool isComputed: activeNode && activeNode.isComputed
|
property bool isComputed: activeNode && activeNode.isComputed
|
||||||
|
|
||||||
active: false
|
active: isUsed && isComputed
|
||||||
// It takes time to load tracks, so keep them loaded, if we may use it again.
|
|
||||||
// If we load another node, we can trash them (to eventually load the new node data).
|
|
||||||
onIsUsedChanged: {
|
|
||||||
if(!active && isUsed && isComputed) {
|
|
||||||
active = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
onIsComputedChanged: {
|
|
||||||
if(!isComputed) {
|
|
||||||
active = false;
|
|
||||||
}
|
|
||||||
else if(!active && isUsed) {
|
|
||||||
active = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
onActiveNodeChanged: {
|
|
||||||
if(!isUsed) {
|
|
||||||
active = false;
|
|
||||||
}
|
|
||||||
else if(!isComputed) {
|
|
||||||
active = false;
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
active = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
onActiveChanged: {
|
onActiveChanged: {
|
||||||
if(active) {
|
if(active) {
|
||||||
|
@ -888,7 +820,7 @@ FocusScope {
|
||||||
if (activeNode) {
|
if (activeNode) {
|
||||||
if (activeNode.nodeType == "FeatureMatching" && isComputed) {
|
if (activeNode.nodeType == "FeatureMatching" && isComputed) {
|
||||||
result.push(activeNode.attribute("output").value);
|
result.push(activeNode.attribute("output").value);
|
||||||
} else {
|
} else if (activeNode.hasAttribute("matchesFolders")) {
|
||||||
for (let i = 0; i < activeNode.attribute("matchesFolders").value.count; i++) {
|
for (let i = 0; i < activeNode.attribute("matchesFolders").value.count; i++) {
|
||||||
let attr = activeNode.attribute("matchesFolders").value.at(i);
|
let attr = activeNode.attribute("matchesFolders").value.at(i);
|
||||||
result.push(attr.value);
|
result.push(attr.value);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue