diff options
author | Laszlo Agocs <laszlo.agocs@qt.io> | 2018-08-01 12:15:42 +0200 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2018-08-02 09:48:49 +0000 |
commit | 48149c7af40dc1e87d2caaa91526269a752a9107 (patch) | |
tree | 1032577006feff959209242a4c8ac849478f4c38 /tests | |
parent | 2040e207f56ac9246240938a43c6f5c2b6d912c4 (diff) |
Make effects dynamically spawnable, destroyable, and changeable
Also makes it possible to use filenames in effects', custom materials' and
behaviors' "class" property. Previously this could only contain an id
referring to an entry in the Classes section of the uip document. With
programatically constructed scenes the pre-loaded list of
effect/material/behavior descriptions is not used. Instead the instances
refer directly to filenames (the loaded data is cached like with meshes).
Custom materials and behaviors do not yet support changing their "class"
at runtime, although they get many of the enablers.
Change-Id: I560ab00b9dc447bd19d5ebeb749972873b89ec2c
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/uipparser/tst_q3dsuipparser.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/uipparser/tst_q3dsuipparser.cpp b/tests/auto/uipparser/tst_q3dsuipparser.cpp index 3f9ec36..8f67b97 100644 --- a/tests/auto/uipparser/tst_q3dsuipparser.cpp +++ b/tests/auto/uipparser/tst_q3dsuipparser.cpp @@ -1309,12 +1309,12 @@ void tst_Q3DSUipParser::customPropertyTextureSourceResolve() auto eff = pres->object<Q3DSEffectInstance>(QByteArrayLiteral("FullScreenTextureOverlay_001")); QVERIFY(eff); - QCOMPARE(eff->propertyNames().count(), 10); // 8 standard, 2 dynamic + QCOMPARE(eff->propertyNames().count(), 9); // 7 standard, 2 dynamic QCOMPARE(eff->dynamicPropertyNames().count(), 2); QCOMPARE(eff->dynamicPropertyValues().count(), 2); QSet<QString> expectedNames { QLatin1String("id"), QLatin1String("name"), QLatin1String("starttime"), QLatin1String("endtime"), - QLatin1String("dynamicProperties"), QLatin1String("class"), QLatin1String("eyeball"), QLatin1String("effect"), + QLatin1String("dynamicProperties"), QLatin1String("class"), QLatin1String("eyeball"), QLatin1String("Overlay"), QLatin1String("overlay_repeat") }; QSet<QString> actualNames; for (const QString &s : eff->propertyNames()) |