Beispiel #1
0
        public int multiply(int matID)
        {
            MMatrix result = new MMatrix();

            result.m_matrix = m_matrix * MMatrix.getFromStorage(matID).m_matrix;
            return(result.m_ID);
        }
Beispiel #2
0
        public int multiply(int matID)
        {
            MVector3 result = new MVector3();

            result.m_vector = Vector3.Transform(m_vector, MMatrix.getFromStorage(matID).getRawData());
            return(result.m_ID);
        }
Beispiel #3
0
        public static int createCopyMatrix(int ID)
        {
            MMatrix instance = new MMatrix();

            instance.m_matrix = getFromStorage(ID).m_matrix;
            return(instance.m_ID);
        }
Beispiel #4
0
        private MMatrix(MMatrix mat)
        {
            m_matrix = new Matrix();
            m_matrix = mat.m_matrix;
            MMatrix instance = this;

            addMatrix(ref instance);
        }
Beispiel #5
0
        private MMatrix()
        {
            m_matrix = new Matrix();
            m_matrix = Matrix.Identity;
            MMatrix instance = this;

            addMatrix(ref instance);
        }
Beispiel #6
0
        private static void addMatrix(ref MMatrix mat)
        {
            while (m_storage.ContainsKey(m_IDCounter))
            {
                m_IDCounter = (m_IDCounter + 1) % int.MaxValue;
            }

            m_storage.Add(m_IDCounter, mat);
            mat.m_ID = m_IDCounter;
        }
Beispiel #7
0
        public static int createMatrix()
        {
            MMatrix instance = new MMatrix();

            return(instance.m_ID);
        }