summaryrefslogtreecommitdiffstats
path: root/src/bodymovin/bmfreeformshape.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/bodymovin/bmfreeformshape.cpp')
-rw-r--r--src/bodymovin/bmfreeformshape.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/bodymovin/bmfreeformshape.cpp b/src/bodymovin/bmfreeformshape.cpp
index a714314..b4ef5f8 100644
--- a/src/bodymovin/bmfreeformshape.cpp
+++ b/src/bodymovin/bmfreeformshape.cpp
@@ -45,10 +45,11 @@ BMFreeFormShape::BMFreeFormShape(const BMFreeFormShape &other)
m_vertexMap = other.m_vertexMap;
}
-BMFreeFormShape::BMFreeFormShape(const QJsonObject &definition, BMBase *parent)
+BMFreeFormShape::BMFreeFormShape(const QJsonObject &definition, const QVersionNumber &version,
+ BMBase *parent)
{
setParent(parent);
- construct(definition);
+ construct(definition, version);
}
BMBase *BMFreeFormShape::clone() const
@@ -56,9 +57,10 @@ BMBase *BMFreeFormShape::clone() const
return new BMFreeFormShape(*this);
}
-void BMFreeFormShape::construct(const QJsonObject &definition)
+void BMFreeFormShape::construct(const QJsonObject &definition, const QVersionNumber &version)
{
BMBase::parse(definition);
+ m_version = version;
if (m_hidden)
return;
@@ -315,9 +317,9 @@ void BMFreeFormShape::finalizeVertices()
coObj.insert(QLatin1String("k"), m_vertexInfos.value(i)->coKeyframes);
VertexInfo vertexInfo;
- vertexInfo.pos.construct(posObj);
- vertexInfo.ci.construct(ciObj);
- vertexInfo.co.construct(coObj);
+ vertexInfo.pos.construct(posObj, m_version);
+ vertexInfo.ci.construct(ciObj, m_version);
+ vertexInfo.co.construct(coObj, m_version);
m_vertexList.push_back(vertexInfo);
}
qDeleteAll(m_vertexInfos);