Hey, i'm trying to write a custom .env file using xml that could be able to store more information than the .env file
so far everything works, I managed to save the skin into an xml and load it back
However i'm not really happy with the loading part pipeline. In order to get the weights loaded correctly I have to:
(pipeline for a single vertex)
Get all the bone ID currently used
Turn off normalize
Sets all weights to zero on all the bone id previously gathered
load the weight data from the xml
turn on normalize
if I only load the weight data using setweights or replaceWeights i get skinning error ( the weights doesn't get applied correctly)
is there a way to force the skin modifiers to take new weights without having to flush everything out of every vertex ?
Replies
https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=2&cad=rja&ved=0CDwQFjAB&url=http%3A%2F%2Fdocs.autodesk.com%2F3DSMAX%2F15%2FENU%2FMAXScript-Help%2Ffiles%2FGUID-0820AA26-920F-434D-A6BC-E8B6B57F54AC.htm&ei=pYXgUZuOLonxygHtvYG4Ag&usg=AFQjCNEDSPMAVuqsig3eSjazYxF5xw5_7w&sig2=XCMD-qjXatahTOzCck6K8g
Is there an script crash? Can you post a code snippet?
I already tried skinops.ReplaceVertexWeights on a specific vertex and didnt work, I had to set the current influence to zero and mess with normalize.
What I tried to do I assigned some legs verts to the head bone to max influence ( was using a character for testing) but with setVertexWeights or replaceVertexWeight I would still get something like 0.5 influence on the head
There's no crash, no error I get an OK but the weight isnt right
At first I thought it was an error from the xml, but doing it manually from the data saved from the xml gave me the right results.
I'm using max2013
strange, I guess I was either too tired or I fucked up somewhere anyhow it's working perfectly many thanks
btw I simply want to confirm what I saw about an other issue. THere's no real vertex with the 0 ID in the skinning array which means that the number we get from the weight table aren't exact you have to do the weightTable given vertex ID + 1 to compensate for ID#0
Thanks autodesk for making things so intuitive.