mirror of
https://github.com/alicevision/Meshroom.git
synced 2025-05-21 04:56:28 +02:00
[core][io] store nodes position in graph file
* increment file minor version (no incompatibility) * nodeFactory: reload file position if available
This commit is contained in:
parent
dfb0934ef4
commit
e2155ba962
2 changed files with 10 additions and 3 deletions
|
@ -162,7 +162,7 @@ class Graph(BaseObject):
|
|||
|
||||
class IO(object):
|
||||
""" Centralize Graph file keys and IO version. """
|
||||
__version__ = "1.0"
|
||||
__version__ = "1.1"
|
||||
|
||||
class Keys(object):
|
||||
""" File Keys. """
|
||||
|
@ -179,6 +179,7 @@ class Graph(BaseObject):
|
|||
Header = "header"
|
||||
NodesVersions = "nodesVersions"
|
||||
PrecomputedOutputs = "precomputedOutputs"
|
||||
NodesPositions = "nodesPositions"
|
||||
|
||||
@staticmethod
|
||||
def getFeaturesForVersion(fileVersion):
|
||||
|
@ -199,6 +200,8 @@ class Graph(BaseObject):
|
|||
Graph.IO.Features.NodesVersions,
|
||||
Graph.IO.Features.PrecomputedOutputs,
|
||||
]
|
||||
if fileVersion >= Version("1.1"):
|
||||
features += [Graph.IO.Features.NodesPositions]
|
||||
return features
|
||||
|
||||
def __init__(self, name, parent=None):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue