Hello fellow TA’s,
I am having a bit of an issue with Maya at the moment and was wondering if anyone had come across this before. What I am doing is writing a script in PyMel that gathers the vertex point positions of 3 separate objects and storing them in a multi list.
The next step is to combine the objects, once this is done I iterate through the new object’s vertex point positions to check which are the same as the values in my list:
for point in myNode.getPoints("world"):
vertCount += 1
vertPositions[count].append(point)
for point in myNode.getPoints("world"):
vertCount += 1
if (pm.dt.Vector(point) == pm.dt.Vector(verts[1][2])):
print "found"
Now onto my issue. When I print out the values of the first list of point positions compared to the 2nd set of point positions the values are slightly different, it’s as if the verts have shifted slightly. Here is an example:
The first set of point positions (separate objects):
[-141.332735864, -34.1640412074, 0.0]
[200.334744605, -34.1640412074, 0.0]
The second set of point positions (now combined using polyunite):
[-141.332733154, -34.1640396118, 0.0]
[200.334747314, -34.1640396118, 0.0]
As you can see, the values are very similar except for the last 6 decimal places. Is this just an unavoidable computing error or something wrong with Maya?
Cheers!