This is my first post to the forum so might sound a bit not so professional in regards programming terms and concepts.
I’m developing a system for managing real tree branches and one of the components has to split a mesh in parts. It creates a bounding box of the branch, a dozen of surfaces along a line and then after converting the surfaces to meshes I use the Mesh.Split() command. The thing is I made this component multi-threaded and when using tasks as by the official example on the Mcneel site the results are always different and less accurate than the single threaded solution. The code I use is the same for both. Anyone has and idea as to why this is happening? Also it is not very clear what is happening when all threads finish? When is the final data assigned to the output parameters? It seems as if the next components do not get all data and recomputing the solutions sometimes fixes the problem. Is there something code wise I should be doing? Expiring does not work.
Tasked run #1:
Tasked run #2:
Single thread - shows normal behaviour: