You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When working through this tutorial process, I can import the sphere, pull some verts, and save those changes to the session layer. This initial process works fine. When I try to do this a second time, where I import the mesh, move different verts, then save those changes to the session layer, the second edit is lost. The code never hits the Mesh::writeEdits logic the second time around.
I tracked it down to TranslatorContext::unloadPrim, (line 532), there is a test to ensure preTearDown is only called once.
// call pretearDown if it hasn't been called before
if(!translator->isTearingDown()) {...call preTearDown...}
This "isTearingDown" test prevents the edits from being saved the second time the mesh is edited and saved back to the session layer. I changed this in a local build to remove the if statement, and then the mesh edits save each time I import, edit, and save to the session layer. I don't know if that is a valid fix for this though. meshTranslationEdits.py.txt
The text was updated successfully, but these errors were encountered:
A fix will be out for the next release. I removed the bool entirly. which means the preTearDown can get called more than once in some cases, such as a variant switch that removes a Mesh. But no ill-effects happen because of this from what I have seen.
https://github.com/AnimalLogic/AL_USDMaya/tree/master/tutorials/meshTranslation
When working through this tutorial process, I can import the sphere, pull some verts, and save those changes to the session layer. This initial process works fine. When I try to do this a second time, where I import the mesh, move different verts, then save those changes to the session layer, the second edit is lost. The code never hits the Mesh::writeEdits logic the second time around.
I tracked it down to TranslatorContext::unloadPrim, (line 532), there is a test to ensure preTearDown is only called once.
// call pretearDown if it hasn't been called before
if(!translator->isTearingDown()) {...call preTearDown...}
This "isTearingDown" test prevents the edits from being saved the second time the mesh is edited and saved back to the session layer. I changed this in a local build to remove the if statement, and then the mesh edits save each time I import, edit, and save to the session layer. I don't know if that is a valid fix for this though.
meshTranslationEdits.py.txt
The text was updated successfully, but these errors were encountered: