I'm trying to export the XYZ values from Raycast Geometry Nodes to a txt or csv. The output socket Hit Position, I know is a vector, but I can't access the coordinates of every hit position. How do I go about this issue?

Raycast GeoNode

This is the closest I get to achieve the data I need:

  • $\begingroup$ Does this answer your question? Accessing Geometry Nodes mesh data from Python In your particular case: set position to the Hit Position, then in Python read the positions of vertices of the evaluated data. $\endgroup$ Aug 28, 2023 at 16:23
  • $\begingroup$ is the issue that you are only getting one value instead of a vector or is it that you are only getting one vector, when you want one for each point? $\endgroup$
    – shmuel
    Aug 28, 2023 at 17:15
  • $\begingroup$ @MarkusvonBroady helped a lot, but i need every vertice position, with this one all i have is the number of vertices, not the position: from bpy import context as C dg = C.evaluated_depsgraph_get() ev = C.object.evaluated_get(dg) print("Evaluated Verts:", len(C.object.evaluated_get(dg).data.vertices)) that's what i've tried, can i get the positions of every vertice? thanks for the help $\endgroup$
    – leocfranz
    Aug 28, 2023 at 19:26
  • $\begingroup$ @shmuel i want one for each point, is that possible? $\endgroup$
    – leocfranz
    Aug 28, 2023 at 19:28
  • 1
    $\begingroup$ @MarkusvonBroady Thank you so much, it worked, you saved my day!! $\endgroup$
    – leocfranz
    Aug 28, 2023 at 19:39


Browse other questions tagged .