Amerio.Stephane Posted February 27, 2023 Posted February 27, 2023 Hi, In 2.16.1, I need to adjust an existing skeletal animation. I add a control node (dummy) on the bone with the "Create Dummy Hierarchy" button in the Bones panel of the skinned mesh, and then I can move/rotoate the dummy to adjust the animation. This works find... unless the mesh is part of a reference ".node" file. When saving the node, the control dummy reference is los, as you can see when the world is reopened: Worse, if I reassign the node, then the editor crashes when the world is saved.
ipakseev Posted February 28, 2023 Posted February 28, 2023 Hello, Stephane. Thanks for the bug report, I've successfully reproduced crash in the latest release. However, disappearing links inside the NodeReference is expected behavior: https://developer.unigine.com/en/docs/latest/objects/nodes/reference/?rlang=cpp#outside I've created a bug report (crash in the Editor) in our internal tracker. We will try to fix it before the release of the 2.17 SDK.
Amerio.Stephane Posted February 28, 2023 Author Posted February 28, 2023 4 hours ago, ipakseev said: However, disappearing links inside the NodeReference is expected behavior Sorry, I wasn't clear enough. The Dummy controlling the bone is also INSIDE the node reference, so it should be allowed. Can you confirm you also reproduce this? On is this only an incorrect manipulation on my side?
ipakseev Posted March 1, 2023 Posted March 1, 2023 Sorry, I really misunderstood you. Yes, I reproduced this. It's also a bug. I've created a bug report about this behavior. Can you please elaborate on what you want to achieve? If this is the functionality you need, we will try to find a workaround depending on your goals.
Amerio.Stephane Posted March 2, 2023 Author Posted March 2, 2023 On 3/1/2023 at 9:29 AM, ipakseev said: Can you please elaborate on what you want to achieve? We have some skinned mesh which base animation needs to be adjusted in regard of other objects. In this specific case, we have an animated mixamo human, seated and slightly moving its head and hands, and we needed to reposition its hands and legs so they wouldn't interfer with other elements and be more integrated with their surrounding (eg having the hand hovering over the correct section of a keyboard or pointing toward the correct direction). It's easier to adjust the animation inside the editor than it would be to modify and rexport through Blender. Moreover, we can then adjust the animation with the Tracker tool or control it through other means in real time. As the human is inside a CIGI entity, it has to be inside a node. I guess the future animation and Tracker rehaul will help in the regard.
cash-metall Posted March 6, 2023 Posted March 6, 2023 It is due to the fact that the reference to the binded node inside the meshskinned does not update for dynamic identifiers (inside the noreference e.g.) as a result, it stores the id of the original node that was created the first time. to avoid this problem, you can add a small component that will restore the id. For properties and components this problem is solved. class BindNodes: public Unigine::ComponentBase { public: COMPONENT_DEFINE(BindNodes, Unigine::ComponentBase); COMPONENT_INIT(init); struct BindedNode: public Unigine::ComponentStruct { PROP_PARAM(Int, index); PROP_PARAM(Node, binded_node); }; PROP_ARRAY_STRUCT(BindedNode, binded_nodes); private: void init() { auto object = checked_ptr_cast<ObjectMeshSkinned>(node); if (!object) return; for (int i = 0; i < binded_nodes.size(); i++) { auto &s = binded_nodes[i]; object->setBindNode(s->index, s->binded_node); } } }; you need to add this component to the meshskinned and manually duplicate link for all binded nodes. 1
Recommended Posts