gradientspace / geometry3Sharp

C# library for 2D/3D geometric computation, mesh algorithms, and so on. Boost license.
http://www.gradientspace.com
Boost Software License 1.0
1.71k stars 384 forks source link

Extrude plane mesh #126

Closed vibra2020 closed 4 years ago

vibra2020 commented 4 years ago

Hi, i want to use extrude function, when i did it on a plane mesh, its extruding with 1 meter height, but i want to change the height to custom value, when i am trying that its still use the same default value - 1 meter.

              mesh3 = g3UnityUtils.UnityMeshToDMesh( hit.transform.gameObject.GetComponent<MeshFilter>().sharedMesh);

                MeshExtrudeMesh mem = new MeshExtrudeMesh(mesh3);
                mem.ExtrudedPositionF (new Vector3d(hit.transform.position.x, hit.transform.position.y + 4f, hit.transform.position.z), (Vector3f) Vector3.up, 0);

                mem.Extrude();

is it right? correct me please. Thanks.