Amerio.Stephane Posted December 3, 2021 Posted December 3, 2021 Hello, Would it be possible to display the Scale and World Scale of a node in the Syncker Debug Window? Currently there is Position+Rotation in local and World coord. I'm missing the Scale, because I've apparently a bug where it looks like node::setWorldScale is not being applied to a node. Thanks!
silent Posted December 3, 2021 Posted December 3, 2021 Hi Stephane, Scale might be reset to 1 if you are using physics on this node. Can you reproduce the same behavior on the same content without Syncker? How to submit a good bug report --- FTP server for test scenes and user uploads: ftp://files.unigine.com user: upload password: 6xYkd6vLYWjpW6SN
Amerio.Stephane Posted December 3, 2021 Author Posted December 3, 2021 Hi Silent. There is no physics on the node. It's stored as a NodeReference on disk and loaded with World::loadNode (2.13.1.1). The node hierarchy is just a NodeDummy with a child ObjectMeshStatic. I call setScale or setWorldScale on the root node (ie the dummy). A console dump shows that the scale should be applied indeed but the size of the object in the world doesn't change (master only, I don't even look at the slave right now). This is strange. Here is the code used: if (_parallax = World::loadNode("Crosshair.node")) { syncker->addSyncNode(_parallax); _parallax->setLifetime(Node::LIFETIME_ENGINE); _parallax->setEnabled(true); } ... _parallax->setParent(parent); if (ObjectPtr o = World::getIntersection(src, dst, 0x80000000U, wi)) { _parallax->setWorldPosition(wi->getPoint()); _parallax->setWorldDirection(wi->getNormal(), vec3::UP, Math::AXIS_NY); Console::onscreenMessageLine(">%f", _parallax_scale); //< this value is '2' _parallax->setScale(vec3(_parallax_scale)); Console::onscreenMessageLine("=%f", _parallax->getScale().x); //< this prints '2' so everything should be ok } //< but visually, nothing changes, whatever I put in '_parallax_scale'
Amerio.Stephane Posted December 9, 2021 Author Posted December 9, 2021 Hello, any idea why I have this peculiar effect (size change not visible). This is in an, IG so I can't test without the Syncker, but as I said the issue is visible on the master too.
silent Posted December 9, 2021 Posted December 9, 2021 Hi Stephane, Thanks for waiting. Scale is not supported in Syncker in 2.13.x branch when interpolation is enabled. Scale support with interpolation was added in 2.14.x. How to submit a good bug report --- FTP server for test scenes and user uploads: ftp://files.unigine.com user: upload password: 6xYkd6vLYWjpW6SN
Amerio.Stephane Posted December 9, 2021 Author Posted December 9, 2021 Ok, thanks, I'll try on 2.14-15 then
Recommended Posts