I’m trying to write 3D surfaces and curves on the surface can be flattened in a 2D plane and the opposite process.I try to use the SDK inside ON_SquishMesh(), I wrote the following code:
ON_SquishParameters * sp = new ON_SquishParameters();
sp-> SetSpringConstants (1.0, 1.0);
sp-> m_bSaveMapping = true;
sp-> m_bAreaPreprocess = true;
sp-> m_material = 1;
ON_SquishConstraints * sc = new ON_SquishConstraints();
Srf0-> CreateMesh (mp, m_meshAry);
ON_Mesh * outMesh1 = new ON_Mesh();
ON_Mesh * outMesh2 = new ON_Mesh();
outMesh1 = ON_SquishMesh (m_meshAry , sp, sc, outMesh2);
I have some questions to ask.
(I) What is the difference, “outMesh1” and “outMesh2”? In accordance with the Help file says, outMesh2 is to be variable input, I put a “outMesh2” into function, but found “outMesh1” and “outMesh2” will become the same.
(II) The second parameter ON_SquishParameters, m_bSaveMapping variables within this Class in SDK Help instructions for 『If m_bEnableMapBack is true, then ON_SquishMesh () will save extra information on the squished mesh so 3d points and curves near the input mesh can be mapped to the squished mesh and …』derived here are two small problems:
(a) I can not find “m_bEnableMapBack” in the SDK Help. It really exist?
(b) see the instructions say: 3D points and curves near the input mesh can be mapped to the squished mesh and『 2d points and curves on the squished mesh can be mapped back to the 3d mesh.』Are there examples in bold part?