I need to set the colors of vertices from data generated by third-party simulation. To do this, I need to access the vertices by their unique indices with the Python API.
I can do this with bpy.data.objects.data.vertices, but there doesn't seem to be a color attribute there that I can set. I can access (and maybe set) vertex colors with bpy.data.objects.data.vertex_indices.color, but it seems that vertex_indices gives me the loop indices (which are not unique, as neighboring edge loops will generally share at least one vertex).
Can someone clarify how to do this (access vertices by unique index and set color)?
Many thanks in advance!