Does godot have such a feature, I haven't found an answer in a long time by google. My scenario is that I make some rotation of the MeshInstance Node and want to change the center of the mesh. The scenario I came up with was to regenerate mesh at runtime by applying these transformations.

I can determine the new center point and mesh rotation, but I don’t know how to regenerate the mesh at runtime

Thanks for any reply

Simplest solution might be to apply an offset to the vertices in a vertex shader.

You might be able to use the MeshDataTool for this, if you are wanting to directly modify the mesh itself.

Though, it may be simpler to use a vertex shader like Megalomaniak suggested. You could also potentially have the MeshInstance node as a child of a Spatial node, and then use the Spatial node as the "origin" of the mesh, and apply any rotation and offsets you want to the translation and rotation of the child MeshInstance node.

2 years later