Mesh Parameter, a mysterious Data Type?

Hi all,

I have always used the ‘Mesh Parameter’ output from the MeshClosestPoint (MeshCP) to immediately input it into ‘MeshEval’ (MEval).

The format of a Mesh Parameter is F[A;B;C;D], where F is a FaceIndex and A to D are coordinate values for Triangle and Quad faces.

I tried to change these values inbetween using MeshCP and MeshEval and I’ve run into this weird error, that the Mesh Eval component cannot handle Text input, even though the data seems unchanged. So I cannot change the Mesh Parameters by changing the Face index or one of the 4 coordinate values. I also cannot generate Mesh Parameters by simply formatting text into “F[A;B;C;D]” and make points appear on the mesh. This same approach would work for Surface UV points, or normal 3D XYZ points and XYZ vectors.

In fact, Grasshopper tells me Mesh Parameter is ALREADY a String, but if I put it through a Text Parameter component, MeshEval can no longer us it, even though it is still the same String type according to Grasshopper!

MeshParameterFromText.gh (12.6 KB)

There also seems to be no way to cast Text into a MeshPoint or MeshParameter, as far as I know. So right now, I can only use Mesh Parameters if I perfectly preserve them in a Generic Data Parameter component.

Does anybody know if there is a way to actually change or generate a MeshParameter or MeshPoint?

It looks like the ‘Mesh Parameter’ type in GH1 was never fully exposed with a constructor, so you’ll need scripting here.
Mesh.PointAt does have the option to input either a MeshPoint or a faceIndex and 4 parameters.

https://developer.rhino3d.com/api/rhinocommon/rhino.geometry.mesh/pointat

Thanks, I will try this.

The reason I need this solved is because for a mirrored mesh, the Mesh Parameters were no longer accurate. I did find out that FlipMesh does fix this issue. So FlipMesh after Mirror, that solved my specific use case.