コード例 #1
0
        public void TestEquals()
        {
            Matrix33F m1 = new Matrix33F(columnMajor, MatrixOrder.ColumnMajor);
            Matrix33F m2 = new Matrix33F(columnMajor, MatrixOrder.ColumnMajor);

            Assert.IsTrue(m1.Equals(m1));
            Assert.IsTrue(m1.Equals(m2));
            for (int i = 0; i < 9; i++)
            {
                m2     = new Matrix33F(columnMajor, MatrixOrder.ColumnMajor);
                m2[i] += 0.1f;
                Assert.IsFalse(m1.Equals(m2));
            }

            Assert.IsFalse(m1.Equals(m1.ToString()));
        }
コード例 #2
0
ファイル: Matrix33FTest.cs プロジェクト: Zolniu/DigitalRune
        public void TestEquals()
        {
            Matrix33F m1 = new Matrix33F(columnMajor, MatrixOrder.ColumnMajor);
              Matrix33F m2 = new Matrix33F(columnMajor, MatrixOrder.ColumnMajor);
              Assert.IsTrue(m1.Equals(m1));
              Assert.IsTrue(m1.Equals(m2));
              for (int i = 0; i < 9; i++)
              {
            m2 = new Matrix33F(columnMajor, MatrixOrder.ColumnMajor);
            m2[i] += 0.1f;
            Assert.IsFalse(m1.Equals(m2));
              }

              Assert.IsFalse(m1.Equals(m1.ToString()));
        }