How do you save Vertices Coordinates in a list?

Is there a script or does any one know how to export/save a list of all the coordinated of every vertex in Blender.

a few easy steps


import bpy

for item in bpy.data.objects:
    
    print(item.name)
    if item.type == 'MESH':
        for vertex in item.data.vertices:
            print(vertex.co)

couldn’t resist :slight_smile: this makes sure to check if the object is a mesh, before checking it’s vertex data

Thank you for helping. :slight_smile:

Are you sure that’s accurate? Maybe I’m splitting hairs here but shouldn’t the vert count be based on bpy.data.meshes? Should the verts in a mesh associated with 2 Blender objects be counted twice?

Sorry if the questions confuse the issue but this thread got my curious.

There are plenty of ways to approach this, and if this doesn’t solve it for Patrick then my hopes are that he will be interested enough to learn more python/blender to solve things for himself. This snippet of code is how I understood his question.

Alright there patrick?