I work on a script that reduces the vertex number of a Mesh meeting certain criteria.
To get it work, I need my own subclasses for Mesh,
bpy.types.MeshVertex to store some custom data. 'Mesh' is ok, but if I do something like:
class CustomVertex(bpy.types.MeshVertex): def __init__(self, inMesh, inVertex): pass
I get an error message:
TypeError: bpy_struct.__new__(type): expected a single argument
Blender, for some reason, doesn't like changing
__init__()'s number of arguments, and also cannot be tricked with packaging multiple variables into a tuple or a list.
But, if I cannot pass in the mesh owning
MeshVertex without passing it as a variable is there any function like
bpy.types.MeshEdge.owner() or anything similar to refer to the Mesh in which the
MeshEdge or the
MeshVertex is in?