Example #1
0
//C++ TO C# CONVERTER WARNING: 'const' methods are not available in C#:
//ORIGINAL LINE: int FaceNr(INDEX_3 & face) const
        public int FaceNr(INDEX_3 face) // which face nr is it ?
        {
            for (int i = 0; i < 3; i++)
            {
                if (pnums[i] != face.I1() && pnums[i] != face.I2() && pnums[i] != face.I3())
                {
                    return(i);
                }
            }
            return(3);
        }
Example #2
0
//C++ TO C# CONVERTER WARNING: The original C++ declaration of the following method implementation was not found:
        public double Func(Vector vp)
        {
            double badness = 0;

            Point <3> pp(vp(0), vp(1), vp(2));

            for (int j = 0; j < faces.Size(); j++)
            {
                INDEX_3 el = faces[j];

                double bad = CalcTetBadness(points[new PointIndex(el.I1())], points[new PointIndex(el.I3())], points[new PointIndex(el.I2())], pp, 0, mp);
                badness += bad;
            }

            return(badness);
        }